rety runs mypy, Pyright, Pyrefly, and ty on the same Python code, normalizes their diagnostics, and shows where they agree, where they disagree, and why.
$ rety check src/
src/api.py ────────────────────────────────────────────────
3/4 * HIGH L42 in handle_request [Call]
mypy error 42:18 Argument 1 to "process" has incompatible type "str"; expected "int" [arg-type]
pyright error 42:18 Argument of type "str" cannot be assigned to parameter "x" of type "int" [reportArgumentType]
pyrefly error 42:18 Expected `int`, got `str` [bad-argument-type]
Install
pipx install rety
# or
uv tool install rety
Usage
rety check src/ # run all available checkers
rety check --checker mypy,pyright src/ # run specific checkers
rety check --format json src/ # machine-readable output
rety check --verbose src/ # show why diagnostics were grouped
rety check --fail-on error src/ # exit 1 on errors (for CI)
rety check --python .venv/bin/python src/ # make every checker use your project's environment
Exit codes
| Code | Meaning |
|---|---|
0 |
Run completed and the --fail-on threshold was not met |
1 |
The --fail-on threshold was met |
2 |
Usage error, no checker available, or --require-all not satisfied |
3 |
A checker crashed, timed out, or rejected its config (the report is incomplete) |
By default (--fail-on none) rety exits 0 whenever the run itself succeeded, regardless of what the checkers found.
Confidence scores
Confidence reflects cross-checker evidence only:
| Badge | Meaning |
|---|---|
* HIGH |
Two different checkers report exactly the same line range |
~ MED |
Two different checkers report overlapping line ranges, or share an enclosing statement/--line-tolerance and belong to the same code family |
- LOW |
Joined only through a shared enclosing statement or --line-tolerance (different code families), or a single checker reported here |
Use as a library
from rety import ALL_ADAPTERS, run_checkers
from rety.align import align
adapters = [ALL_ADAPTERS[name]() for name in ("mypy", "pyright")]
results = run_checkers(adapters, paths=["src"], cwd="/path/to/project")
diagnostics = [d for r in results if r.succeeded for d in r.diagnostics]
for cluster in align(diagnostics, root="/path/to/project"):
print(cluster.checkers_present, cluster.confidence, cluster.file)
Development
uv sync --all-groups
uv run pytest -q
uv run mypy src
uv run ruff check src tests
License
Metadata
Release files for rety 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| rety-0.2.0.tar.gz | 41.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| rety-0.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 93.7 kB
Release files / rety-0.2.0.tar.gz
| Download URL | rety-0.2.0.tar.gz |
|---|---|
| Size | 41.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d457a1fed413781a9a8fcdda66c98bf7fe868650cb7dc189aca6da6400d075ca
|
|
BLAKE2b-256 checksum How to use checksums |
996c972c4c67b55e123b30c98ab87d1ece27b3d6b135120b3690cf6d33a35120
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 9, 2026.
Transparency logRelease files / rety-0.2.0-py3-none-any.whl
| Download URL | rety-0.2.0-py3-none-any.whl |
|---|---|
| Size | 52.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b67058b05b6aea69a01d19ffbeae053bf28575e95f92ac85dbdebdb6abb1be3f
|
|
BLAKE2b-256 checksum How to use checksums |
52808035e2d2fd8cda9f46fc853f944bf80af3a74930cf2eabab95683826993c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 9, 2026.
Transparency log