Debugging GitHub Actions
Trying to figure out a problem with your GitHub Actions?
Because workflows are described with a yaml file, you can validate your formatting locally. There are VSCode extensions to help with this.
You can isolate down to the build step you are interested in and inspect the logs, or run the commands locally. You can run debug versions of tools, attach debuggers, and iterate quickly.
If you’re using GitHub-hosted runners, it’s useful to know which versions of software they have available and which are pre-installed. It’s all documented here.
Lastly, if you are debugging something that requires a whole workflow to execute, you can use act to easily run your workflow locally. I’ve found it to be helpful to iterate faster for extra-tricky situations.