Skip to content

[MRG] Change ignore_warnings behavior - #7296

Closed
tguillemot wants to merge 1 commit into
scikit-learn:masterfrom
tguillemot:ignore_warning
Closed

tguillemot wants to merge 1 commit into
scikit-learn:masterfrom
tguillemot:ignore_warning

Conversation

@tguillemot

Copy link
Copy Markdown
Contributor

Reference Issue

Fixes #7255

What does this implement/fix? Explain your changes.

I have removed the clean_warning_registry from ignore_warnings and all assert_warn... functions.
Consequently, now assert_warn and ignore_warning can be used together.

Any other comments?

I haven't a strong felling about that and I really need your point of view.
Is it ok for you @ogrisel @amueller @jnothman ?

@jnothman

Copy link
Copy Markdown
Member

As I said, there's a Python bug standing in the way. If you look back to the first version of assert_warns, clearing the registry didn't play a part, but for this reason became necessary. The solution is, unfortunately, not so simple!

@tguillemot

Copy link
Copy Markdown
Contributor Author

Oops I've misunderstand what you have said in #7255.
I close the PR :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ignore_warnings decorator ignored on python3.5?

2 participants