fix(engine): add degraded_success status and verification reporting#62
Open
mvanhorn wants to merge 3 commits intodanshapiro:mainfrom
Open
fix(engine): add degraded_success status and verification reporting#62mvanhorn wants to merge 3 commits intodanshapiro:mainfrom
mvanhorn wants to merge 3 commits intodanshapiro:mainfrom
Conversation
Adds infrastructure to prevent false-green outcomes when verification commands fail due to transient infra issues: - New StatusDegradedSuccess stage status that routes like success but signals that required verification was blocked or failed - New Verification and VerificationEntry types on Outcome for structured verification reporting (status, blocked_reason, command results) - Updated stage status contract preamble to instruct agents to use degraded_success when verification is blocked - degraded_success routes like success in the engine (retry reset, goal gate, parallel completion) so runs continue correctly Fixes danshapiro#50 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…i/ paths - Add gpt-5.3-codex-spark to cliOnlyModelIDs map (fixes TestIsCLIOnlyModel) - Replace root .ai/verify_errors.log and .ai/test-evidence/latest/ with run-scoped .ai/runs/$KILROY_RUN_ID/ paths in demo spec (fixes TestReferenceSurfaces_NoLegacyRootAIScratchPaths) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
Fixes #50
Summary
When verification commands (tsc, pytest, go test) fail due to transient infra issues (DNS failures, missing tools), stages still reported unqualified success. This adds the foundation to properly track and report verification outcomes.
Changes
New status:
degraded_success(runtime/status.go)StatusDegradedSuccessto the canonical status enumsuccessin the engine (retry reset, goal gate, parallel completion)degraded_success,degraded-success,degradedsuccessIsCanonical()checkVerification types (
runtime/status.go)VerificationResult- captures overall verification status (passed/failed/blocked), blocked reason, and individual command resultsVerificationEntry- records command, exit code, blocked flag, and reasonVerification *VerificationResultfield toOutcomeEngine routing (
engine/engine.go)degraded_successresets retry counters (like success)degraded_successpasses goal gate checks (like success)FinalSuccesswhen stages reportdegraded_successAgent instructions (
prompts/stage_status_contract_preamble.tmpl)degraded_successwith verification details when verification commands fail or are blocked by infra issuesTest plan
TestParseStageStatus_CanonicalAndLegacy- degraded_success and aliases parsed correctlyTestStageStatus_IsCanonical- degraded_success is canonicalTestDecodeOutcomeJSON_DegradedSuccessWithVerification- full verification object preserved through decodeTestDecodeOutcomeJSON_SuccessWithPassedVerification- verification data preserved on normal success toogo build ./...compiles cleanlyThis contribution was developed with AI assistance (Claude Code).