Skip to content

linkify_issues(docs[SetupDict]): Document TypedDict fields#81

Open
tony wants to merge 2 commits into
masterfrom
attributes-backfill
Open

linkify_issues(docs[SetupDict]): Document TypedDict fields#81
tony wants to merge 2 commits into
masterfrom
attributes-backfill

Conversation

@tony

@tony tony commented Jul 25, 2026

Copy link
Copy Markdown
Member

SetupDict reached the API reference with its keys rendered bare — autodoc emits every field of a NamedTuple, dataclass, or TypedDict whether or not the docstring describes it, so an undocumented field ships as "Alias for field number 0" or with no description at all. This adds a NumPy-style Attributes section naming each key, its type, and what it holds. Docstrings only: no code, signature, or field-order changes.

Gates run and passing: just ruff-format, just ruff, uv run mypy ., just test, just build-docs.

The docs build now emits new duplicate-object warnings for linkify_issues.SetupDict.version, linkify_issues.SetupDict.parallel_read_safe, and linkify_issues.SetupDict.parallel_write_safe — the NumPy preprocessor emits an .. attribute:: for each documented field while autodoc renders the same field, so Sphinx sees each described twice. Trunk builds clean, so these arrive with this change. They are left unsuppressed here; the fix belongs in gp-sphinx and is landing there separately.

Closes #80

@codecov

codecov Bot commented Jul 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 76.32%. Comparing base (bdf648b) to head (d042bae).

Additional details and impacted files
@@           Coverage Diff           @@
##           master      #81   +/-   ##
=======================================
  Coverage   76.32%   76.32%           
=======================================
  Files          15       15           
  Lines        1018     1018           
=======================================
  Hits          777      777           
  Misses        241      241           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@tony
tony force-pushed the attributes-backfill branch from ab80392 to fd3727d Compare July 26, 2026 00:57
tony added 2 commits July 25, 2026 20:20
why: Sphinx autodoc renders TypedDict fields whether or not they
are described, so the extension metadata keys ship to the API
reference bare, leaving readers to guess what the setup mapping
promises Sphinx.

what:
- Add an Attributes section to SetupDict covering the extension
  version and the parallel read/write safety flags
why: The unreleased entry did not record that class fields now carry
descriptions where the API reference renders them.

what:
- Note the described fields under Documentation
@tony
tony force-pushed the attributes-backfill branch from 686e745 to d042bae Compare July 26, 2026 01:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

docs: Document Attributes for NamedTuple, dataclass, and TypedDict fields

1 participant