LinuxCommandLibrary

mypy

TLDR

Type check file

$ mypy [script.py]
copy
Type check directory
$ mypy [src/]
copy
Strict mode
$ mypy --strict [script.py]
copy
Ignore missing imports
$ mypy --ignore-missing-imports [script.py]
copy
Show error codes
$ mypy --show-error-codes [script.py]
copy
Check specific Python version
$ mypy --python-version [3.10] [script.py]
copy
Generate HTML report
$ mypy --html-report [report/] [script.py]
copy

SYNOPSIS

mypy [options] files

DESCRIPTION

mypy is a static type checker for Python. It validates type annotations.
The tool catches type errors before runtime. Supports gradual typing adoption.
mypy is Python type checker.

PARAMETERS

FILES

Python files to check.
--strict
Enable strict checking.
--ignore-missing-imports
Skip untyped modules.
--show-error-codes
Display error codes.
--python-version VER
Target Python version.
--help
Display help information.

CAVEATS

Requires type annotations. Third-party stubs may be needed. Optional strict mode.

HISTORY

mypy was created by Jukka Lehtosalo and is developed at Dropbox as the premier Python type checker.

SEE ALSO

python(1), pyright(1), pylint(1)

> TERMINAL_GEAR

Curated for the Linux community

Raspberry Pi 5 8GB

Raspberry Pi 5 8GB

$134.50
GMKtec Gaming PC, K11 AMD Ryzen 9 8945HS, 32GB DDR5 RAM 1TB Mini PC Desktop Computer, Oculink, Dual NIC 2.5GbE LAN, HDMI/DisplayPort/USB4*2

GMKtec Gaming PC, K11 AMD Ryzen 9 8945HS, 32GB DDR5 RAM 1TB Mini PC Desktop Computer, Oculink, Dual NIC 2.5GbE LAN, HDMI/DisplayPort/USB4*2

$739.99
KIWITATA 2X Classic SNES USB Controller for PC Gamings, Retro SNES Wired USB Game Emulator Controller for Windows XP 7 8 11 Mac Raspberry Pi

KIWITATA 2X Classic SNES USB Controller for PC Gamings, Retro SNES Wired USB Game Emulator Controller for Windows XP 7 8 11 Mac Raspberry Pi

$16.99
Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community

Bmax Mini PC B2 Power Intel 5205U 8GB DDR4 256GB M.2 NVMe SSD ,HDMI 1.4&DP 1.2, USB3.2,4K Dual Display 2.4G/5G WiFi & BT5.0 Mini Desktop Computers /Office/Design

Bmax Mini PC B2 Power Intel 5205U 8GB DDR4 256GB M.2 NVMe SSD ,HDMI 1.4&DP 1.2, USB3.2,4K Dual Display 2.4G/5G WiFi & BT5.0 Mini Desktop Computers /Office/Design

$169.99
New Raspberry Pi 3 Model B+ Board Raspberry PI 3B+

New Raspberry Pi 3 Model B+ Board Raspberry PI 3B+

$54.00
GMKtec Gaming PC, K11 AMD Ryzen 9 8945HS, 32GB DDR5 RAM 1TB Mini PC Desktop Computer, Oculink, Dual NIC 2.5GbE LAN, HDMI/DisplayPort/USB4*2

GMKtec Gaming PC, K11 AMD Ryzen 9 8945HS, 32GB DDR5 RAM 1TB Mini PC Desktop Computer, Oculink, Dual NIC 2.5GbE LAN, HDMI/DisplayPort/USB4*2

$739.99