Repository navigation
stubs/requests: expand types for files - #7999
Conversation
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
AlexWaygood
left a comment
There was a problem hiding this comment.
Thanks! I dug around in the source code and tried out your repro, all looks good. Just one comment about how we can simplify the code a little, and also make the stub a little more permissive.
This comment has been minimized.
This comment has been minimized.
AlexWaygood
left a comment
There was a problem hiding this comment.
LGTM, but given the number of issues we've had with requests stubs recently, I'd like a second opinion before merging :)
This comment has been minimized.
This comment has been minimized.
Akuli
left a comment
There was a problem hiding this comment.
I'm mostly concerned about using _TextMapping. The rest are small nits.
This comment has been minimized.
This comment has been minimized.
|
According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉 |
|
Which version will reflect these changes? |
|
@isFakeAccount I can confirm these changes were released as of at least pip install types-requests==2.27.30 -U |
|
Thanks for the quick response @tommilligan |
Relates to #7724
Closes #7998
This PR allows passing a sequence of tuple for the
filesargument, where applicable in therequestslibrary.Existing types have been aliased for readability, and to document that all type of file specification are supported in either the
MappingorSequence[tuple]form.