fix(zfc): remove Go-side computation and stderr parsing violations
hq-u0ach: done.go - Add --cleanup-status flag so agents can pass cleanup status directly. Removes computeCleanupStatus() which violated ZFC by having Go compute cleanup status from git state. hq-z0zqw: beads.go - Remove strings.Contains parsing for ErrNotARepo and ErrSyncConflict. Per ZFC, Go should transport errors to agents, not parse them to make decisions. IsBeadsRepo() now uses file existence check. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
committed by
Steve Yegge
parent
2f50a59e74
commit
fc8718e680
@@ -84,6 +84,8 @@ func TestIsBeadsRepo(t *testing.T) {
|
||||
}
|
||||
|
||||
// TestWrapError tests error wrapping.
|
||||
// ZFC: Only test ErrNotFound detection. ErrNotARepo and ErrSyncConflict
|
||||
// were removed as per ZFC - agents should handle those errors directly.
|
||||
func TestWrapError(t *testing.T) {
|
||||
b := New("/test")
|
||||
|
||||
@@ -92,11 +94,6 @@ func TestWrapError(t *testing.T) {
|
||||
wantErr error
|
||||
wantNil bool
|
||||
}{
|
||||
{"not a beads repository", ErrNotARepo, false},
|
||||
{"No .beads directory found", ErrNotARepo, false},
|
||||
{".beads directory not found", ErrNotARepo, false},
|
||||
{"sync conflict detected", ErrSyncConflict, false},
|
||||
{"CONFLICT in file.md", ErrSyncConflict, false},
|
||||
{"Issue not found: gt-xyz", ErrNotFound, false},
|
||||
{"gt-xyz not found", ErrNotFound, false},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user