@@ -11,18 +11,21 @@ flag (or its long form ``--help``)::
11
11
usage: mypy [-h] [-v] [-V] [--python-version x.y] [--platform PLATFORM] [-2]
12
12
[--ignore-missing-imports]
13
13
[--follow-imports {normal,silent,skip,error}]
14
+ [--disallow-any {unimported, expr, unannotated, decorated, explicit, generics}]
14
15
[--disallow-untyped-calls] [--disallow-untyped-defs]
15
16
[--check-untyped-defs] [--disallow-subclassing-any]
16
17
[--warn-incomplete-stub] [--warn-redundant-casts]
17
18
[--no-warn-no-return] [--warn-return-any] [--warn-unused-ignores]
18
- [--show-error-context] [-i] [--quick-and-dirty] [--cache-dir DIR]
19
+ [--show-error-context] [--no-implicit-optional] [-i]
20
+ [--quick-and-dirty] [--cache-dir DIR] [--skip-version-check]
19
21
[--strict-optional]
20
22
[--strict-optional-whitelist [GLOB [GLOB ...]]]
21
23
[--junit-xml JUNIT_XML] [--pdb] [--show-traceback] [--stats]
22
24
[--inferstats] [--custom-typing MODULE]
23
25
[--custom-typeshed-dir DIR] [--scripts-are-modules]
24
26
[--config-file CONFIG_FILE] [--show-column-numbers]
25
- [--find-occurrences CLASS.MEMBER] [--strict] [--strict-boolean]
27
+ [--find-occurrences CLASS.MEMBER] [--strict]
28
+ [--shadow-file SOURCE_FILE SHADOW_FILE] [--any-exprs-report DIR]
26
29
[--cobertura-xml-report DIR] [--html-report DIR]
27
30
[--linecount-report DIR] [--linecoverage-report DIR]
28
31
[--memory-xml-report DIR] [--old-html-report DIR]
@@ -427,13 +430,21 @@ Here are some more useful flags:
427
430
- ``--strict `` mode enables all optional error checking flags. You can see the
428
431
list of flags enabled by strict mode in the full ``mypy -h `` output.
429
432
433
+ .. _shadow-file :
434
+
430
435
- ``--shadow-file SOURCE_FILE SHADOW_FILE `` makes mypy typecheck SHADOW_FILE in
431
436
place of SOURCE_FILE. Primarily intended for tooling. Allows tooling to
432
437
make transformations to a file before type checking without having to change
433
438
the file in-place. (For example, tooling could use this to display the type
434
439
of an expression by wrapping it with a call to reveal_type in the shadow
435
440
file and then parsing the output.)
436
441
442
+ .. _no-implicit-optional :
443
+
444
+ - ``--no-implicit-optional `` causes mypy to stop treating arguments
445
+ with a ``None `` default value as having an implicit ``Optional[...] ``
446
+ type.
447
+
437
448
For the remaining flags you can read the full ``mypy -h `` output.
438
449
439
450
.. note ::
0 commit comments