Skip to content
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

Add pre-commit #702

Open
adamghill opened this issue Jun 28, 2024 · 1 comment
Open

Add pre-commit #702

adamghill opened this issue Jun 28, 2024 · 1 comment
Labels
good first issue Good for newcomers

Comments

@adamghill
Copy link
Owner

Add configuration for pre-commit.

  • Should include ruff and potentially mypy checks (if it doesn't slow things down too much) -- look at
  • Should this only run on commits to main?
  • Add setup steps to new CONTRIBUTING.md doc (WIP)
@adamghill adamghill added the good first issue Good for newcomers label Jun 28, 2024
@MHLut
Copy link

MHLut commented Jul 4, 2024

I spotted a failing Dependabot issue for Black that was created back in March, which can be a problem for pre-commit:

Sadly, Dependabot does not support pre-commit (nor will it anytime soon). To keep hooks and Python packages in sync, you must manually track hook updates by running pre-commit autoupdate regularly.

A mismatch between the Black Python package and pre-commit hook versions can lead to wrongly formatted code. Similar issues can occur with other quality tools.

I don't have a practical solution for this situation, but it is something to consider.

Cc. @epw1624 (we discovered this during a Zoom call)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants