-
-
Notifications
You must be signed in to change notification settings - Fork 954
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
Drop support for Python 3.7 #2178
Conversation
I'll make the next release with 3.7, then I'll merge this. |
starlette/applications.py
Outdated
# TODO: Make `__name` a positional-only argument when we drop Python 3.7 support. | ||
def url_path_for(self, __name: str, **path_params: typing.Any) -> URLPath: | ||
return self.router.url_path_for(__name, **path_params) | ||
def url_path_for(self, /, name: str, **path_params: typing.Any) -> URLPath: |
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.
Is there a mistake here?
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.
It isn't supposed to be... Why do you think it is?
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 recall from our earlier discussion that name
should be a positional-only parameter.
Maybe it should be changed to (self, name: str, /, **path_params: typing.Any)
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.
Ah, it's a mistake! 🤣
Thanks! 🙏
793c030
to
3ace695
Compare
LGTM |
Python 3.7 EOL is coming: https://endoflife.date/python.