-
Notifications
You must be signed in to change notification settings - Fork 2
Ruff precommit #235
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
Ruff precommit #235
Changes from all commits
3b4309d
dab42df
f41646e
0d8e4e6
4ce53c3
e5eab79
ea62d24
2d239fe
9d10da7
a890d52
e3005f5
62231c6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,8 @@ | ||||||||||||||||||||||||||||||||||||||||||||||
| repos: | ||||||||||||||||||||||||||||||||||||||||||||||
| - repo: https://github.com/astral-sh/ruff-pre-commit | ||||||||||||||||||||||||||||||||||||||||||||||
| rev: v0.15.5 | ||||||||||||||||||||||||||||||||||||||||||||||
| hooks: | ||||||||||||||||||||||||||||||||||||||||||||||
| - id: ruff-check | ||||||||||||||||||||||||||||||||||||||||||||||
| args: [ --fix ] | ||||||||||||||||||||||||||||||||||||||||||||||
| # Run the formatter. | ||||||||||||||||||||||||||||||||||||||||||||||
| - id: ruff-format | ||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+2
to
+8
|
||||||||||||||||||||||||||||||||||||||||||||||
| - repo: https://github.com/astral-sh/ruff-pre-commit | |
| rev: v0.15.5 | |
| hooks: | |
| - id: ruff-check | |
| args: [ --fix ] | |
| # Run the formatter. | |
| - id: ruff-format | |
| - repo: local | |
| hooks: | |
| - id: ruff-check | |
| name: ruff-check | |
| entry: ruff | |
| language: system | |
| types: [python] | |
| args: [ --fix ] | |
| # Run the formatter. | |
| - id: ruff-format | |
| name: ruff-format | |
| entry: ruff | |
| language: system | |
| types: [python] | |
| args: [ format ] |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| # packages to install when developing locally | ||
| # these are not required for production, but are useful for development and testing | ||
| pre-commit | ||
| ruff==0.15.7 | ||
|
|
||
| # OPTIONAL, BUT LOVELY FOR DEBUGGING | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. These could be removed. It'd make copilot happier and speed up the CI process. If we want these locally for dev they're super easy to install. The committed code should never need ipdb (or ipython) to run.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. "These" meaning |
||
| ipdb | ||
| ipython | ||
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.
CI is now installing all dev-only dependencies (including
pre-commit,ipdb,ipython) just to runruff. This adds unnecessary packages and can slow/fail CI in ways unrelated to tests/linting. Consider installing only Ruff in this workflow (e.g.,python -m pip install ruff==...) or splitting a smallerrequirements_ci.txtthat contains only CI tools.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.
ignoring this because I want to install the same version of ruff as what is in
requirements_dev.txt