FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-89554: Document typing.ParamSpecArgs and ParamSpecKwargs as classes by gaborbernat · Pull Request #150677 · python/cpython · GitHub

Repository navigation

gh-89554: Document typing.ParamSpecArgs and ParamSpecKwargs as classes - #150677

Merged
serhiy-storchaka merged 1 commit into
python:mainfrom
gaborbernat:gh-89554-typing-paramspec-class-roles
Jun 2, 2026
Merged

serhiy-storchaka merged 1 commit into
python:mainfrom
gaborbernat:gh-89554-typing-paramspec-class-roles

Conversation

gaborbernat commented May 31, 2026 •
edited
Loading

Copy link
Copy Markdown
Contributor

typing.ParamSpecArgs and typing.ParamSpecKwargs are classes (the runtime types of the args and kwargs attributes of a ParamSpec), but the documentation marks them with the .. data:: directive. The existing :class: cross-references to them in Doc/library/typing.rst and Doc/whatsnew/3.10.rst therefore resolve against a missing py:class target.

Switch the stacked entry to .. class:: so the references resolve. Both names share a single entry, so both are covered.

Refs: gh-89554. Documentation-only change, so no Misc/NEWS entry (skip news).

…classes

ParamSpecArgs and ParamSpecKwargs are classes (the runtime types of the
args and kwargs attributes of a ParamSpec), but were documented with the
".. data::" directive. The existing ":class:`ParamSpecArgs`" and
":class:`ParamSpecKwargs`" cross-references in the typing docs and the 3.10
What's New page therefore fail to resolve against a py:class target.

Switch the stacked entry to ".. class::" so the references resolve.

Copy link
Copy Markdown

Documentation build overview

📚 cpython-previews | 🛠️ Build #32924402 | 📁 Comparing cc59bf0 against main (2f8f569)

  🔍 Preview build  

1 file changed
± library/typing.html

JelleZijlstra added needs backport to 3.13 only security fixes needs backport to 3.14 bugs and security fixes needs backport to 3.15 bugs and security fixes labels May 31, 2026

gaborbernat commented Jun 1, 2026 •
edited
Loading

Copy link
Copy Markdown
Contributor Author

Backward-compatibility check. The only downstream :data: reference found is typing_extensions (doc/index.rst), which is maintained alongside CPython. :class: references to ParamSpecArgs already exist in typing.rst and whatsnew/3.10.rst. Low risk.

serhiy-storchaka left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM. 👍

serhiy-storchaka merged commit 35c314d into python:main Jun 2, 2026
46 checks passed
github-project-automation Bot moved this from Todo to Done in Docs PRs Jun 2, 2026

Copy link
Copy Markdown

Thanks @gaborbernat for the PR, and @serhiy-storchaka for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14, 3.15.
🐍🍒⛏🤖

bedevere-app Bot commented Jun 2, 2026

Copy link
Copy Markdown

GH-150763 is a backport of this pull request to the 3.15 branch.

bedevere-app Bot removed the needs backport to 3.15 bugs and security fixes label Jun 2, 2026

bedevere-app Bot commented Jun 2, 2026

Copy link
Copy Markdown

GH-150764 is a backport of this pull request to the 3.14 branch.

bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label Jun 2, 2026

bedevere-app Bot commented Jun 2, 2026

Copy link
Copy Markdown

GH-150765 is a backport of this pull request to the 3.13 branch.

bedevere-app Bot removed the needs backport to 3.13 only security fixes label Jun 2, 2026
serhiy-storchaka pushed a commit that referenced this pull request Jun 2, 2026
… classes (GH-150677) (GH-150765)

Use the directive "class" instead of "data" for ParamSpecArgs and ParamSpecKwargs.
(cherry picked from commit 35c314d)

Co-authored-by: Bernát Gábor <gaborjbernat@gmail.com>
serhiy-storchaka pushed a commit that referenced this pull request Jun 2, 2026
… classes (GH-150677) (GH-150764)

Use the directive "class" instead of "data" for ParamSpecArgs and ParamSpecKwargs.
(cherry picked from commit 35c314d)

Co-authored-by: Bernát Gábor <gaborjbernat@gmail.com>
serhiy-storchaka pushed a commit that referenced this pull request Jun 2, 2026
… classes (GH-150677) (GH-150763)

Use the directive "class" instead of "data" for ParamSpecArgs and ParamSpecKwargs.
(cherry picked from commit 35c314d)

Co-authored-by: Bernát Gábor <gaborjbernat@gmail.com>
gaborbernat deleted the gh-89554-typing-paramspec-class-roles branch October 3, 2026 15:12
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation in the Doc dir skip news

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL