Skip to content

[docutils] Type Publisher attributes and the source/destination classes in docutils.core - #16268

Merged
srittau merged 2 commits into
python:mainfrom
ekanshul:docutils-core-publisher
Aug 20, 2026
Merged

[docutils] Type Publisher attributes and the source/destination classes in docutils.core#16268
srittau merged 2 commits into
python:mainfrom
ekanshul:docutils-core-publisher

Conversation

@ekanshul

Copy link
Copy Markdown
Contributor

Publisher.document, Publisher.source_class and Publisher.destination_class were Incomplete, the source_class/destination_class parameters of the publish_* functions were unannotated, and publish_programmatically() only accepted type[FileInput] although publish_parts() and publish_doctree() pass StringInput to it. This types document as nodes.document | None and the class parameters and attributes as type[Input[Incomplete]] / type[Output] throughout.

Agent used: Claude Code

…es in docutils.core

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@github-actions

This comment has been minimized.

@github-actions

Copy link
Copy Markdown
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@srittau
srittau merged commit a1499c5 into python:main Aug 20, 2026
74 checks passed
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.

2 participants