-
-
Notifications
You must be signed in to change notification settings - Fork 25.5k
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
MNT replace flake8 with ruff #26630
MNT replace flake8 with ruff #26630
Conversation
Linting PassedAll linting checks passed. Your pull request is in excellent shape! ☀️ |
|
but the linter bot comment is still sunny. |
I tried the pre-commit hook locally and it's green:
|
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.
LGTM, lets merge it and see if it works.
Maybe the linter should do something like:
so that we can access the raw output of the |
@ogrisel the next step (comment) already prints the log, so you can see that there. The failure in the linter is really not supposed to happen in usually though. This is very specific to this PR (or changing linting tools / dependencies) which we do very rarely. |
Yes I found out, after commenting: https://github.com/scikit-learn/scikit-learn/actions/runs/5322327168/jobs/9638664632#step:6:16 What @thomasjpfan implies above is that 6188b36 will only have an effect once this PR is merged because it's a change in the workflow file? If so, +1 for merge. |
Note, I think this is causing CI runs more recent than this PR (?) that have not rebased with main to fail 'linter / lint (pull_request_target)' with error:
Though confusingly github actions bot tells you that 'Linting Passed'. Solved by rebasing with main. cc @adrinjalali |
@lucyleeow #26638 should fix the issue. |
@adrinjalali Thanks for pushing ruff! |
This replaces
flake8
withruff
(https://github.com/astral-sh/ruff), which is significantly faster thanflake8
, and can also fix many of the reported issues automatically (inpre-commit
hooks).Once this is merged, we can then introduce import sorting (instead of using
isort
) throughruff
as well (and more linting).cc @thomasjpfan @ogrisel