-
Notifications
You must be signed in to change notification settings - Fork 16
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
Allow marking stubs as partial #94
Conversation
In that case it would probably make sense to rename |
I personally wouldn't rename I infer from it, because having stubtest ignore missing stubs usually means that, well, there's missing stubs! (and so, the stub package should probably be marked as partial, so that we don't hide public API that is not yet typed). I see two ways of doing it (more suggestions welcome). Whichever solution should be well documented in typeshed.
Now for example use cases where
|
I'd prefer to split those features, i.e. have a separate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! The mkdir/makedirs
suggestions are optional, in case you like your solution better.
Co-authored-by: Sebastian Rittau <srittau@rittau.biz>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whoops, sorry for forgetting about this and thanks!
Closes #93
I'm sure this can be improved. Also please review and test carefully (I'm still running integration tests, but they're taking forever).
The basic idea is to infer a stub package beingpartial
from findingignore_missing_stub = true
in the metadata. If we decide to add a specific "partial" entry in the metadata, the logic will stay the same, only the property's inner code will change.Edit: went for a separate metadata key.
Alternatively typeshed could add the
partial\n
py.typed
marker itself (assuming it can use packages instead of single files for single-file source w/o problem with stubtest)