-
Notifications
You must be signed in to change notification settings - Fork 6
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
Require Python 3.11 and lint #44
Conversation
@coderabbitai review |
✅ Actions performedReview triggered.
|
WalkthroughThe changes in this pull request involve updates to multiple configuration and source files. The Python version matrix in the GitHub Actions workflow has been adjusted to support only versions 3.11, 3.12, and 3.13. The Changes
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
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.
Actionable comments posted: 1
🧹 Outside diff range and nitpick comments (1)
pyproject.toml (1)
23-23
: Consider pinning the ruff version more strictly.Using
>=0.8.1
could lead to inconsistent linting behavior across different environments. Consider using^0.8.1
instead to get compatible updates while avoiding potential breaking changes.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
📒 Files selected for processing (5)
.github/workflows/test.yml
(0 hunks).pre-commit-config.yaml
(1 hunks)pyproject.toml
(1 hunks)ttls/client.py
(4 hunks)ttls/colours.py
(1 hunks)
💤 Files with no reviewable changes (1)
- .github/workflows/test.yml
✅ Files skipped from review due to trivial changes (1)
- .pre-commit-config.yaml
🔇 Additional comments (4)
ttls/colours.py (2)
3-5
: LGTM! Type hints modernized correctly.
The type aliases have been updated to use the new union operator (|
) and built-in generics, which is more readable and aligns with PEP 604.
13-13
: LGTM! Type hint modernized correctly.
The optional type hint has been updated to use the new union operator (|
), which is more readable and aligns with PEP 604.
ttls/client.py (2)
50-50
: LGTM! Type hint modernized correctly.
The type alias has been updated to use the new union operator (|
), which is more readable and aligns with PEP 604.
420-420
: LGTM! Type checks updated correctly.
The isinstance
checks have been updated to use built-in tuple
type instead of typing.Tuple
, which is more efficient and aligns with modern Python practices.
Also applies to: 441-441
@@ -14,13 +14,13 @@ repository = "https://github.com/jschlyter/ttls" | |||
ttls = "ttls.cli:main" | |||
|
|||
[tool.poetry.dependencies] | |||
python = "^3.9" | |||
python = "^3.11" |
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.
💡 Codebase verification
Breaking change: Python version requirement increased from 3.9 to 3.11 without proper documentation
The change increases the minimum Python version from 3.9 to 3.11, which is a breaking change. However:
- No CHANGELOG.md file exists to document this significant change
- The version bump from 1.9.0 is not following semver (should be 2.0.0 for breaking changes)
- No upgrade documentation is provided
Required actions:
- Create a CHANGELOG.md file documenting the Python version requirement change
- Bump version to 2.0.0 to reflect the breaking change
- Add upgrade instructions for users on Python 3.9-3.10
🔗 Analysis chain
Consider the impact of requiring Python 3.11.
This is a breaking change that requires users to upgrade their Python version. Consider:
- Adding a changelog entry
- Incrementing the major version number
- Documenting the upgrade path
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Check if there's a CHANGELOG.md file and if it mentions Python 3.11
fd -t f "CHANGELOG.md" -x grep -l "Python 3.11" {} \;
Length of output: 56
Script:
#!/bin/bash
# Check if CHANGELOG.md exists
fd -t f "CHANGELOG.md"
# Check current version in pyproject.toml
grep "version" pyproject.toml
# Check previous Python version requirement
git show HEAD^:pyproject.toml | grep "python ="
Length of output: 138
Summary by CodeRabbit
New Features
Bug Fixes
Chores