Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Docs: Update PyExc_* tables in the c-api documentation #131640

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
Loading
from
Open
Show file tree
Hide file tree
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
Next Next commit
Docs: Update PyExc_* tables in the c-api documentation
`PyExc_BaseExceptionGroup` and `PyExc_EncodingWarning` are not listed in
[the exceptions table](https://docs.python.org/3/c-api/exceptions.html#standard-exceptions) and
[the warnings table] (https://docs.python.org/3/c-api/exceptions.html#standard-warning-categories)
  • Loading branch information
koyuki7w committed Mar 24, 2025
commit ffa4f4a83986d828603c6404b3dfe075941b3389
12 changes: 12 additions & 0 deletions 12 Doc/c-api/exceptions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -982,6 +982,7 @@ the variables:

.. index::
single: PyExc_BaseException (C var)
single: PyExc_BaseExceptionGroup (C var)
single: PyExc_Exception (C var)
single: PyExc_ArithmeticError (C var)
single: PyExc_AssertionError (C var)
Expand Down Expand Up @@ -1041,6 +1042,8 @@ the variables:
+=========================================+=================================+==========+
| :c:data:`PyExc_BaseException` | :exc:`BaseException` | [1]_ |
+-----------------------------------------+---------------------------------+----------+
| :c:data:`PyExc_BaseExceptionGroup` | :exc:`BaseExceptionGroup` | |
koyuki7w marked this conversation as resolved.
Show resolved Hide resolved
+-----------------------------------------+---------------------------------+----------+
| :c:data:`PyExc_Exception` | :exc:`Exception` | [1]_ |
+-----------------------------------------+---------------------------------+----------+
| :c:data:`PyExc_ArithmeticError` | :exc:`ArithmeticError` | [1]_ |
Expand Down Expand Up @@ -1164,6 +1167,9 @@ the variables:
.. versionadded:: 3.6
:c:data:`PyExc_ModuleNotFoundError`.

.. versionadded:: 3.11
:c:data:`PyExc_BaseExceptionGroup`.

These are compatibility aliases to :c:data:`PyExc_OSError`:

.. index::
Expand Down Expand Up @@ -1207,6 +1213,7 @@ the variables:
single: PyExc_Warning (C var)
single: PyExc_BytesWarning (C var)
single: PyExc_DeprecationWarning (C var)
single: PyExc_EncodingWarning (C var)
single: PyExc_FutureWarning (C var)
single: PyExc_ImportWarning (C var)
single: PyExc_PendingDeprecationWarning (C var)
Expand All @@ -1225,6 +1232,8 @@ the variables:
+------------------------------------------+---------------------------------+----------+
| :c:data:`PyExc_DeprecationWarning` | :exc:`DeprecationWarning` | |
+------------------------------------------+---------------------------------+----------+
| :c:data:`PyExc_EncodingWarning` | :exc:`EncodingWarning` | |
+------------------------------------------+---------------------------------+----------+
| :c:data:`PyExc_FutureWarning` | :exc:`FutureWarning` | |
+------------------------------------------+---------------------------------+----------+
| :c:data:`PyExc_ImportWarning` | :exc:`ImportWarning` | |
Expand All @@ -1245,6 +1254,9 @@ the variables:
.. versionadded:: 3.2
:c:data:`PyExc_ResourceWarning`.

.. versionadded:: 3.10
:c:data:`PyExc_EncodingWarning`.

Notes:

.. [3]
Expand Down
2 changes: 2 additions & 0 deletions 2 Doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,7 @@
('c:data', 'PyExc_AssertionError'),
('c:data', 'PyExc_AttributeError'),
('c:data', 'PyExc_BaseException'),
('c:data', 'PyExc_BaseExceptionGroup'),
('c:data', 'PyExc_BlockingIOError'),
('c:data', 'PyExc_BrokenPipeError'),
('c:data', 'PyExc_BufferError'),
Expand Down Expand Up @@ -287,6 +288,7 @@
# C API: Standard Python warning classes
('c:data', 'PyExc_BytesWarning'),
('c:data', 'PyExc_DeprecationWarning'),
('c:data', 'PyExc_EncodingWarning'),
('c:data', 'PyExc_FutureWarning'),
('c:data', 'PyExc_ImportWarning'),
('c:data', 'PyExc_PendingDeprecationWarning'),
Expand Down
Loading
Morty Proxy This is a proxified and sanitized view of the page, visit original site.