raise DeprecationWarnings and FutureWarnings as errors#11570
raise DeprecationWarnings and FutureWarnings as errors#11570amueller merged 41 commits intoscikit-learn:masterfrom
Conversation
…e names. this is already tested for strings. Could add a test for dtype object?
|
this should be everything except model_selection and isolation forest and bagging which uses Imputer (these two have separate issues). |
|
merged #11593 into this so tests may pass. |
| _lars_path_residues(X_train, y_train, X_test, y_test, copy=False) | ||
|
|
||
|
|
||
| @ignore_warnings(DeprecationWarning) # positive deprecated, remove in 0.22 |
There was a problem hiding this comment.
This will skip the test due to #11594 (also applies to all other tests)
| @@ -1,20 +1,21 @@ | |||
| """Test the search module""" | |||
|
|
|||
| from collections import Iterable, Sized | |||
There was a problem hiding this comment.
from sklearn.utils.fixes import _Iterable as Iterable, _Sized as Sizedotherwise we get collections ABC warning in Python 3.7
There was a problem hiding this comment.
ah, right. not sure why @janvanrijn changed that.
There was a problem hiding this comment.
My code is an (old) version of master. I did not intentionally change that
|
|
||
| from sklearn.utils.fixes import sp_version | ||
| from sklearn.utils.fixes import PY3_OR_LATER | ||
| from sklearn.utils.fixes import _Iterable as Iterable, _Sized as Sized |
There was a problem hiding this comment.
Why? That's necessary to avoid warnings in Python 3.7
|
I think we need need to test Python 3.7 in Travis and not in a cron job (#11409). Otherwise this would have failed on Python 3.7 but we won't know because we are not testing for it.. |
|
@rth we should but that seems unrelated ;) |
|
@amueller you are right. |
|
I attempted the thing @massich is mentioning in github.com/amueller/futurepast but didn't have the follow-through necessary |
| ) | ||
|
|
||
|
|
||
| @ignore_warnings(FutureWarning) # ignore warning for validate=False 0.22 |
There was a problem hiding this comment.
@ignore_warnings(category=FutureWarning)
Towards #11252.
In the end we'd like to make these errors so we can keep this cleaner in the future.