-
-
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
Use correct type for add_view #3633
Conversation
@asvetlov tests and mypy went fine for me locally. However I noticed that |
Codecov Report
@@ Coverage Diff @@
## master #3633 +/- ##
==========================================
- Coverage 97.9% 97.84% -0.06%
==========================================
Files 43 43
Lines 8556 8649 +93
Branches 1376 1381 +5
==========================================
+ Hits 8377 8463 +86
- Misses 74 81 +7
Partials 105 105
Continue to review full report at Codecov.
|
It will resolve: #123 |
Hmm..I have tried to sign the CLA, but for some reason there are requests in https://cla-assistant.io/aio-libs/aiohttp?pullRequest=3633 that fail with 401. Not sure why though. |
Sorry, @kornicameister |
Ah, ok...I though that maybe the PR is not being checked because of missing CLA :/. I shall be calm :) GL with Python 3.8. |
Thanks! |
(cherry picked from commit 5ea9169) Co-authored-by: Tomasz Trębski <[email protected]>
(cherry picked from commit 5ea9169) Co-authored-by: Tomasz Trębski <[email protected]>
@asvetlov Cheers 👍 |
What do these changes do?
They are changing the type declaration for
add_view
in router. Previously it said that it was to beAbstractView
but that required an instance of theAbstractView
subclass. The documentation stands for it to be the class, hence changing the typing toType[AbstractView]
.Are there changes in behavior for the user?
No more mypy errors when using
add_view
method/function.Related issue number
Fixes #3653
Checklist
CONTRIBUTORS.txt
CHANGES
folder<issue_id>.<type>
for example (588.bugfix)issue_id
change it to the pr id after creating the pr.feature
: Signifying a new feature..bugfix
: Signifying a bug fix..doc
: Signifying a documentation improvement..removal
: Signifying a deprecation or removal of public API..misc
: A ticket has been closed, but it is not of interest to users.