New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
get rid of warnings in regrtest with -3 #46654
Comments
Running the test suite with -3 enabled issues a load of warnings. The |
No, *correct usage* of the stdlib should not result in Py3k warnings. |
Fair enough. I agree that the deprecated APIs should still be tested. Testing of deprecated APIs should probably temporarily suppress the Py3K Reducing the flood of warnings is really worthwhile -- I just fixed a |
I made a little decorator which silences py3k warnings. It could be def silence_py3k(func):
def decorator(*args, **kwargs):
warnings.simplefilter("ignore", warnings.DeprecationWarning)
func(*args, **kwargs)
warnings.simplefilter("default", warnings.DeprecationWarning)
if sys.flags_py3kwarning:
return decorator
else:
return func |
Brett has been doing this. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: