-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
multipart.py
type annotations mismatch documentation
#3621
Comments
@asvetlov since I've only "collaborated" with you in the past. I am working now on improving those annotations a bit. If you're interested I might push a patch in a day or two. |
Ok, it went a bit faster. Can't exactly test that, something is off in my environment and can't quite tell what. It keeps on telling me that I should install cython although it is already installed. So fingers crossed and full transparency that I did not manage to test those out. |
Fixed by #3905 |
Long story short
Problem lies in a mismatch between the documentation of multipart here and the actual code execution around courotines
__anext__
,next
.Expected behaviour
Code annotations are matching the documentation and therefore expected behavior.
Actual behaviour
As a developer, I didn't notice that multipart reader behavior is actually not as straightforward as it seemed to be. Reading the documentation again, revealed to me what should be expected in here however I would expect that
mypy
tells me that I need to account for that behavior.Steps to reproduce
None that I can think of. Code works fine, only annotations need tuning.
Your environment
The text was updated successfully, but these errors were encountered: