Building the product · Edition No. 55 · 19 Oct 2026

python/mypy

The reference type checker for Python, run from the command line.

← Building the productRead the whole edition →
mypy: the reference type checker. Reads the code and reports mismatched types.

20.7k stars · MIT · 2.4.0 (2026-10-01, from the Python package index) · Track this in Scout

The reference type checker for Python, run from the command line.

▶Repo detailsthe review · specs · pros & cons · install

What it does

You add type annotations to your Python source. An annotation is a short note that says what kind of value a function takes and what kind it returns. Then you run mypy over the files, and it reads the code without running any of it, follows values from one function into the next, and prints each mismatch with a numbered error code. It knows the standard library, and it reads the type information that installed packages ship with themselves. Strictness is a dial: you can start with one file and no annotations and add one flag at a time, or turn on --strict and work through the list that comes back. It also ships mypyc, a compiler that turns annotated Python into a C extension module, which is how the checker itself is made fast. Release 2.4.0 was published on 1 October 2026, and code was pushed to the repository on 19 October 2026. It does not find mistakes in your logic, it does not check anything while a program is running, and it does not change the way the code is written.

Why it matters

Who it suits.

Anyone looking after a Python codebase of more than a few files, and above all one with several authors. The gain is largest at the edges of a program, where a value arrives from a web request, a file or a database and could be anything at all. It also suits a team that wants one place to settle an argument about what the typing rules actually say. Skip it if the project is a single script that can be read end to end, because writing the annotations will cost more than they return.

Verdict.

This is the reference implementation, and the typing rules for Python are written against it, so when two checkers disagree this is the one that settles it. It is also the slowest of the serious options, which matters if the checking is meant to happen while you type. Treat the choice as a pairing rather than a contest: one of the fast checkers in the editor, this one in the step that runs before code is merged. Edition 44 covered astral-sh/ty and Edition 47 covered facebook/pyrefly, both written in Rust and both much quicker, and microsoft/pyright is the one already built into Visual Studio Code. The project is plainly alive: code was pushed on 19 October 2026 and release 2.4.0 is three weeks old. One thing to read before redistributing it: the licence is MIT, but parts of the tree carry other licences.

Stars20.7k
LicenceMIT
Latest2.4.0 (2026-10-01, from the Python package index)
Good
  • The reference checker, so its reading of an unclear rule is the one that counts.
  • Switches on gradually. One file, one flag, one module at a time.
  • Every error code is documented, so a confusing message can be looked up.
Watch for
  • Slow on a large codebase next to the checkers written in Rust.
  • Some error messages take a few readings before they make sense.
  • The licence is MIT, but parts of the tree carry other licences, including the Python Software Foundation licence.
Similar repositories
Install
python3 -m venv venv
source venv/bin/activate
pip install mypy
mypy your_module.py

On Stack Radar: Build & Ship › Testing & Quality › Browser & E2E Testing.

Get the next edition in your inbox

A dozen repositories, opened and checked. The licence read, the last release dated, and the ones that did not make it named with the reason. It is the half most lists leave out.

No tracking pixels. One click to leave. The archive stays free either way.

We use your address to send the edition and nothing else. Confirm by email, leave in one click. How we handle it.