-
-
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
Add final declarations to the library constants. #5275
Labels
Comments
Hello @asvetlov ! I would be glad to step in and make a PR, are there other places that come to your mind that have these kind of constants? |
Basically, any module-level assignment falls into one of three categories:
|
4 tasks
asvetlov
added a commit
that referenced
this issue
Dec 17, 2020
Co-authored-by: Andrew Svetlov <[email protected]>
asvetlov
pushed a commit
that referenced
this issue
Dec 17, 2020
Co-authored-by: Andrew Svetlov <[email protected]>. (cherry picked from commit 3be8a68) Co-authored-by: Anas <[email protected]>
asvetlov
added a commit
that referenced
this issue
Dec 17, 2020
Co-authored-by: Andrew Svetlov <[email protected]>. (cherry picked from commit 3be8a68) Co-authored-by: Anas <[email protected]>
Closing, it was merged almost a month ago |
commonism
pushed a commit
to commonism/aiohttp
that referenced
this issue
Apr 27, 2021
Co-authored-by: Andrew Svetlov <[email protected]>
commonism
pushed a commit
to commonism/aiohttp
that referenced
this issue
Apr 27, 2021
Co-authored-by: Andrew Svetlov <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The library has many constant definitions that are declared as
NAME = 'val'
, e.g. https://github.com/aio-libs/aiohttp/blob/master/aiohttp/client.py#L161We need to add
Final
type hint to let users know that these constants should be considered as immutable (this hint doesn't prevent the actual modification and fully backward compatible).The text was updated successfully, but these errors were encountered: