fix: correct import sorting and pin tool versions to fix CI lint#153
fix: correct import sorting and pin tool versions to fix CI lint#153Ckk3 wants to merge 5 commits intogazorby:mainfrom
Conversation
📝 WalkthroughWalkthroughThis PR updates development tooling configurations by upgrading ruff to v0.14.10 with version pinning, updating CI cache identifiers, adjusting pre-commit and mise task invocations to use qualified paths, and expanding pyproject.toml source paths and exclusions. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #153 +/- ##
=======================================
Coverage 94.28% 94.28%
=======================================
Files 69 69
Lines 5814 5814
Branches 770 770
=======================================
Hits 5482 5482
Misses 190 190
Partials 142 142 ☔ View full report in Codecov by Sentry. |
…classification The ruff `src = ["src/strawchemy"]` setting caused ruff to auto-detect subdirectories like `sqlalchemy/` and `strawberry/` (from __pycache__) as first-party packages. Changed to `src = ["src"]` so only `strawchemy` is detected as a source package. Also pinned ruff in pre-commit unasyncd hook to prevent version drift.
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.pre-commit-config.yaml:
- Line 59: The YAML uses spaced bracket array syntax which triggers yamllint
`brackets` errors: update the entries for additional_dependencies to use compact
brackets without spaces (e.g., change additional_dependencies: [
"ruff>=0.14.10,<0.15" ] to additional_dependencies: ["ruff>=0.14.10,<0.15"]) and
make the same change for the other occurrence; ensure you only remove the space
after `[` and before `]` while keeping the string contents unchanged.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 6c59009c-88d6-4b92-8a94-a0bddc589d9b
⛔ Files ignored due to path filters (1)
uv.lockis excluded by!**/*.lock
📒 Files selected for processing (4)
.github/workflows/ci.yaml.pre-commit-config.yamlmise.tomlpyproject.toml
| hooks: | ||
| - id: unasyncd | ||
| additional_dependencies: [ "ruff" ] | ||
| additional_dependencies: [ "ruff>=0.14.10,<0.15" ] |
There was a problem hiding this comment.
Fix YAML bracket spacing to clear lint errors.
Line 59 and Line 76 use spaced bracket style that triggers YAMLlint brackets errors.
Proposed fix
- additional_dependencies: [ "ruff>=0.14.10,<0.15" ]
+ additional_dependencies: ["ruff>=0.14.10,<0.15"]
...
- types: [ python ]
+ types: [python]Also applies to: 76-76
🧰 Tools
🪛 YAMLlint (1.38.0)
[error] 59-59: too many spaces inside brackets
(brackets)
[error] 59-59: too many spaces inside brackets
(brackets)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In @.pre-commit-config.yaml at line 59, The YAML uses spaced bracket array
syntax which triggers yamllint `brackets` errors: update the entries for
additional_dependencies to use compact brackets without spaces (e.g., change
additional_dependencies: [ "ruff>=0.14.10,<0.15" ] to additional_dependencies:
["ruff>=0.14.10,<0.15"]) and make the same change for the other occurrence;
ensure you only remove the space after `[` and before `]` while keeping the
string contents unchanged.
Description
Fix CI lint failures caused by incorrect import sorting (I001 errors) and tool version drift between local and CI environments.
Root cause: A stale
.ruff_cachelocally masked import sorting errors. Ruff auto-detectedstrawberryas first-party (due to__pycache__artifacts insrc/strawchemy/strawberry/), while CI correctly classified it as third-party.Changes:
strawberry(third-party) fromstrawchemy(first-party)pyproject.toml(>=0.14.10,<0.15)2025.12.12(matchingtools/misewrapper)tools/misepath, fixlanguage: systemrender:usagetask to usetools/miseTypes of Changes
Issues Fixed or Closed by This PR
N/A
Checklist
Summary by CodeRabbit