Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove mention of exception objects being builtins.
They were already for a very long time, so this is pointless.
I only had this sentence to explain why I had removed the
"import exceptions" line from the Python 2 days.
  • Loading branch information
malemburg committed Sep 2, 2022
commit b4c4c3bb8c49ba968d77908e5e68966bf888916f
10 changes: 4 additions & 6 deletions pep-0249.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1299,12 +1299,10 @@ Footnotes
was used as the base class for all DB-API exceptions. Since
``StandardError`` was removed in Python 3, database modules
targeting Python 3 should use ``Exception`` as base class instead.
Both ``StandardError`` and ``Exception`` are available as builtin
exception objects. The PEP was updated to use ``Exception``
throughout the text, to avoid confusion. The change should not
affect existing modules or uses of those modules, since all DB-API
error exception classes are still rooted at the ``Error`` or
``Warning`` classes.
The PEP was updated to use ``Exception`` throughout the text, to
avoid confusion. The change should not affect existing modules or
uses of those modules, since all DB-API error exception classes are
still rooted at the ``Error`` or ``Warning`` classes.

.. [11] In a future revision of the DB-API, the base class for
``Warning`` will likely change to the builtin ``Warning`` class. At
Expand Down