-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unify docutils type annotations #12007
Comments
Have started tweaking type annotations in typeshed, with a view to reach parity and then transition this repo to typeshed |
Good idea! I am always frustrated because of how poor autocompletion is done with docutils on Pycharm so I'll be very happy if this can be merged upstream. |
i've created a PR to track the migration here - #12012 contributions (both to the PR and upstream in typeshed) very very welcome! |
@sphinx-doc/triagers @sphinx-doc/developers @sphinx-doc/former-maintainers @picnixz can I pretty please get a solid review of python/typeshed#11469? It introduces a generic type argument to the docutils state machine to represent the from the docutils docs:
|
I won't be there next week, and I don't think I'll have time for that today. But I'll do it by in two weeks (I will take time for that). |
stand down! I've postponed adding generics, even if they are technically correct. The decision is blocking progress and would have significant downstream impact. |
If you are talking about state transitions, like
I am, I've been through it in excruciating detail, because I'm writing an RST parser as we speak 😉 This all looks great, thanks for all the work! |
I believe that's true of the rst-specific subclasses. Is it also true of the superclass? (I'll take your word for it) |
Ah thank you chris for helping here since I am travelling (I'm currently in a train). Could I ask you to help with the upstream PRs (I can come back later if there are some questions though it's been a while since I played with docutils)? |
Okie, I will try to carve out some time for it 👍 |
i'm proposing that #12012 be merged, warts and all so that all future improvements to typing are made against the community-supported typeshed docutils stubs |
there are two sources of truth for docutils type annotations.
this repo uses
docutils-stubs
, but there's also typeshed annotations -types-docutils
.Neither are complete, nor is one a subset of the other.
types-docutils
was historically pretty poor but has seen more active development lately and has improved.doctuils-stubs
is more complete, but is out of date and unmaintained.I believe this repo should migrate to the typeshed annotations and upstream anything missing from
docutils-stubs
into typeshed.cc @tk0miya
[WIP] improve type annotations in 'docutils.parsers.rst.states' python/typeshed#11525and the actual PR to migrate to typeshed (WIP): #12012
The text was updated successfully, but these errors were encountered: