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
bpo-39674: Suggest to test with DeprecationWarning #18552
Conversation
Add a section in What's New In Python 3.9 to strongly advice to check for DeprecationWarning in your Python projects.
@brettcannon: Does it sound like what you proposed in the python-dev thread? |
Doc/whatsnew/3.9.rst
Outdated
==================================================== | ||
|
||
When Python 2.7 was still supported, many functions were kept for backward | ||
compatibility with Python 2.7. With the end of the Python 2.7 support, these |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
compatibility with Python 2.7. With the end of the Python 2.7 support, these | |
compatibility with Python 2.7. With the end of Python 2.7 support, these |
Doc/whatsnew/3.9.rst
Outdated
|
||
When Python 2.7 was still supported, many functions were kept for backward | ||
compatibility with Python 2.7. With the end of the Python 2.7 support, these | ||
backward compatibility layers have been reomved or will be removed shortly. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
backward compatibility layers have been reomved or will be removed shortly. | |
backward compatibility layers have been removed, or will be removed soon. |
Doc/whatsnew/3.9.rst
Outdated
When Python 2.7 was still supported, many functions were kept for backward | ||
compatibility with Python 2.7. With the end of the Python 2.7 support, these | ||
backward compatibility layers have been reomved or will be removed shortly. | ||
Most of them emitted :exc:`DeprecationWarning` warning for several years. For |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Most of them emitted :exc:`DeprecationWarning` warning for several years. For | |
Most of them emitted a :exc:`DeprecationWarning` warning for several years. For |
Doc/whatsnew/3.9.rst
Outdated
backward compatibility layers have been reomved or will be removed shortly. | ||
Most of them emitted :exc:`DeprecationWarning` warning for several years. For | ||
example, using ``collections.Mapping`` instead of ``collections.abc.Mapping`` | ||
emits a :exc:`DeprecationWarning` since Python 3.3 released in 2012. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
emits a :exc:`DeprecationWarning` since Python 3.3 released in 2012. | |
emits a :exc:`DeprecationWarning` since Python 3.3, released in 2012. |
Doc/whatsnew/3.9.rst
Outdated
example, using ``collections.Mapping`` instead of ``collections.abc.Mapping`` | ||
emits a :exc:`DeprecationWarning` since Python 3.3 released in 2012. | ||
|
||
Test your application with :option:`-W` ``default`` command line option to see |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test your application with :option:`-W` ``default`` command line option to see | |
Test your application with the :option:`-W` ``default`` command-line option to see |
Doc/whatsnew/3.9.rst
Outdated
Test your application with :option:`-W` ``default`` command line option to see | ||
:exc:`DeprecationWarning` and :exc:`PendingDeprecationWarning`, or even with | ||
:option:`-W` ``error`` to treat them as errors. :ref:`Warnings Filter | ||
<warning-filter>` can be used to ignore warnings from third party code. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<warning-filter>` can be used to ignore warnings from third party code. | |
<warning-filter>` can be used to ignore warnings from third-party code. |
Yep, this is what I was thinking, but you forgot to mention |
Right. But you wrote that you wasn't convinced that the relationship between DeprecationWarning and -X dev, so I focused on warnings instead ;-) |
I think it's also worth mentioning |
Ok, done. |
Co-Authored-By: Hugo van Kemenade <hugovk@users.noreply.github.com>
Thanks @hugovk for your useful reviews! |
You're welcome! |
Add a section in What's New In Python 3.9 to strongly advice to check
for DeprecationWarning in your Python projects.
https://bugs.python.org/issue39674