fix(bin): refuse task id reuse when data directory exists - #2
Open
BohnBawerick wants to merge 2 commits into
Open
fix(bin): refuse task id reuse when data directory exists#2BohnBawerick wants to merge 2 commits into
BohnBawerick wants to merge 2 commits into
Conversation
…chenguid#2570) * fix(bin): report remote secondmate delivery and state truthfully A steer to a remote secondmate crosses fm-on.sh to a host-local fm-send leg whose unconfirmed submit read-back (verdict=pending, typically a busy mate whose harness queues the steer) was flattened into exit 1, so the parent printed "error: text not submitted" / "error: text not sent" and discarded the pending-reply expectation for a steer that had actually landed. fm-send now carries the verdict across the ssh boundary as a documented delivered-unconfirmed exit 3: the parent reports the steer as delivered with confirmation pending, exits 0, keeps the expectation armed (awaiting_report), and closes --resolve-key decisions, while transport loss (ssh 255) and real remote failures keep failing loudly with the remote leg's stderr attached. A local unconfirmed submit now also exits 3 with an honest non-error message and still never closes a decision key. fm-crew-state.sh and fm-peek.sh no longer read a remote mate's endpoint through local probes (which misreported a healthy mate as "worktree gone" / "can't find session: remote"): both now use the true remote source over fm-on.sh, and an unreachable or unreadable remote reads as unknown-remote, never as gone or dead. * no-mistakes(document): Document remote delivery and state truth * no-mistakes: apply CI fixes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Intent
Refuse task id reuse in fm-brief.sh when a data/ directory already exists to protect retained reports and prevent stale task instruction collisions
What Changed
bin/fm-brief.shthat requires a task ID and refuses brief creation if$DATA/<id>already exists, reporting the existing path contents and exiting with an error.tests/fm-brief.test.shverifying task ID reuse refusal across existing files and directories, and updated test teardowns to remove full task data directories.tests/fm-calm-pi-extension.test.shwhen capturing tmux pane contents.Risk Assessment
✅ Low: The change cleanly refuses task ID reuse when a task data directory already exists, protecting retained artifacts with clear error reporting and thorough test coverage.
Testing
Executed targeted unit tests in tests/fm-brief.test.sh and performed end-to-end verification of bin/fm-brief.sh demonstrating refusal on existing data/<id> directories/files and report preservation, with evidence recorded in /tmp/no-mistakes-evidence/01M0AZQVAQWN146YANWJVWCVBY/task-id-reuse-cli-transcript.txt.Evidence: CLI transcript demonstrating task ID reuse refusal and retained report preservation
Source: CLI transcript demonstrating task ID reuse refusal and retained report preservation
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
✅ **Review** - passed
✅ No issues found.
✅ **Test** - passed
✅ No issues found.
bash tests/fm-brief.test.shbin/fm-brief.shtask ID reuse refusal verification across existing retained report, multi-artifact directory, empty directory, existing file, and fresh ID creation✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.