skillfed

tracerite

Human-readable HTML tracebacks for Python exceptions

tracerite v2.6.3 1.2M downloads/30d#4,295 on PyPI13
Permissive license Public Domain Active released

What it is and what it does

TraceRite intercepts Python exceptions and renders them in human-readable formats—HTML for notebooks and web frameworks, colored terminal output for scripts and REPLs, and JSON for machine processing. It displays variable values at each frame, highlights syntax errors, and handles complex exception chains (including Python 3.11+ ExceptionGroups) in chronological order.

The package integrates via a single import in scripts, a Jupyter magic command, or monkeypatching for FastAPI and Sanic. It smartly prunes output to show only relevant context, differentiates between context-manager failures (entry vs. exit vs. expression), and supports custom styling via CSS variables or terminal color configuration. No configuration is required for basic use.

Use it for:

  • Debug Jupyter notebooks by seeing formatted exceptions with variable values instead of raw Python tracebacks.
  • Improve FastAPI error responses with HTML tracebacks that show context and variable state during development.
  • Diagnose concurrent execution errors (ExceptionGroups) in Python 3.11+ with clear visualization of all subexceptions.
  • Format terminal application errors with color and structure for easier reading in long-running CLI tools.
  • Export exception data as JSON for automated error logging, monitoring, or post-mortem analysis systems.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Formats Python exceptions and tracebacks into readable HTML, JSON, and terminal output with variable inspection, working in Jupyter, FastAPI, Sanic, and standard Python scripts.

Yes. TraceRite is actively maintained, has no known vulnerabilities, installs with minimal friction, and solves a real problem—making Python exceptions readable across multiple environments. The permissive public-domain license removes any legal concern. Install it if you spend time debugging Python code in notebooks, web frameworks, or terminals.

Install

tracerite on PyPI

pip

pip install tracerite

uv

uv add tracerite

poetry

poetry add tracerite

Installing tracerite

Before you install

Low friction: pure Python wheel with a single runtime dependency (html5tagger). Active maintenance with a recent release 24 days ago.

License in practice

Public Domain license with permissive treatment means no restrictions on use, modification, or distribution in any context.

Quickstart

pip install tracerite

# In Python script or REPL:
import tracerite
tracerite.load()

# In Jupyter:
%pip install tracerite
%load_ext tracerite

Requires Python 3.10 or later.

Verify before relying

  • Whether variable inspection works equally well across all three output formats (HTML, JSON, terminal).
  • Performance impact of enabling tracerite in long-running applications or high-error-rate scenarios.
  • Compatibility with third-party exception handlers or logging frameworks beyond logging.exception.

Package facts

License Public Domain (permissive)
Python support supports the current Python release (>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 1 — html5tagger
Maintenance actively maintained — 24 days since the last release
Last repo commit
First released
Downloads 1,151,501/month — #4,295 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: tracerite-2.6.3-py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseLicense :: Public DomainOperating System :: OS IndependentProgramming Language :: Python :: 3Topic :: Software Development :: Debuggers

Tags

python traceback formatterpretty print exceptionsjupyter error displayhtml error messagesdebug traceback visualizationexception chain formatterterminal error highlighting
exception-formattingjupyter-integrationdebugging-tools

More Debuggers packages