error: reviewdog: not found: install reviewdog before running the review step
Fixes 'error: reviewdog: not found' in CI review steps. Use when the workflow calls reviewdog but nothing installed it on the runner. Covers the official setup action, go install, and version pinning. Not for reviewdog flag errors or diff and annotation failures.
TL;DR
The runner image does not ship reviewdog. Install it in a step before the review step, pin the version so builds stay reproducible, and the command resolves. This is a missing tool, not a config bug.
The error
error: reviewdog: not found: install reviewdog before running the review stepSteps
1. Confirm it is really missing
Add a debug step or check the log for the command resolution:
which reviewdog || echo "not installed"Expected output: "not installed", confirming the diagnosis.
2. Install with the official setup action
Add this step before the review step:
- uses: reviewdog/action-setup@v1
with:
reviewdog_version: v0.17.2Expected output: reviewdog lands on PATH at the pinned version.
3. Or install with go install
On runners with Go available:
go install github.com/reviewdog/reviewdog/cmd/reviewdog@v0.17.2Make sure the Go bin directory is on PATH afterward. Expected output: reviewdog --version prints v0.17.2.
4. Pin the version everywhere
Use the same pinned version in every workflow that calls reviewdog. Unpinned installs drift and break flag compatibility. Expected output: all review steps report the same version.
5. Re-run the review step
Expected output: reviewdog runs instead of the not-found error.
When to use
- The exact "reviewdog: not found" error
- New workflows or new runner images
- Self-hosted runners with minimal tooling
When not to use
- reviewdog flag or usage errors (it installed but the call is wrong)
- Diff, filter, or annotation failures
- Permission errors posting reviews
Tool compatibility
- reviewdog/action-setup v1
- Go toolchain 1.20 and later for go install
- GitHub-hosted and self-hosted runners
Variant phrasings
reviewdog command not found in GitHub Actions
Same fix. The hosted images do not include it.
install reviewdog in CI pipeline
The setup action is the shortest path. Pin the version.
reviewdog version mismatch between jobs
Pin one version in a shared workflow or a central env var and reference it everywhere.
Why it happens
GitHub-hosted runner images include common tools but not reviewdog. A step that calls it directly fails at command resolution before reviewdog ever runs, which is why the error message tells you to install it first.
Edge cases
- Self-hosted runners: install once on the image instead of per run to save time.
- PATH issues: go install puts the binary in the Go bin dir. Add it to PATH or the next step still cannot find it.
- Version drift: a floating install can pull a release that renames flags. Pinning avoids surprise breakage.
- Caching: cache the tool directory on self-hosted runners to keep installs fast.
Provenance
Resolved from the public thread: https://vectle.com/posts/pst_ODWMkxp0zeuJkGIaIvyWFw