Skip to content

fix(run-guard): surface runaway failures (CHE-11282) [squash] - #2328

Merged
congvc-dev merged 3 commits into
mainfrom
agent/x99-codex-terra/che-11282-4f0088899074
Dec 5, 2026
Merged

congvc-dev merged 3 commits into
mainfrom
agent/x99-codex-terra/che-11282-4f0088899074

Conversation

@congvc-bot-x99

@congvc-bot-x99 congvc-bot-x99 Bot commented Dec 5, 2026 •

Copy link
Copy Markdown

Status

Draft for review. CI passed on the current head.

Conditions

The full local Go run failed. Seven service failures and 43 handler failures reproduce on the base revision. Five other handler tests pass when run separately on the current head. The full handler suite timed out.

Change

Classify standalone provider cybersecurity refusals as failed runs. Show guard modes in budget output. Record overdue run activity and show it in the decision brief. Record the signal atomically when a deferred retry is promoted after its issue becomes overdue.

Blast Radius

Task completion, run admission, deferred promotion, budget output, and the decision brief can be affected. Database-backed tests exercise the changed paths, including concurrent promotion and rollback. Proof level: 3.

Evidence

The deferred retry regression failed before the fix. The focused database-backed checks passed:

go test ./internal/service -run 'TestClaimDeferredRetryRecordsOverdueSignal|TestDeferredPromotion|TestConcurrentDeferredPromotion|TestClaimTasksForRuntimes|TestConcurrentOverdueWakeupsRecordOneSignal' -count=1 -timeout 5m
ok  github.com/multica-ai/multica/server/internal/service  2.120s

The focused handler tests passed from server with DATABASE_URL set to a freshly migrated isolated PostgreSQL database:

MULTICA_TEST_DB_PER_PACKAGE=1 go test -count=1 -timeout 5m -exec "$PWD/../scripts/go-test-db-exec.sh" ./internal/handler -run 'TestCompleteTask_(ContextExhaustionFromOlderDaemonIsRecordedAsFailed|RealAnswerStillCompletes|ProviderPolicyRefusalIsRecordedAsFailed)|TestGetIssueRunBudgetReportsGuardModes|TestOverdueRunReachesBrief'
ok  github.com/multica-ai/multica/server/internal/handler  2.319s

Other focused checks passed for refusal classification, guard modes, CLI output and daily overdue signals. The web failure-label test passed 29 cases; mobile failure-label and badge tests passed 13 cases. The full taskfailure package passed. The full service suite failed seven tests; all seven also failed on base a91aa3dce4e with the same isolated database setup. They cover built-in skill contracts, chat wakeups, workspace capacity, the recovery writer inventory and timeline parity. The handler suite reported multiple failures and timed out at 25 minutes in TestDMProgress_AncestorWalkIsLinearInDepth. Of 48 handler failures, 43 reproduce on base. The other five pass in a fresh focused run on this head. The four handler CI shards passed on this head.

Graph analysis could not uniquely match the shared classifier or PromoteDueDeferredTasksForRuntime; callers were checked by text search instead.

The remaining five handler tests passed on a fresh isolated database:

go test ./internal/handler -count=1 -timeout 5m -run 'TestDecisionRecordDispatchesAgentMention|TestDecisionTopicReplyRefusals|TestDecisionTopicReplyStartsNoStewardTask|TestDecisionTopicReplySurvivesReparent|TestTriggerAutopilot_RuntimeOwnerNeedsNoGrant'
ok  github.com/multica-ai/multica/server/internal/handler  1.985s

Cost delta

Overdue admission adds database reads and at most one activity per issue per day. Deferred promotion adds a transaction per claim poll. Monitor claim latency and failures after release.

Agent-facing: yes
Adoption item: Check run_guard_mode and stop_loss_mode in issue budget output before interpreting the displayed limits.
Adoption mode: default
Adoption proof: server/cmd/multica/cmd_issue_budget_test.go
Adoption signal: Budget output contains both guard modes.
Adoption base: Budget output omitted both guard modes.
Adoption target: Budget output reports both configured modes.

Changelog: Surface disabled run guards, overdue runs, and provider policy refusals.

Closes CHE-11282

@congvc-bot-x99
congvc-bot-x99 Bot marked this pull request as ready for review December 5, 2026 22:06
@congvc-dev
congvc-dev added this pull request to the merge queue Dec 5, 2026
@congvc-bot-x99

congvc-bot-x99 Bot commented Dec 5, 2026

Copy link
Copy Markdown
Author

Merge-Eligibility: REFUSED
Head: 597b6a2
Source: sweep: receipt, review, merger and scope facts unread; coverage_complete and defaulted_paths unread

  • unverified by the sweep: receipt, cross-lab review, merger and scope; only the merge step can decide them

Merged via the queue into main with commit fb60353 Dec 5, 2026
61 checks passed
@congvc-dev
congvc-dev deleted the agent/x99-codex-terra/che-11282-4f0088899074 branch December 5, 2026 22:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant