Skip to content

[TYP] Reduce stubtest ignores #25844

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

Merged
merged 1 commit into from
May 23, 2023
Merged

Conversation

ksunden
Copy link
Member

@ksunden ksunden commented May 9, 2023

PR summary

Broadly makes the type hints more reflective of runtime behavior, though does incur some type:ignore comments because of sub/superclass interactions

In particular, mypy does not approve of making parameters to methods mandatory for subclasses (it is fine with adding optional params, just not making valid superclass calls invalid).
Nor does it approve of removing even an optional param (for the same reason).

Helper _path functions which are undocumented are no longer exported in the transforms namespace.

Some additional comments added regarding corner cases of typing/explaining new ignores

PR checklist

Broadly makes the type hints more reflective of runtime behavior, though does incur some type:ignore comments because of sub/superclass interactions
@oscargus oscargus added this to the v3.8.0 milestone May 23, 2023
@timhoffm timhoffm merged commit 7d7f6da into matplotlib:main May 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants