-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
mock.patch
generic incorrectly inferred from new=
argument
#5533
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
Comments
I wonder if the order of the two overloads should be flipped. Your code matches the first overload (the new just goes into |
I think Jelle's right since if you pass the arg without keyword it works, opening a PR |
hauntsaninja
pushed a commit
to hauntsaninja/typeshed
that referenced
this issue
May 26, 2021
Fixes python#5533. This changes the order and in some cases removes default values from new.
Merged
srittau
pushed a commit
that referenced
this issue
May 26, 2021
* mock: fix overloads Fixes #5533. This changes the order and in some cases removes default values from new. * ignore incompatible overlaps Co-authored-by: hauntsaninja <>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
To Reproduce
Results in error:
I've had a quick look at the typeshed (
typeshed/stdlib/unittest/mock.pyi
Lines 203 to 258 in af33b09
Your Environment
The text was updated successfully, but these errors were encountered: