Skip to content

Commit

Permalink
Mention ignore_errors in exclude docs (#18412)
Browse files Browse the repository at this point in the history
  • Loading branch information
hauntsaninja authored Jan 2, 2025
1 parent 025642b commit 8456287
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions docs/source/command_line.rst
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,11 @@ for full details, see :ref:`running-mypy`.
checked. For instance, ``mypy --exclude '/setup.py$'
but_still_check/setup.py``.

In particular, ``--exclude`` does not affect mypy's :ref:`import following
<follow-imports>`. You can use a per-module :confval:`follow_imports` config
option to additionally avoid mypy from following imports and checking code
you do not wish to be checked.
In particular, ``--exclude`` does not affect mypy's discovery of files
via :ref:`import following <follow-imports>`. You can use a per-module
:confval:`ignore_errors` config option to silence errors from a given module,
or a per-module :confval:`follow_imports` config option to additionally avoid
mypy from following imports and checking code you do not wish to be checked.

Note that mypy will never recursively discover files and directories named
"site-packages", "node_modules" or "__pycache__", or those whose name starts
Expand Down

0 comments on commit 8456287

Please sign in to comment.