Fix pre-commit version constraint for Python 3.8-3.9 compatibility#59
Conversation
|
Important Review skippedBot user detected. To trigger a single review, invoke the You can disable this status message by setting the Comment |
Co-authored-by: omsherikar <180152315+omsherikar@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR fixes a CI failure on Python 3.8 and 3.9 by updating the pre-commit version constraint to be compatible with older Python versions. Pre-commit 4.x requires Python ≥3.10, while version 3.x supports Python 3.8+.
- Changed pre-commit constraint from a pinned version to a range that supports Python 3.8-3.9
- Ensures compatibility with all Python versions in the CI test matrix (3.8-3.12)
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| flake8>=6.0.0 | ||
| isort>=5.12.0 | ||
| pre-commit==4.3.0 | ||
| pre-commit>=3.5.0,<4.0.0 |
There was a problem hiding this comment.
The PR description mentions an error related to pre-commit==4.5.1, but the actual change in the diff shows the previous version was pre-commit==4.3.0. The description should be updated to reflect the actual version being changed from (4.3.0) rather than 4.5.1, or clarify if there was an intermediate change.
CI was failing on Python 3.8 and 3.9 because
pre-commit==4.5.1requires Python ≥3.10.Changes
requirements-dev.txtto usepre-commit>=3.5.0,<4.0.0instead of pinning to 4.5.1Context
The error from CI:
Pre-commit 3.x supports Python 3.8+, while 4.x requires Python 3.10+. The version constraint now allows installation on all supported Python versions in the test matrix.
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.