Repository navigation
v3.0.0
First release of the v3 ground-up rewrite. Not backwards-compatible with pyModeS 2.x. See the migration guide before upgrading.
pip install "pyModeS>=3"Python 3.11+ required.
Highlights
- One unified
decode()function. Returns aDecodeddict with every decodable field populated in a single call. Handles single hex strings or batched lists with per-message timestamps; errors become error-dicts instead of exceptions. - Stateful streaming via
PipeDecoder. Per-ICAO state, automatic even/odd CPR pair matching, TTL eviction, and DF20/21icao_verifiedpromotion from a trusted-address set populated off clean DF17/18 frames. - Reference-assisted Comm-B disambiguation. BDS 5,0 vs 6,0 ambiguity is resolved by scoring candidates against cached groundspeed / track / heading / mach when passed via
known=, or automatically inPipeDecoder. - New
modesCLI with two subcommands:modes decode— one-shot, inline-batch, or file-based hex→JSONmodes live --network HOST:PORT— streaming TCP → JSON lines, with sub-microsecond timestamps derived from the Mode-S Beast MLAT counter (tick rate auto-calibrated, so dump1090 and radarcape/AirSquitter both work without config)modes live --tui— interactive textual-based aircraft table with keyboard navigation, live incremental search, sort cycling, and diff-update cell redraws (requirespyModeS[tui]extra)
- Pure Python. Dropped the Cython
c_commonextension and the numpy hard dependency. Internal representation is Pythonint+ bit-shift primitives; no wheel build per Python version. - Airport database for surface CPR:
surface_ref="EHAM"orsurface_ref=(lat, lon). - Optional
full_dict=Truepopulates every key in the 123-field canonical schema for pandas / parquet workflows.
Breaking changes
- Legacy function-per-field API removed (
pms.adsb.callsign,pms.commb.bds,pms.common.hex2bin, etc.). The old submodule paths are intercepted by a meta-path finder that raisesV2APIRemovedError(ImportErrorsubclass) with a migration hint.pyModeS.commonhelpers are restored aspyModeS.util(hex2bin,bin2int,hex2int,crc,df,icao,typecode,altcode,idcode,cprNL). - Python 3.11+ minimum (was 3.9+).
- numpy is no longer a dependency.
modesliveCLI entry point replaced bymodes live/modes decode. The oldmodeslivescript prints a migration hint and exits code 2 instead of vanishing.- CPR resolution API:
reference=(lat, lon)for airborne (180 NM tolerance),surface_ref="EHAM"orsurface_ref=(lat, lon)for surface (45 NM tolerance).
Staying on v2
pip install "pyModeS<3"v2 and v3 share the same PyPI distribution slot; pinning <3 keeps you on the 2.x line indefinitely.
Full changelog
See CHANGELOG.md for the complete list of added / fixed / changed / removed items.
Full diff: v2.22.0...v3.0.0