Skip to main content

AWX/Ansible Log Viewer

A fast, keyboard-driven terminal UI for exploring AWX/Ansible logs. It supports multi-select filtering (hosts, tasks, statuses), quick error navigation, and a clean status/bottom bar experience powered by prompt_toolkit.

Buy Me a Coffee

Features

  • Multi-select filters: choose multiple hosts, tasks, and statuses at once.
  • Ordered statuses: always shows ok, changed, unreachable, failed, skipping.
  • Host stats in dialog: per-host T/C/F/U/S counts for quick triage.
  • Error navigation: jump to next/previous failed or unreachable line.
  • Collapsing/expanding: fold sections to focus on what matters.
  • Copy selection: Ctrl+C copies selected text via OSC 52 when possible.
  • Safe exit: Q prompts for confirmation; Ctrl+X exits immediately.

Requirements

  • Python 3.10+
  • prompt_toolkit 3.x

Install

# Install from PyPI
pip install ansible-logviewer

# Run
ansible-logviewer path/to/logfile.log

Or install from source:

# (optional) create a virtualenv
python3 -m venv .venv
source .venv/bin/activate

pip install .

Key Bindings

  • Q: Exit (with confirmation)
  • Ctrl+X: Exit immediately
  • Ctrl+C: Copy selection (or exit when no selection)
  • W / Up: Move up
  • S / Down: Move down
  • PageUp / PageDown: Scroll by blocks
  • A / Left / -: Collapse current section
  • D / Right / +: Expand current section
  • F: Open filter dialog
  • N: Next error (failed/unreachable)
  • P: Previous error (failed/unreachable)
  • Ctrl+R: Clear all filters

Filter Dialog

  • Categories: Hosts, Tasks, Statuses (TAB switches categories)
  • Navigation: Up/Down to move; Space to toggle selection
  • Actions: A (select all), C (clear), Enter (apply), ESC/Ctrl+X (cancel)
  • Host stats legend: T=Total, C=Changed, F=Failed, U=Unreachable, S=Skipped

Notes

  • Status list is always shown in order: ok, changed, unreachable, failed, skipping (even if some don’t appear in the current file).
  • Error navigation respects active filters and collapsed state (errors in collapsed sections won’t appear in the rendered body until expanded).

Options

  • --highlight-style underline|color|both: Style for search match highlights (default: underline)
  • --search-mode keyword|regex|both: Search mode (default: both)
  • --debug: Write debug output to debug.log in the current directory

Troubleshooting

  • If Ctrl+X doesn’t work in your terminal, use Q (with prompt) to exit.
  • If copying via Ctrl+C doesn’t reach the system clipboard, your terminal may not support OSC 52; the text is still copied internally.

Project Structure

  • ansible_logviewer/cli.py: application entrypoint and UI wiring
  • ansible_logviewer/log_manager.py: parsing, indexing, filtering, and navigation logic
  • ansible_logviewer/kb.py: key bindings and modal dialogs
  • ansible_logviewer/ui.py: styles and status/bottom bar rendering
  • ansible_logviewer/lexer.py: syntax highlighting for log lines

Contributing

License

This project is licensed under the MIT License - see the LICENSE file for details.

Author

Raymond Rizzo

Metadata

Release files for ansible-logviewer 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ansible-logviewer 1.0.1
File Size Uploaded Provenance
ansible_logviewer-1.0.1.tar.gz 17.2 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for ansible-logviewer 1.0.1
File Interpreter ABI Platform
ansible_logviewer-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 35.3 kB

Release files / ansible_logviewer-1.0.1.tar.gz

Download URL ansible_logviewer-1.0.1.tar.gz
Size 17.2 kB
Tags Source
SHA-256 checksum
How to use checksums
6786fc56d566533163d50b727f62d9bb5c4847098018e5fc793c90ff898d43a6
BLAKE2b-256 checksum
How to use checksums
cc1c25b171bbb47a641927f5234af04875b2410062ac12df70790cf0f8750fef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 25, 2026.

Transparency log

Release files / ansible_logviewer-1.0.1-py3-none-any.whl

Download URL ansible_logviewer-1.0.1-py3-none-any.whl
Size 18.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bb2adc5c0a644d8b6044d607557f9b1874cb1b849093b16b6c5c4bf5d0febce0
BLAKE2b-256 checksum
How to use checksums
f969074d3f83d2e4d7ea089879f272607ae4f00372abf00ab56273cb8354865a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 25, 2026.

Transparency log

Security for ansible-logviewer 1.0.1

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.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for ansible_logviewer-1.0.1.tar.gz

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 Mar 25, 2026.

Transparency log

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.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files Full provenance

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