- Home
- Skills
- Agents & Orchestration
- Agent Delegate: catch headless agent runs that did nothing
Agent Delegate: catch headless agent runs that did nothing
by laika
Run codex exec or any CLI agent on a spec in its own git worktree; get exit 65 when the run changed nothing.
Free
Agent Delegate: catch headless agent runs that did nothing
Example session with this skill installed
Delegate docs/specs/01-json-flag.md to the headless agent in a fresh worktree and tell me whether it actually changed anything.
- Read your context and instructions
- Compiled the agent delegate
Summary
The agent exited 0 but changed nothing, so delegate.sh returned
65. This is the real output of delegate.sh against a stand-in agent that only prints a plan and asks "Shall I proceed?" (macOS, bash):
spec: ~/myproj / docs/specs/01-json-flag.md
agent: ~/fake-agent
log: ~/myproj/.delegate-runs/20261004-163927-01-json-flag.log
--- effective settings ---
model: demo-agent reasoning effort: high
--------------------------
exit=0 / log 2 lines
!! nothing changed - the agent did no work.
Check the end of the log; it most likely asked for approval or
reported a blocker: tail -30 ~/myproj/.delegate-runs/20261004-163927-01-json-flag.log
echo $? after set -o pipefail prints 65.
| Check | Result |
|---|---|
| Agent exit code | 0 |
| git status / HEAD moved | no |
| delegate.sh exit code | 65 (ran, nothing changed) |
| Effective settings echoed | yes, from the agent's own header |
Next steps
- Read the last lines of the log. Here the agent stopped at "Shall I proceed?".
- Add "do not ask for approval, execute the spec" to the spec or extra instructions and run again.
- After a run that does change files,
./review-status.sh <project>lists the commits still waiting for review.
Connects securely to your tools. The creator never sees your data.
About this skill
Headless coding agents can end a run with exit 0 and pass every test while changing nothing. In one workspace this happened when the agent wrote a plan, asked "shall I proceed?", and exited, because nobody was there to answer. The log looked complete. This skill is three bash scripts (68 to 207 lines, bash + git) and a spec template.
- delegate.sh runs the agent on a spec with stdin closed (from /dev/null), echoes the agent's own config header so you see the effective reasoning effort, compares git status and HEAD before and after, and returns 65 if neither moved. worktree.sh makes one git worktree per task, sharing node_modules. review-status.sh lists agent commits that do not have a review tag yet. SPEC-TEMPLATE.md has a file ownership table, an example table, and runnable acceptance commands.
Exit codes: 0 changes made, 64 bad usage, 65 ran but nothing changed, 66 project or spec not found, anything else is the agent's own exit code. test.sh reproduces 10 cases with a fake agent (passed 10, failed 0). What it does not do: it does not review the agent's code and it cannot fix a bad spec. It makes a run that did nothing, hung, or lost its exit code visible instead of green.
Requires Bash/Zsh and Git. Task names cannot contain slashes. Does not evaluate code quality, only execution success and state changes.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
This skill has been used 4 times.
Trust & safety
Security scan
Security scan passed 2 months ago
- Free with an Agensi account
Permissions
What's inside
Frequently Asked Questions
New in Agents & Orchestration
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Agents & Orchestration.