-
Notifications
You must be signed in to change notification settings - Fork 61
Set up pre-commit #289
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
base: master
Are you sure you want to change the base?
Set up pre-commit #289
Conversation
See status in #279 (comment) - 14 errors left:
I will prepare the needed changes as PR(s) |
Rebased and fixed remaining mypy warnings. All tests in |
This should make workflow runs with linter errors fail faster.
For some reason, I only get this warning when running in github actions.
Updated to run |
@ondras12345 Would you consider to modify this PR such that it comes without the following parts (changes to OMCSession.py) - these clash with PR #295 such that there are big merge conflicts; both points (mypy warning and spelling fix) are included ... |
Proposal
pre-commit
is a nice tool that can be used to run various linters before each commit is made.This PR adds a
.pre-commit-config.yaml
with a basic set of checks and linters. It also fixes typos detected by the codespell check.Currently, the
mypy
check fails:I think @syntron has fixed at least some of these in his fork. I think we should wait for them to be merged before proceeding with this PR.
In the future, we could configure the github actions test workflow to also run linters via pre-commit.