Skip to content

Improve TypedDict documentation#770

Merged
AlexWaygood merged 2 commits into
mainfrom
typeddicts
Jun 25, 2026
Merged

Improve TypedDict documentation#770
AlexWaygood merged 2 commits into
mainfrom
typeddicts

Conversation

@AlexWaygood

@AlexWaygood AlexWaygood commented Jun 25, 2026

Copy link
Copy Markdown
Member
  • Our source code had several confusing comments referring to PEP 728 not yet having been implemented upstream. It's been implemented upstream for a while now, but we can't yet simply re-export TypedDict on Python 3.15 because...
  • ...We never documented that typing_extensions includes experimental support for PEP 764 (inline TypedDicts).

This PR improves the documentation for TypedDicts. To test the PR, I built the docs locally, which exposed:

  • I didn't know how to do that for this repo. This PR adds some notes to CONTRIBUTING.md on how to do that.
  • The docs build already failed on main with nitpicky mode, because the signature we gave for dataclass_transform in the docs was invalid (you can't do multiline definitions like that with Sphinx). This PR therefore also fixes those issues, and adds a CI job to build the docs with nitpicky mode, to prevent issues like that from reoccurring.

@codecov

codecov Bot commented Jun 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.26%. Comparing base (224f8d5) to head (76663c0).

@@            Coverage Diff             @@
##             main     #770      +/-   ##
==========================================
- Coverage   97.26%   97.26%   -0.01%     
==========================================
  Files           3        3              
  Lines        7862     7860       -2     
==========================================
- Hits         7647     7645       -2     
  Misses        215      215              
Flag Coverage Δ
3.10 88.85% <100.00%> (-0.01%) ⬇️
3.10.4 88.85% <100.00%> (-0.01%) ⬇️
3.11 88.02% <100.00%> (-0.01%) ⬇️
3.11.0 87.27% <100.00%> (-0.01%) ⬇️
3.12 87.97% <100.00%> (-0.01%) ⬇️
3.12.0 87.96% <100.00%> (-0.01%) ⬇️
3.13 83.39% <100.00%> (-0.01%) ⬇️
3.13.0 84.10% <100.00%> (-0.01%) ⬇️
3.14 79.53% <100.00%> (-0.01%) ⬇️
3.9 89.53% <100.00%> (-0.01%) ⬇️
3.9.12 89.53% <100.00%> (-0.01%) ⬇️
pypy3.10 88.68% <100.00%> (-0.01%) ⬇️
pypy3.11 87.88% <100.00%> (-0.01%) ⬇️
pypy3.9 89.37% <100.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/test_typing_extensions.py 98.23% <100.00%> (-0.01%) ⬇️
src/typing_extensions.py 94.00% <100.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@AlexWaygood AlexWaygood added the documentation Improvements or additions to documentation label Jun 25, 2026
@AlexWaygood AlexWaygood marked this pull request as ready for review June 25, 2026 11:28
@AlexWaygood AlexWaygood merged commit 8dcc559 into main Jun 25, 2026
25 checks passed
@AlexWaygood AlexWaygood deleted the typeddicts branch June 25, 2026 14:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants