20.3 Warnings
A warning is understood to be an exception that doesn’t change the program flow but only appears in the standard stderr error stream (see Chapter 29, Section 29.2.3) to inform the programmer of a questionable but not critical circumstance.
An example of a typical warning is DeprecationWarning, which informs the developer or user that the running program uses functionality that will no longer be available in future Python versions or future versions of a library. This finding does not cause a problem in the current program flow, but it’s important enough that it should be made known.
Note
The appendix lists the types of warnings defined by default in Python and explains their meaning.
The warnings module of the standard library ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access