feat(#3697): add on_failure mode for comment.completion status notifications - #5736
Conversation
|
🤖 Review · |
Site previewPreview: https://31c7f779-site.fullsend-ai.workers.dev Commit: |
|
🤖 Finished Review · ✅ Success · Started 5:47 PM UTC · Completed 6:01 PM UTC |
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
ReviewFindingsLow
Previous runReviewFindingsLow
Previous run (2)ReviewFindingsLow
Previous run (3)ReviewFindingsMedium
Low
Labels: PR touches core harness internals (internal/cli, internal/config, internal/statuscomment), the GitHub Actions composite action (action.yml), and Go source files. Next steps:
Previous run (4)ReviewFindingsLow
Previous run (5)ReviewFindingsLow
Previous run (6)ReviewFindingsMedium
Low
Next steps:
Previous run (7)ReviewFindingsMedium
Low
Next steps:
Previous run (8)ReviewFindingsMedium
Low
Next steps:
Previous run (9)ReviewFindingsMedium
Low
Next steps:
Previous run (10)ReviewFindingsLow
Previous run (11)ReviewFindingsLow
Previous run (12)ReviewFindingsLow
Previous run (13)ReviewFindingsMedium
Low
Previous run (14)ReviewFindingsMedium
Low
Previous run (15)ReviewFindingsMedium
Low
Previous run (16)ReviewFindingsMedium
Low
Previous run (17)ReviewFindingsCritical
Medium
Low
Next steps:
Previous run (18)ReviewFindingsMedium
Low
Previous run (19)ReviewFindingsMedium
Low
Previous run (20)ReviewFindingsLow
Previous run (21)ReviewFindingsLow
Labels: PR adds a new user-facing config option (on_failure mode) with documentation updates |
PR Summary by QodoAdd on_failure mode for completion status comments
AI Description
Diagram
High-Level Assessment
Files changed (6)
|
|
🤖 Finished Review · ❌ Failure · Started 6:03 PM UTC · Completed 6:04 PM UTC |
Code Review by Qodo
1.
|
waynesun09
left a comment
There was a problem hiding this comment.
Review Squad findings (medium+ severity)
Posting the medium+ findings from a 4-agent review pass (claude-coder, claude-researcher, grok-review-agent, gemini-code-review). Two additional medium findings couldn't be attached inline since they're in files outside this PR's diff:
[MEDIUM] operations.md still documents the old enabled/disabled-only completion values
docs/guides/getting-started/operations.md:150-162 still shows completion: enabled # "enabled" (default) | "disabled", unchanged by this PR — no mention of on_failure. Meanwhile running-agents-locally.md's cross-reference was repointed to the new customizing-agents.md#status-notifications section, leaving two docs pages disagreeing about valid values for the same key. Suggest replacing operations.md's section with a pointer to the new canonical location instead of maintaining two copies.
[MEDIUM] reconcile-status/ReconcileOrphaned ignores status_notifications entirely
internal/cli/reconcilestatus.go and internal/statuscomment/statuscomment.go's ReconcileOrphaned take no config input and always finalize an orphaned marker to "Interrupted" regardless of completion's configured value. This is pre-existing behavior, but this PR turns "silent on success" into a documented guarantee without addressing the narrow race where a process succeeds but is hard-killed before its deferred PostCompletion runs — the reconciler would still surface a false "Interrupted" notice under on_failure. Worth a doc note or a test capturing this known interaction.
f832f7a to
1999cd4
Compare
|
🤖 Review · |
|
🤖 Finished Review · ✅ Success · Started 8:50 PM UTC · Completed 9:04 PM UTC |
20b4437 to
6131423
Compare
|
🤖 Finished Review · ✅ Success · Started 9:38 PM UTC · Completed 9:55 PM UTC |
waynesun09
left a comment
There was a problem hiding this comment.
[HIGH] Required behaviour CI check is red at current HEAD — PR is currently BLOCKED
(Noting this in the review body rather than as an inline comment since the referenced test file, e2e/behaviour/features/dispatch/url-dispatch.feature:26, is not part of this PR's diff.)
The behaviour required check is failing on the PR's current HEAD (6131423) and mergeStateStatus is BLOCKED. This isn't a stale/cached result: commit 6131423 ("fix(#3697): auto-suppress start comment when completion is on_failure") triggered a fresh CI run (run 30493021917, job 90715292701) that ran to completion and failed again — this time with 4 scenarios failing (pr-ping, fork-pr-sync, url-ping, enabled-ping, all failing with a generic "did not complete successfully" error, clustered within a ~26s window around the ~13–14 minute mark of the run) versus only 1 scenario failing on the prior commit's run (1999cd47, run 30489904095).
The changing failure count/set across consecutive runs of the same suite is a strong flake/infrastructure signature (e.g. rate-limiting, a stuck dispatch queue, or the suite's own time-boxed guard pending the harness CEL cutover) rather than a deterministic regression — this PR's diff (docs, internal/config/config.go, internal/statuscomment/statuscomment.go + tests) has zero file overlap with e2e/behaviour or dispatch/harness-resolution code in either commit, which reinforces that this is very unlikely to be caused by this change.
Regardless of root cause: this is a currently-red required check on a PR that GitHub reports as BLOCKED, and it hasn't been raised elsewhere in this PR's comment/review history yet.
Suggestion: Don't merge on a red required check. Re-run behaviour once more (or loop in CI/infra to rule out GitHub API rate-limiting or runner contention) — given the failing scenario set changed between runs and now spans 4 unrelated harness scenarios simultaneously, this looks like shared test-infrastructure flakiness rather than something to fix in this PR's code, but it needs an explicit green run (or a documented infra ticket) before merging.
Superseded by updated review
|
🤖 Finished Review · ✅ Success · Started 8:45 PM UTC · Completed 8:59 PM UTC Commit: |
…ult mode ReasonSkipCommentFailed's "comment failed to post" label asserted a specific cause ReconcileOrphaned can't actually verify — a missing completion comment under on_failure could equally mean the notifier never got set up. Reword it to be outcome-neutral. Also extend orphan synthesis to the default/"enabled" completion mode: previously it only fired for on_failure, leaving the #3635 blind spot open for the common case (agent crashes before posting anything at all). "disabled" mode remains an explicit opt-out and is unaffected. Assisted-by: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Ralph Bean <rbean@redhat.com>
|
🤖 Finished Review · ✅ Success · Started 9:06 PM UTC · Completed 9:18 PM UTC Commit: |
The final commit on this branch (9199342) extended ReconcileOrphaned's synthesis logic to the default "enabled" completion mode, not just on_failure, but the user-facing docs weren't updated to disclose it. Add a line to the Completion modes section explaining the behavior. Reported-by: waynesun09 Assisted-by: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Ralph Bean <rbean@redhat.com>
|
🤖 Finished Review · ✅ Success · Started 2:29 PM UTC · Completed 2:45 PM UTC Commit: |
|
🤖 Finished Retro · ✅ Success · Started 3:34 PM UTC · Completed 4:31 PM UTC Commit: |
Retro: PR #5736 —
|
Summary
on_failureas a valid value forstatus_notifications.comment.completionon_failure, the start comment is silently cleaned up (deleted)on_failureforcomment.start(no outcome to evaluate yet)Phase 1 of #3697 — comment-only changes. Reaction support is a follow-up.
Also extends orphan-comment synthesis (previously
on_failure-only) to the defaultenabledmode: a hard crash before any status comment is posted now surfaces as a synthesized "Interrupted" comment there too. This affects every existing install using the default config, not juston_failureopt-ins. Seedocs/guides/user/customizing-agents.md's Completion modes section.Test plan
on_failurefor completion, rejects for startPostCompletionwithon_failuresuppresses on success, fires on failure/cancelledfullsend run triagewithon_failureconfig on a test issue🤖 Generated with Claude Code