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

Detect missing arg for prepare-commit-msg and commit-msg #1341

Merged

Conversation

particledecay
Copy link
Contributor

@particledecay particledecay commented Feb 22, 2020

If using the prepare-commit-msg and commit-msg stages specifically (such as with the try-repo command), the --commit-msg-filename arg must be provided.

Resolves #1336

If using the prepare-commit-msg and commit-msg stages specifically (such
    as with the try-repo command), the `--commit-msg-filename` arg must be
provided.

[fixes pre-commit#1336]

chore: improve error message for hook stage check
@asottile
Copy link
Member

I went ahead and:

  • fixed the linting (lol)
  • added a test
  • fixed the test which was inadvertently tickling this change

Copy link
Member

@asottile asottile left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@asottile asottile merged commit 05f486e into pre-commit:master Feb 23, 2020
@particledecay
Copy link
Contributor Author

Nice... admittedly I was trying to familiarize myself with all the functions you're using in your unit tests but I just haven't had the time this weekend.

@asottile
Copy link
Member

no problem! patch looked good and I wanted to build on it in some other PRs which would have conflicted

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

TypeError: expected string or bytes-like object
2 participants