Skip to content

Commit 9e230b3

Browse files
committed
Improve docs about pre-commit and mypy
1 parent 3483dfa commit 9e230b3

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,13 @@ repos:
5151
"types-tabulate",
5252
"types-urllib3",
5353
]
54-
# Unfortunately, `pre-commit` only runs on changed files
54+
# Unfortunately, `pre-commit` only runs on modified files
5555
# This doesn't work well with `mypy --follow-imports error`
5656
# See: https://github.com/pre-commit/mirrors-mypy/issues/34#issuecomment-1062160321
5757
#
5858
# To work around this we run `mypy` only in manual mode
59-
# So it won't run as part of `git commit` command
60-
# But it will still be run as part of `pre-commit` workflow and give expected results
59+
# So it won't run as part of `git commit` command,
60+
# but it will still be run as part of `pre-commit` workflow and give expected results
6161
stages: [manual]
6262

6363
# Autoformat: YAML, JSON, Markdown, etc.

docs/contributing/lint.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ pre-commit run --all-files --hook-stage manual
3838
```
3939

4040
```{note}
41-
We're running `pre-commit` with `--hook-stage manual`, because works with changed files, which doesn't work well for mypy.
41+
We're running `pre-commit` with `--hook-stage manual`, because `pre-commit` is run on modified files only, which doesn't work well with `mypy --follow-imports error`.
4242
More information can be found in [`.pre-commit-config.yaml` file](https://github.com/jupyter/docker-stacks/blob/main/.pre-commit-config.yaml)
4343
```
4444

0 commit comments

Comments
 (0)