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

Adding compatibility for Python 3.12 #226

Closed
AmyOctoCat opened this issue Apr 24, 2024 · 0 comments · Fixed by #220
Closed

Adding compatibility for Python 3.12 #226

AmyOctoCat opened this issue Apr 24, 2024 · 0 comments · Fixed by #220

Comments

@AmyOctoCat
Copy link
Collaborator

AmyOctoCat commented Apr 24, 2024

Is your feature request related to a problem? Please describe.
Currently, the pyrealm unit tests will not run and flake8 will not run from the command line when running with Python 3.12.0. This is due to a flake8 and pytest-flake8 version incompatibility with the newer version of python. We should also update our test runners and docs accordingly.

Describe the solution you'd like
Option 1: Remove pytest-flake8 and bump version of flake8 to 7.0.0
One potential option is to upgrade the version of flake8 specified in pyproject.toml (7.0.0 is compatible with the newer python). However, pytest-flake8 does not have a version compatible with Python 3.12.0. We are currently considering removing this from the pytest config so that it no longer runs as part of the unit tests, since flake8 is already run as part of the pre-commit step. This solution has been confirmed to be backwards compatible with Python 3.10 and 3.11 too.

Option 2: Switch to using ruff and remove the use of flake8 and pytest-flake8
We currently have an open issue to investigate the use of ruff: #219
We may decide to replace flake8 entirely with ruff.

Whichever option is chosen, we should also add test runners for Python 3.12 and potentially considering adding explicit upper bound to the compatible python versions listed in our docs.

Describe alternatives you've considered
Pending investigation into ruff, both solutions are a possibility.

Additional context
N/A

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 a pull request may close this issue.

1 participant