-
Notifications
You must be signed in to change notification settings - Fork 3
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
Use ruff instead of flake8, isort, black and pyupgrade #202
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #202 +/- ##
==========================================
+ Coverage 85.86% 86.07% +0.20%
==========================================
Files 9 9
Lines 920 919 -1
==========================================
+ Hits 790 791 +1
+ Misses 130 128 -2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
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.
Looks all good! Thanks @danielhollas
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.
Thanks @danielhollas.
I have a few concerns related to the removal of additional hooks that are not related to ruff.
Huh, interestingly, when I added back the ['/pc/clone/LLopfktuRsCG39y1Br0Ylw/py_env-python3/bin/python', '-m', 'build', '--sdist', '.', '--outdir', '/tmp/check-manifest-64gqzu8s-sdist'] failed (status 1):
* Creating venv isolated environment...
ERROR Failed to create venv. Maybe try installing virtualenv.
Command '/tmp/build-env-iai5zihp/bin/python3.11 -m ensurepip --upgrade --default-pip' failed with return code 1
stdout:
/tmp/build-env-iai5zihp/bin/python3.11: No module named ensurepip It doesn't seem like an actual issue, just some missing dependencies. For now I've removed the build-related setup from |
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
aiida-core recently switched to ruff, and I've been using it for my app for some time. IMO we should consider slowly switching AiiDAlab repos as well. @unkcpz @yakutovicha LMK what you think.
I've enabled a couple more rules than there were before, based on my judgment and previous experience. More might be useful, but this is a reasonable start IMO.
I've also removed a couple of hooks that did not seem as useful, now that the codebase and its configuration is quite stable. But I am happy to revert.