latest--partial-mypy
shared| Type | object |
|---|---|
| Schema URL | https://catalog.lintel.tools/schemas/schemastore/pyproject/_shared/latest--partial-mypy.json |
| Parent schema | pyproject |
Properties
Specifies the paths to use, after trying the paths from MYPYPATH environment variable. Useful if you'd like to keep stubs in your repo, along with the config file. Multiple paths are always separated with a : or , regardless of the platform. User home directory and environment variables will be expanded.
A comma-separated list of paths which should be checked by mypy if none are given on the command line. Supports recursive file globbing using glob, where * (e.g. *.py) matches files in the current directory and **/ (e.g. **/*.py) matches files in any directories below the current one. User home directory and environment variables will be expanded.
A comma-separated list of packages which should be checked by mypy if none are given on the command line. Mypy will not recursively type check any submodules of the provided module.
A comma-separated list of packages which should be checked by mypy if none are given on the command line. Mypy will recursively type check any submodules of the provided package. This flag is identical to modules apart from this behavior.
A regular expression that matches file names, directory names and paths which mypy should ignore while recursively discovering files to check. Use forward slashes (/) as directory separators on all platforms.
This flag will add everything that matches .gitignore file(s) to exclude (https://mypy.readthedocs.io/en/stable/config_file.html#confval-exclude). This option may only be set in the global section ([mypy]).
Enables PEP 420 style namespace packages. See the corresponding flag --no-namespace-packages for more information.
This flag tells mypy that top-level packages will be based in either the current directory, or a member of the MYPYPATH environment variable or mypy_path config option. This option is only useful in the absence of __init__.py. See Mapping file paths to modules for details.
Suppresses error messages about imports that cannot be resolved.
Makes mypy analyze imports from installed packages even if missing a py.typed marker or stubs.
Directs what to do with imports when the imported module is found as a .py file and not part of the files, modules and packages provided on the command line.
Determines whether to respect the follow_imports setting even for stub (.pyi) files.
Specifies the path to the Python executable to inspect to collect a list of available PEP 561 packages. User home directory and environment variables will be expanded. Defaults to the executable used to run mypy.
Disables using type information in installed packages (see PEP 561). This will also disable searching for a usable Python executable. This acts the same as --no-site-packages command line flag.
Enables reporting error messages generated within installed packages (see PEP 561 for more details on distributing type information). Those error messages are suppressed by default, since you are usually not able to control errors in 3rd party code.
Specifies the Python version used to parse and check the target program. The string should be in the format MAJOR.MINOR (for example, 2.7). The default is the version of the Python interpreter used to run mypy.
Specifies the OS platform for the target program, for example darwin or win32 (meaning OS X or Windows, respectively). The default is the current platform as revealed by Python's sys.platform variable.
Specifies a list of variables that mypy will treat as compile-time constants that are always true.
Specifies a list of variables that mypy will treat as compile-time constants that are always false.
Disallows usage of types that come from unfollowed imports (anything imported from an unfollowed import is automatically given a type of Any).
Disallows all expressions in the module that have type Any.
Disallows functions that have Any in their signature after decorator transformation.
Disallows explicit Any in type positions such as type annotations and generic type parameters.
Disallows usage of generic types that do not specify explicit type parameters.
Disallows subclassing a value of type Any.
Disallows calling functions without type annotations from functions with type annotations. Note that when used in per-module options, it enables/disables this check inside the module(s) specified, not for functions that come from that module(s).
Selectively excludes functions and methods defined in specific packages, modules, and classes from action of disallow_untyped_calls. This also applies to all submodules of packages (i.e. everything inside a given prefix). Note, this option does not support per-file configuration, the exclusions list is defined globally for all your code.
Disallows defining functions without type annotations or with incomplete type annotations (a superset of disallow_incomplete_defs).
Disallows defining functions with incomplete type annotations, while still allowing entirely unannotated definitions.
Type-checks the interior of functions without type annotations.
Allow decorating typed functions with untyped decorators.
Reports an error whenever a function with type annotations is decorated with a decorator without annotations.
Causes mypy to treat arguments with a None default value as having an implicit Optional type.
Inverse of implicit_optional.
By default, imported values to a module are treated as exported and mypy allows other modules to import them. This flag changes the behavior to not re-export unless the item is imported using from-as or is included in __all__. Note this is always treated as enabled for stub files.
Disable treating bytearray and memoryview as subtypes of bytes. This will be enabled by default in mypy 2.0.
Enables or disables strict Optional checks. If False, mypy treats None as compatible with every type.
Warns about casting an expression to its inferred type.
Warns about unneeded # type: ignore comments.
Shows errors for missing return statements on some execution paths.
Shows a warning when returning a value with type Any from a function declared with a non-Any return type.
Shows a warning when encountering any code inferred to be unreachable or redundant after performing type analysis.
Ignores all non-fatal errors.
Causes mypy to suppress errors caused by not being able to fully infer the types of global and class variables.
By default, mypy won't allow a variable to be redefined with an unrelated type. This experimental flag enables the redefinition of unannotated variables with an arbitrary type. You will also need to enable local_partial_types.
Allows variables to be redefined with an arbitrary type, as long as the redefinition is in the same block and nesting level as the original definition.
Disallows inferring variable type for None from two assignments in different scopes. This is always implicitly enabled when using the mypy daemon.
Allows disabling one or multiple error codes globally.
Allows enabling one or multiple error codes globally.
By default, imported values to a module are treated as exported and mypy allows other modules to import them. When false, mypy will not re-export unless the item is imported using from-as or is included in __all__. Note that mypy treats stub files as if this is always disabled.
Make arguments prepended via Concatenate be truly positional-only.
Enable additional checks that are technically correct but impractical.
Prohibit equality checks, identity checks, and container checks between non-overlapping types.
Include None in strict equality checks. Requires strict_equality to be activated.
https://mypy.readthedocs.io/en/stable/config_file.html#confval-strict_equality_for_none
Enable all optional error checking flags. You can see the list of flags enabled by strict mode in the full mypy --help output. The exact list of flags enabled by strict may change over time.
Prefixes each error with the relevant context.
Shows column numbers in error messages.
Hides error codes in error messages. See Error codes for more information.
Use visually nicer output in error messages: use soft word wrap, show source code snippets, and show error location markers.
Shows error messages with color enabled.
Shows a short summary line after error messages.
Show absolute paths to files.
Always use List instead of list in error messages, even on Python 3.9+.
Always use Union[] and Optional[] for union types in error messages (instead of the | operator), even on Python 3.10+.
Enables incremental mode.
Specifies the location where mypy stores incremental cache info. User home directory and environment variables will be expanded. This setting will be overridden by the MYPY_CACHE_DIR environment variable.
Use an SQLite database to store the cache.
Include fine-grained dependency information in the cache for the mypy daemon.
Makes mypy use incremental cache data even if it was generated by a different version of mypy. (By default, mypy will perform a version check and regenerate the cache if it was written by older versions of mypy.)
Skip cache internal consistency checks based on mtime.
Use a new experimental cache format for faster incremental builds. Makes incremental builds up to twice as fast. This is experimental and currently only supported when using a compiled version of mypy.
https://mypy.readthedocs.io/en/stable/config_file.html#confval-fixed_format_cache
A comma-separated list of mypy plugins. See Extending mypy using plugins.
Invokes pdb on fatal error.
Shows traceback on fatal error.
Raise exception on fatal error.
Specifies a custom module to use as a substitute for the typing module.
This specifies the directory where mypy looks for standard library typeshed stubs, instead of the typeshed that ships with mypy. This is primarily intended to make it easier to test typeshed changes before submitting them upstream, but also allows you to use a forked version of typeshed.
Warns about missing type annotations in typeshed. This is only relevant in combination with disallow_untyped_defs or disallow_incomplete_defs.
Causes mypy to generate a text file report documenting how many expressions of type Any are present within your codebase.
Causes mypy to generate a Cobertura XML type checking coverage report.
Causes mypy to generate a text file report documenting the functions and lines that are typed and untyped within your codebase.
Causes mypy to generate a JSON file that maps each source file's absolute filename to a list of line numbers that belong to typed functions in that file.
Causes mypy to generate a flat text file report with per-module statistics of how many lines are typechecked etc.
Causes mypy to generate an XML type checking coverage report.
Causes mypy to generate a JUnit XML test result document with type checking results. This can make it easier to integrate mypy with continuous integration (CI) tools.
Makes script x become module x instead of __main__. This is useful when checking multiple scripts in a single run.
Warns about per-module sections in the config file that do not match any files processed when invoking mypy. (This requires turning off incremental mode using incremental = False.)
Controls how much debug output will be generated. Higher numbers are more verbose.
DEPRECATED and UNDOCUMENTED: Now defaults to true, use hide_error_codes if you need to disable error codes instead.
UNDOCUMENTED: show links for error codes.
UNDOCUMENTED. Disables automatic promotion of bytearray to bytes type. Is set to true in strict mode.
UNDOCUMENTED. Disables automatic promotion of memoryview to bytes type. Is set to true in strict mode.
Enable a preview of incomplete features that are not yet enabled by default by the current version of mypy. Note that it is not guaranteed that all features will be ultimately enabled by default.
Install detected missing library stub packages using pip
Install stubs without asking for confirmation and hide errors, with --install-types