Skip to content

[3.15] gh-149044: Improve Py_tp_base[s] docs & error message for non-type bases (GH-151252)#151606

Merged
encukou merged 1 commit into
python:3.15from
miss-islington:backport-16185e9-3.15
Jun 18, 2026
Merged

[3.15] gh-149044: Improve Py_tp_base[s] docs & error message for non-type bases (GH-151252)#151606
encukou merged 1 commit into
python:3.15from
miss-islington:backport-16185e9-3.15

Conversation

@miss-islington

@miss-islington miss-islington commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

The initial implementation of PEP 820 worsened the error message
when non-types are given as base types in Py_tp_bases & Py_tp_base.
Bring back the 'bases must be types' wording and add a 'got' note for
easier debugging.

Improve slot ID documentation, and soft-deprecate Py_tp_base
(as per the PEP).
(cherry picked from commit 16185e9)

Co-authored-by: Petr Viktorin encukou@gmail.com

…ype bases (pythonGH-151252)

The initial implementation of PEP 820 worsened the error message
when non-types are given as base types in Py_tp_bases & Py_tp_base.
Bring back the 'bases must be types' wording and add a 'got' note for
easier debugging.

Improve slot ID documentation, and soft-deprecate Py_tp_base
(as per the PEP).
(cherry picked from commit 16185e9fe2037d2171626f79c3d099bd7772b53e)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
@encukou encukou merged commit e9c7cc1 into python:3.15 Jun 18, 2026
57 checks passed
@miss-islington miss-islington deleted the backport-16185e9-3.15 branch June 18, 2026 08:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants