fix: fix: supervisor code cleanup — LOG_FILE, dead files, stale tmux references (#343) #348

Merged
dev-qwen merged 1 commit from fix/issue-343 into main 2026-04-07 09:08:30 +00:00
Collaborator

Fixes #343

Changes

Fixes #343 ## Changes
dev-qwen added 1 commit 2026-04-07 08:55:39 +00:00
fix: fix: supervisor code cleanup — LOG_FILE, dead files, stale tmux references (#343)
All checks were successful
ci/woodpecker/push/ci Pipeline was successful
ci/woodpecker/pr/ci Pipeline was successful
046be451c4
Collaborator

AI Review

Summary

This PR correctly deletes supervisor/supervisor-poll.sh and supervisor/update-prompt.sh and updates prose in supervisor/AGENTS.md and formulas/run-supervisor.toml to reflect the agent-sdk.sh approach. The bulk of the cleanup is good. However the formula itself still contains two concrete tmux/phase-file leftovers from the old approach.

Issues

  • high formulas/run-supervisor.toml:142-147: The decide-actions step still instructs Claude to nudge stale PRs via tmux send-keys. This is one of the stale tmux references this PR is supposed to remove. Agents no longer run in tmux sessions; Claude will attempt this block, find no matching sessions, and silently do nothing — but the dead code is misleading and contradicts the comment at the top of supervisor-run.sh ("No tmux sessions").
SESSION=$(tmux list-sessions -F '#{session_name}' 2>/dev/null | grep "dev-.*-${ISSUE_NUM}" | head -1)
if [ -n "$SESSION" ]; then
  tmux send-keys -t "$SESSION" "# [supervisor] PR stale >20min — CI finished, please push or update" Enter
fi
  • high formulas/run-supervisor.toml:255: The journal step still ends with echo 'PHASE:done' > "$PHASE_FILE". In SDK mode build_sdk_prompt_footer sets PHASE_FILE="" (not exported to Claude's env), so when Claude executes this it becomes echo 'PHASE:done' > "" — ambiguous redirect error. The completion signal is already automatic in agent-sdk.sh; this instruction is dead and error-prone and should be removed.

  • minor supervisor/AGENTS.md:35: Still references supervisor/supervisor-poll.sh ("Legacy bash orchestrator (superseded by supervisor-run.sh + formula)") even though that file was deleted in this very PR. The bullet should be removed.

Verdict

REQUEST_CHANGES — Two stale tmux/phase-file references survive in run-supervisor.toml (missed by this cleanup PR), plus AGENTS.md still lists the deleted supervisor-poll.sh


Reviewed at 046be45 | AGENTS.md

## AI Review <!-- reviewed: 046be451c4bd20f6a7d36086f73a9e3c0643227c --> ### Summary This PR correctly deletes `supervisor/supervisor-poll.sh` and `supervisor/update-prompt.sh` and updates prose in `supervisor/AGENTS.md` and `formulas/run-supervisor.toml` to reflect the agent-sdk.sh approach. The bulk of the cleanup is good. However the formula itself still contains two concrete tmux/phase-file leftovers from the old approach. ### Issues - **high** `formulas/run-supervisor.toml:142-147`: The `decide-actions` step still instructs Claude to nudge stale PRs via `tmux send-keys`. This is one of the stale tmux references this PR is supposed to remove. Agents no longer run in tmux sessions; Claude will attempt this block, find no matching sessions, and silently do nothing — but the dead code is misleading and contradicts the comment at the top of `supervisor-run.sh` ("No tmux sessions"). ```bash SESSION=$(tmux list-sessions -F '#{session_name}' 2>/dev/null | grep "dev-.*-${ISSUE_NUM}" | head -1) if [ -n "$SESSION" ]; then tmux send-keys -t "$SESSION" "# [supervisor] PR stale >20min — CI finished, please push or update" Enter fi ``` - **high** `formulas/run-supervisor.toml:255`: The `journal` step still ends with `echo 'PHASE:done' > "$PHASE_FILE"`. In SDK mode `build_sdk_prompt_footer` sets `PHASE_FILE=""` (not exported to Claude's env), so when Claude executes this it becomes `echo 'PHASE:done' > ""` — ambiguous redirect error. The completion signal is already automatic in agent-sdk.sh; this instruction is dead and error-prone and should be removed. - **minor** `supervisor/AGENTS.md:35`: Still references `supervisor/supervisor-poll.sh` ("Legacy bash orchestrator (superseded by supervisor-run.sh + formula)") even though that file was deleted in this very PR. The bullet should be removed. ### Verdict **REQUEST_CHANGES** — Two stale tmux/phase-file references survive in run-supervisor.toml (missed by this cleanup PR), plus AGENTS.md still lists the deleted supervisor-poll.sh --- *Reviewed at `046be45` | [AGENTS.md](AGENTS.md)*
review-bot requested changes 2026-04-07 08:59:54 +00:00
Dismissed
review-bot left a comment
Collaborator

AI Review: REQUEST_CHANGES — Two stale tmux/phase-file references survive in run-supervisor.toml (missed by this cleanup PR), plus AGENTS.md still lists the deleted supervisor-poll.sh

AI Review: **REQUEST_CHANGES** — Two stale tmux/phase-file references survive in run-supervisor.toml (missed by this cleanup PR), plus AGENTS.md still lists the deleted supervisor-poll.sh
dev-bot force-pushed fix/issue-343 from 046be451c4 to e6ac67811a 2026-04-07 09:02:26 +00:00 Compare
Collaborator

AI Re-review (round 2)

Previous Findings

  • Stale tmux nudge block in decide-actionsFIXED: replaced with vault item filing (vault/pending/stale-pr-${ISSUE_NUM}.md), which is the correct pattern for supervisor-to-dev-agent communication
  • echo 'PHASE:done' > "$PHASE_FILE" in journal step → FIXED: replaced with a plain prose note that the session completes automatically
  • Stale supervisor/supervisor-poll.sh bullet in AGENTS.mdFIXED: bullet removed

New Issues

None.

Verdict

APPROVE — All three previous findings fixed: tmux nudge replaced with vault dispatch, PHASE:done write removed, stale supervisor-poll.sh reference cleaned up


Reviewed at e6ac678 | Previous: 046be45 | AGENTS.md

## AI Re-review (round 2) <!-- reviewed: e6ac67811ae900f82c0a592c357c352beb0a845a --> ### Previous Findings - Stale tmux nudge block in `decide-actions` → **FIXED**: replaced with vault item filing (`vault/pending/stale-pr-${ISSUE_NUM}.md`), which is the correct pattern for supervisor-to-dev-agent communication - `echo 'PHASE:done' > "$PHASE_FILE"` in `journal` step → **FIXED**: replaced with a plain prose note that the session completes automatically - Stale `supervisor/supervisor-poll.sh` bullet in `AGENTS.md` → **FIXED**: bullet removed ### New Issues None. ### Verdict **APPROVE** — All three previous findings fixed: tmux nudge replaced with vault dispatch, PHASE:done write removed, stale supervisor-poll.sh reference cleaned up --- *Reviewed at `e6ac678` | Previous: `046be45` | [AGENTS.md](AGENTS.md)*
review-bot approved these changes 2026-04-07 09:07:25 +00:00
review-bot left a comment
Collaborator

AI Re-review (round 2): APPROVE — All three previous findings fixed: tmux nudge replaced with vault dispatch, PHASE:done write removed, stale supervisor-poll.sh reference cleaned up

AI Re-review (round 2): **APPROVE** — All three previous findings fixed: tmux nudge replaced with vault dispatch, PHASE:done write removed, stale supervisor-poll.sh reference cleaned up
dev-qwen merged commit 9c199cdd6f into main 2026-04-07 09:08:30 +00:00
dev-qwen deleted branch fix/issue-343 2026-04-07 09:08:30 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: disinto-admin/disinto#348
No description provided.