Skip to main content

Debug GitHub Actions workflows locally with step-by-step execution

Project description

gha-debug

Debug GitHub Actions workflows locally with step-by-step execution

License: MIT

Overview

gha-debug is a lightweight CLI tool that helps developers test and debug GitHub Actions workflows locally before pushing to CI. Unlike heavy Docker-based solutions, it provides fast validation, clear step-by-step execution visibility, and helpful error messages.

Installation

pip install gha-debug

Usage

Run a workflow locally

gha-debug run .github/workflows/test.yml

Run a specific job with verbose output

gha-debug run .github/workflows/build.yml --job build --verbose

List all workflows and jobs

gha-debug list

Show environment variables for a job

gha-debug env .github/workflows/deploy.yml --job deploy

Validate workflow syntax

gha-debug validate .github/workflows/*.yml

Features

  • ✅ Parse and validate GitHub Actions workflow YAML files
  • ✅ List all workflows, jobs, and steps with clear formatting
  • ✅ Run workflows locally with simulated GitHub Actions environment
  • ✅ Show detailed step-by-step execution with timing information
  • ✅ Display environment variables and contexts for debugging
  • ✅ Validate workflow syntax and catch common errors before pushing
  • ✅ Colorized output for better readability
  • ✅ Support for filtering by specific job within a workflow

Why gha-debug?

Debugging GitHub Actions workflows is painful:

  • Logs are hard to navigate in the web interface
  • Re-running failed jobs wastes time
  • No simple local testing that mirrors the CI environment

gha-debug solves this by providing a fast feedback loop. It doesn't try to perfectly replicate GitHub's environment (which causes compatibility issues), but instead focuses on what developers need most: quick validation and clear error messages.

Example Output

$ gha-debug run .github/workflows/test.yml

Running workflow: test.yml
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Job: test
  ✓ Checkout code (1.2s)
  ✓ Setup Python 3.11 (0.8s)
  ✓ Install dependencies (4.5s)
  ✓ Run tests (12.3s)

✓ Workflow completed successfully in 18.8s

License

MIT License - Copyright (c) 2026 Intellirim

Project details


Download files

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

Source Distribution

gha_debug-0.1.1.tar.gz (9.9 kB view details)

Uploaded Source

Built Distribution

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

gha_debug-0.1.1-py3-none-any.whl (10.1 kB view details)

Uploaded Python 3

File details

Details for the file gha_debug-0.1.1.tar.gz.

File metadata

  • Download URL: gha_debug-0.1.1.tar.gz
  • Upload date:
  • Size: 9.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.25

File hashes

Hashes for gha_debug-0.1.1.tar.gz
Algorithm Hash digest
SHA256 b672f03e9cd53a9a0f5ad3d0622cd61c55a2b51c29e810b4b106d0df4062269b
MD5 5f079ad4e2ad9dd09cf1fe29a8a070d9
BLAKE2b-256 f1f4a7bc86a8fd5d4a369759215ef65a0367e309534de14c43f64ecc809c772e

See more details on using hashes here.

File details

Details for the file gha_debug-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: gha_debug-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 10.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.25

File hashes

Hashes for gha_debug-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6a43e95e347edf6b1e4a6e69e9c15739ab7718f103026472e1e20834eb766caf
MD5 56b5295cda84bbc832b42420c519fc8d
BLAKE2b-256 2f3dcb5bef41c32eacf7f8120b614aa5cf127cbc44e5798b9bf36361b1a7d0c6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page