Buildkite "No command to run" in CI
A Buildkite command step must define a command (or a script to run). If none is set, the agent reports "No command to run" because there is nothing to execute.
What this error means
A step fails immediately with "No command to run" and no command output, usually right after a pipeline change.
Preparing working directory
No command to run
The command exited with status 1Common causes
The step defines no command
A step has only a label or attributes but no command/commands, so there is nothing for the agent to execute.
A generated step dropped its command
A dynamic pipeline emitted a step whose command was templated to an empty string, leaving an empty command step.
How to fix it
Add an explicit command
- Open the step that failed and confirm it has a
commandorcommandskey. - Add the command it should run, or remove the step if it was meant to be a wait/block.
- Re-run the build.
steps:
- label: "build"
command: "make build"Guard templated commands
In a generated pipeline, refuse to emit a step when its command variable is empty so an empty step never reaches upload.
How to prevent it
- Require a non-empty command on every command step in review.
- Validate generated steps have a command before uploading.
- Use wait/block steps explicitly instead of empty command steps.