-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Create stubs for Flask #2740
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
Create stubs for Flask #2740
Conversation
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.
I am not a Flask user, but I discovered couple hundreds possible false positives when trying these stubs with our internal codebase. 95% of them however fall into few categories below.
@JelleZijlstra @srittau Could one of you please also take a look at this PR?
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.
This is almost ready. You just need to add the metaclass, and two comments.
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! LGTM now.
@srittau @JelleZijlstra If there are no objections, I will merge this soon, so that we can move forward. |
…n#3913) The PR python#2740 added __setattr__ and __getattr__ to the werkzeug.wrappers.BaseRequest definition to silence mypy when monkeypatching this class. The change disabled the errors for monkeypatching, but disabled disabled the important check attr-defined.
…n#3913) (python#3925) The PR python#2740 added __setattr__ and __getattr__ to the werkzeug.wrappers.BaseRequest definition to silence mypy when monkeypatching this class. The change disabled the errors for monkeypatching, but disabled disabled the important check attr-defined.
See permission in pallets/flask#2012.
Fixes #28.