-
Notifications
You must be signed in to change notification settings - Fork 709
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 py35 and py36 #1203
base: master
Are you sure you want to change the base?
drop py35 and py36 #1203
Conversation
Thanks @trim21 for your hard work here. I haven't tested how well type Mypyc and Cython leverage type hints. If it could indeed lead to faster execution, it would be a very compelling reason to add inline typing to the codebase. However, I'm still in favor of maintaining support for Python 3.5. Even though it reached "End-of-life" status, these versions are still in-use and I'd like to continue releasing bug fixes and enhancements for them. Is this a major obstacle to adding type hints, despite the existence of backporting libraries like |
Normally I wouldn't recommand to drop old python support for typing because we already have typing_extensions, but py35 and py36 are special. Inline type annotation are new syntax, not new stdlib function/variable can be backported by library.
they doesn't work will without typing message.... |
It the "inline type annotation" you're referring to that of PEP 484? The following code is valid syntax: def foo(a: int, b: int) -> int:
d: int = 4
return a + b + d
print(foo(3, 2)) |
I think it need at least py36 |
Apologies. I used an online interpreter that claims to be on version 3.5.2 but visibly is not. |
sorry, I didn't rember it correctly. Maybe we do not need to drop python36 |
renamed_path = "{}.{}{}".format(root, date, ext) | ||
renamed_path = f"{root}.{date}{ext}" |
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 still valid, even in Python 3.13
May I ask what the scope of your PR is?
Are you simply trying to drop support for Python 3.5 and 3.6, or are you also resolving deprecated code and taking advantage of new syntax?
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 diff is generated by pyupgrade
I'm tring to resolving deprecated code and taking advantage of new syntax. and try add mypyc or cython on it to make it faster. but py35 is just too old to do that.
This PR now have conflicts, I'll resolve it when we decide to drop there 2 versions. |
drop python 35 and python 36 will make is possible to add inline typing, then we can commpile it with cython or mypyc.