Skip to content
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

Remove support for Python 3.8 #5508

Merged
merged 7 commits into from
Dec 10, 2024
Merged

Remove support for Python 3.8 #5508

merged 7 commits into from
Dec 10, 2024

Conversation

snejus
Copy link
Member

@snejus snejus commented Nov 17, 2024

Description

  • Drop support for EOL Python 3.8 making Python 3.9 the minimum supported version

  • Take advantage of Python 3.9+ type hint syntax by:

    • Using list[T] instead of List[T] etc. from typing module
    • Using Type | None syntax for unions instead of Union[Type, None]
    • Moving collection type hints from typing to collections.abc
    • Using TYPE_CHECKING guard for runtime import optimization

Note: in #5503 we found that we cannot support Python 3.12 unless we upgrade our minimum support Python to 3.9.

To Do

  • Documentation. (If you've added a new command-line flag, for example, find the appropriate page under docs/ to describe it.)
  • Changelog. (Add an entry to docs/changelog.rst to the bottom of one of the lists near the top of the document.)
  • Tests. (Very much encouraged but not strictly required.)

Copy link
Contributor

@Serene-Arc Serene-Arc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

.github/workflows/lint.yml Show resolved Hide resolved
@snejus snejus merged commit 22163d7 into master Dec 10, 2024
13 checks passed
@snejus snejus deleted the drop-py38 branch December 10, 2024 06:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants