-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
pre-commit: move prospector
inside pre-commit
#10105
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
Conversation
- removes `prospector` check from tox - run `prospector` check inside pre-commit This allows developers to auto-run prospector _before_ pushing changes to GitHub and be able to fix these problems locally in a quicker way.
272fd66
to
a2cadda
Compare
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.
Yes please ❤️
The workflow of waiting for CI to lint things that aren't automatically linted locally is slow. So this will be a relative improvement and most welcome 👍
After doing this, I think we should seriously consider getting a much faster linting process, though. Having https://raw.githubusercontent.com/readthedocs/readthedocs.org/main/requirements/pip.txt
inside pre-commit requirements also seems a bit dramatic.
This is only executed once when the environment is created. Unfortunately, on CircleCI we have to install these requirements each time :/ --but I didn't find a better way of doing this for now. We can explore other alternatives in the future. |
If it makes sense from build times, we could open an issue explore putting |
It seems all of us are more or less on board with this change and the one in common/. We can tune it a little more as we go while finding things that are not working as we expect. Also, we can revert if we find it does not work at all. I'm merging this PR and the one in common as well to start trying this out. |
I think this sounds like a great call, and nothing that cannot be reverted if for some reason it doesn't perform well enough. It shouldn't have any impacts, otherwise since it's the same linter. Because pre-commit is also a local tool, it's much easier to tweak and optimize, and all changes will automatically work in CI 👍 |
prospector
check from toxprospector
check inside pre-commitThis allows developers to auto-run prospector before pushing changes to GitHub and be able to fix these problems locally in a quicker way.
Requires: readthedocs/common#166