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

Unable to add Python 3.12 to CI due to dependency bugs #1617

Closed
supakeen opened this issue Feb 28, 2024 · 3 comments
Closed

Unable to add Python 3.12 to CI due to dependency bugs #1617

supakeen opened this issue Feb 28, 2024 · 3 comments
Labels
CI Continuous Integration Failures tests change related to our testing suite

Comments

@supakeen
Copy link
Member

For the past few months we've been unable to enable Python 3.12 in our CI due to an outstanding autopep8 formatting bug: hhatto/autopep8#712

We need to find a way forward as we do support Python 3.12 and we're even getting relatively close to Python 3.13. The options we have:

  1. Drop autopep8 from the linters.
  2. Use a different linter from autopep8.

For the second one I'd prefer not to revisit arguments made during previous discussions assuming they all still stand and which are the reason to use autopep8. So I'd like to go with option 1 instead, unless people want to re-evaluate using ruff for both formatting and linting.

@achilleas-k @ondrejbudai @thozza @mvo5

@supakeen supakeen added CI Continuous Integration Failures tests change related to our testing suite labels Feb 28, 2024
@mvo5
Copy link
Contributor

mvo5 commented Feb 28, 2024

The third option would be to fix autopep8, it's strange issues, afaict stock autopep8 is fine, it only acts strongly inside a virtualenv (like the one that tox creates automatically). So we have a fourth option (not a good one, mind you): run autopep8 in a container with python3.12 and without virtualenv.

But if ruff is close enough to the autopep8 output that might be the most pragmatic way forward. I would prefer not to have too many source file re-formated in the process though, I find it makes git blame harder to follow.

@supakeen
Copy link
Member Author

@mvo5 For your second concern, we have a .git-blame-ignore-revs file that we can add any auto formatting commit to which should then be ignored by git blame (though I'm unsure if this is configuration or default behavior).

As far as your first idea, yes it'd be nice to fix up autopep8 however I think the virtual environment behavior is a red herring. The other reports had different versions of Python inside their virtual environments and I have yet to theorize a reason as to why a package would act differently given all versions the same in a virtual environment.

@supakeen
Copy link
Member Author

autopep8 was fixed in #1661.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous Integration Failures tests change related to our testing suite
Projects
None yet
Development

No branches or pull requests

2 participants