Skip to main content

navig-blackbox

A free, standalone flight-recorder & crash black-box for any Python app — append-only event log, sys.excepthook crash capture, and sealed .navbox incident bundles — that installs without navig, and also backs the navig blackbox command inside it.

The engine was lifted out of navig-core (navig/blackbox/) into this package so there is one source of truth (the voice/→navig-audio pattern) — navig-core/navig/blackbox/* are now thin re-export shims. Every navig-internal touchpoint (console, atomic writes, paths, version, vault encryption) is routed through navig_blackbox._compat, which uses navig when present and falls back cleanly when it isn't.

Install & use (standalone)

pip install navig-blackbox
nbb status                       # event count, on-disk size, sealed state, data dir
nbb record error "disk full"     # append an event to the recorder
nbb events -n 100                # render the recent event timeline
nbb bundle -o incident.navbox    # seal recent events + crashes + log tails into a .navbox
nbb inspect incident.navbox      # read a bundle back (manifest + timeline)
nbb crashes                      # list captured crash reports
nbb seal / nbb unseal            # freeze / resume recording for an investigation
# also: navig-blackbox --help  ·  python -m navig_blackbox --help

Use as a library (any Python app)

from navig_blackbox import get_recorder, install_crash_handler, EventType

install_crash_handler()                       # unhandled exceptions → ~/.navig/blackbox/crashes/
get_recorder().record(EventType.COMMAND, {"command": "deploy", "args": "prod"})

from navig_blackbox import create_bundle, write_bundle
write_bundle(create_bundle(since_hours=4), "incident.navbox")   # shareable postmortem archive

Inside navig

The command stays navig blackbox … (backed by this engine via the shim); ships as the optional navig[blackbox] extra and registers a free Blackbox module tile. Encrypted .navbox export (--encrypt) uses the navig vault key when navig is present, and falls back to a plaintext archive (with a warning) standalone — data is never lost.

Apache-2.0.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

navig_blackbox-0.1.0.tar.gz (28.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

navig_blackbox-0.1.0-py3-none-any.whl (26.8 kB view details)

Uploaded Python 3

Release history Release notifications | RSS feed

0.1.1

2 files

This release

0.1.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page