TraceTUI
Interactive TUI debugger for logs — a beautiful console interface built on Textual that parses logs (loguru, logging) in real-time, highlights errors, and lets you filter them with arrow keys.
✨ Features
Three-panel interface
- Left panel — list of log sources/files with activity indicators
- Center panel — log stream with color-coded severity levels
- Right panel — selected entry details (traceback, metadata, tags)
Log formats
- loguru —
2024-01-15 10:30:45 | ERROR | module.py:42 - message - logging —
2024-01-15 10:30:45,123 - module.name - ERROR - message - Simple —
ERROR - message - Auto-detect — automatic format detection
Navigation & Control
Log navigation
↑/↓— navigate through logs (by line)- Error blocks are highlighted on hover
Source switching
←/→— switch between sources/log files- Active source is marked with
▸in the left panel
Keyboard shortcuts
| Key | Action | Description |
|---|---|---|
F |
Filter | Filter mode — type text to search |
E |
Next Error | Jump to next error (skip INFO/DEBUG) |
T |
Theme | Switch theme (light/dark) |
Q |
Quit | Exit the application |
Additional capabilities
- Copy traceback to clipboard
- Add custom tags (labels)
- Filter by level and text
- Multiple log file support
- Timeline Merge Mode (
m) — cross-file event timeline with color-coded source tags
📦 Installation
Via pip
pip install tracetui
From source
git clone <repository-url>
cd TraceTUI
pip install -e .
Dependencies
- Python >= 3.10
- textual >= 1.0.0
- rich >= 13.0.0
🚀 Usage
Quick start
# Run with sample logs
tracetui sample_logs/app_standard.log
tracetui sample_logs/app_loguru.log
# Multiple files
tracetui log1.log log2.log log3.log
# With format specification
tracetui -f loguru my_app.log
tracetui -f logging server.log
# Multiple files (timeline mode — press m in UI)
tracetui app.log worker.log scheduler.log
# Filter by level
tracetui -l ERROR app.log
Programmatic usage
from tracetui.app import TraceTUIApp
from tracetui.parsers.log_parser import load_log_source
from pathlib import Path
app = TraceTUIApp()
# Load a file
source = load_log_source(Path("app.log"))
app.add_log_source(source)
# Run
app.run()
🧪 Testing
# Run all tests
pytest
# With verbose output
pytest -v
# With coverage
pytest --cov=tracetui --cov-report=html
📝 Usage examples
Debugging an app with many errors
# Open a log with auto-detect format
tracetui /var/log/myapp.log
# Navigate with arrows to ERROR
# Press Enter to view details
# Check the traceback in the right panel
# Press 'd' to mark as "investigate"
Monitoring multiple files
# Open several logs simultaneously
tracetui app.log worker.log scheduler.log
📄 License
MIT
Metadata
Release files for tracetui 2.0.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 | Provenance | Actions |
|---|---|---|---|---|
| tracetui-2.0.0.tar.gz | 37.3 kB | Without provenance | Details for tracetui-2.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| tracetui-2.0.0-py3-none-any.whl | Python 3 | none | any | Details for tracetui-2.0.0-py3-none-any.whl |
Total release size: 69.0 kB
Release files / tracetui-2.0.0.tar.gz
| Download URL | tracetui-2.0.0.tar.gz |
|---|---|
| Size | 37.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e6483d37f57a6819dac4c8be5863660c3c575b2dd93d08e5570f4c4cb8aa79f1
|
|
BLAKE2b-256 checksum How to use checksums |
a09d60d8f1ac96abccfdddad4d29907304b67e4f06b932dae95fdde1fc638334
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.15.0
|
Release files / tracetui-2.0.0-py3-none-any.whl
| Download URL | tracetui-2.0.0-py3-none-any.whl |
|---|---|
| Size | 31.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
02ae943790a9433e025c11cf4e677c5780e514e739e8684353553bc2aacef118
|
|
BLAKE2b-256 checksum How to use checksums |
a6edb3986ee9aa07f6ab8c16d402c490bda1dbcf81f54acee12742e524a99535
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.15.0
|
Security for tracetui 2.0.0
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.