Modern QA2026Debugging GitHub Actions — tiles
Log inJoin
9 / 48 · 16 CI/CD Pipelines · GitHub Actions: A Practical Example← prev⊞ allnext →☰ Read as one page

2.4Debugging GitHub Actions

Debugging workflows is one of the biggest pain points. Here are practical strategies:

  1. Enable debug logging: Set the repository secret ACTIONS_STEP_DEBUG to true for verbose output
  2. Use act locally: The act tool runs GitHub Actions workflows on your local machine, dramatically speeding up iteration
  3. Add diagnostic steps: Insert env and ls -la steps to inspect the environment when something unexpected happens
  4. Check the Actions tab: Failed steps show expandable logs. Look at the last successful step and the first failed step to narrow the issue
  5. Use continue-on-error: true temporarily: Let a failing step continue so you can see the output of subsequent steps for debugging
# Temporary debugging step
- name: Debug environment
  if: failure()
  run: |
    echo "Working directory: $(pwd)"
    ls -la
    env | sort
    cat package.json | head -20