-
Notifications
You must be signed in to change notification settings - Fork 110
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
Update pre-commit hooks and drop support for Python 3.6 & 3.7 #1109
Update pre-commit hooks and drop support for Python 3.6 & 3.7 #1109
Conversation
@omry any objection to bumping the min version requirement to 3.8? Recent versions of black, etc. have all moved to 3.8. |
Converting to draft until the move to 3.8 is approved |
@omry thoughts on enforcing Python >= 3.8? |
lgtm. |
if sys.version_info < (3, 7, 0): # pragma: no cover | ||
typed_dict = hasattr(type_, "__base__") and type_.__base__ == Dict | ||
return origin is Dict or type_ is Dict or typed_dict | ||
else: # pragma: no cover | ||
typed_dict = hasattr(type_, "__base__") and type_.__base__ == dict | ||
return origin is dict or typed_dict |
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 gets into actual cleanup of 3.6 code.
@Jasha10 , did we officially removed support for it yet?
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 gets into actual cleanup of 3.6 code.
When you said "lgtm" I thought you were saying "yes" to my question "thoughts on enforcing Python >= 3.8?"
@Jasha10 , did we officially removed support for it yet?
All official releases of OmegaConf / Hydra still support Python 3.6. I'm proposing to drop this support in the next release (because it will make our lives easier, and I doubt anyone still runing 3.6/3.7 would care about not being able to run the latest version).
Edit: actually Hydra already dropped support for 3.6
Just in case we would want to distinguish before vs. after dropping support for Python 3.6 / 3.7.
Un-drafting as I believe it's ready now. Next step on my side: doing something similar in Hydra (may take a few more weeks as I'm working on it quite sparingly). Edit: actually Hydra already dropped 3.6 (facebookresearch/hydra#2523) |
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.
Sorry for the slow review. This diff looks good to me!
Fixes #1108
This PR updates pre-commit hooks to the latest current versions of isort / black / flake8 / mypy, and ensures we can run all these tools in the repository without any complaint (which also required dropping support for Python 3.6 & 3.7)