Fix #1431: map verify-approval gate to view-diff in phaseArtifactVerb - #1442
Conversation
Stream Deck's phaseArtifactVerb mapped the spec/plan/dev-approval/pr gates but not verify-approval, so a builder blocked there returned undefined and the Builder Action Automatic press fell back to a terminal instead of the review diff (the #1428 faces already render the gate as blocked, so the key looked gate-blocked but behaved otherwise). Add verify-approval to the gate branch returning view-diff (same as dev-approval/pr: the human is reviewing finished work); the press then resolves view-diff to open-diff-first via BuilderAction.resolveVerb (#1414). Also drop the now-stale face.ts comment noting the resolver gap.
The verify-approval → view-diff mapping also flips reviewMode from 'none' to 'diff' (reviewMode derives from phaseArtifactVerb: view-diff → diff), so a verify-approval-blocked builder's review dials navigate the diff — symmetric with dev-approval/pr and correct while a human reviews finished work. Pin it with an assertion beside the existing dev-approval/pr reviewMode cases.
|
Integration review (streamdeck architect) — APPROVE. Low-risk tier, read line-by-line. The change is one clause added to an existing gate branch ( Board was degraded: codex was environmentally unavailable (OpenAI billing/credits, raised to the owner as an account item), so this shipped on a 2-way CMAP — gemini + claude, both APPROVE HIGH — plus architect source verification, per the interim policy both architects have adopted for low-risk lanes while the outage lasts. That verification earned its place: the two-seat board missed a real untested behaviour change. Because Closes the face/behaviour contradiction introduced by #1428's faces, which already rendered this gate as blocked (yellow + |
Summary
Stream Deck's
phaseArtifactVerbdid not map theverify-approvalgate, so a builder blocked there returnedundefinedand the Builder Action Automatic press fell back to opening a terminal instead of the review diff. The #1428 faces already render this gate (yellow +verifiedglyph +Verifylabel), so today the key looks gate-blocked but the press opens a terminal — a face/behaviour contradiction, the same class codex caught during #1428.Fixes #1431
Root Cause
phaseArtifactVerb(apps/streamdeck/src/actions.ts) mapped thespec-approval,plan-approval,dev-approval, andprgates but notverify-approval— which the VS Code sidebar's gate vocabulary already knows (gateIconFormaps it to theverifiedcodicon). The Stream Deck resolver never caught up, so the gate returnedundefinedand both callers that key off it (the Builder Action Automatic press and the phase-aware dial mode) took the fallback path.Fix
verify-approvalto the gate branch, returningview-diff(same asdev-approval/pr— the human is reviewing finished work). The Automatic press then resolvesview-diff→open-diff-firstviaBuilderAction.resolveVerb(Stream Deck SD+: Automatic diff press should open the builder's first file diff (dial-ready), not the aggregate #1414), which is correct and intended.dev-approval/prgate cases inactions.test.ts.face.tsdoc-comment clause that noted the resolver did not handle this gate yet (BUGFIX Stream Deck: phaseArtifactVerb doesn't map the verify-approval gate (Automatic press falls back to terminal) #1431) — this change closes that gap.Second behavioural effect: review dials
reviewMode()derives from the same resolver (verb === 'view-diff'→'diff'), so this change also flips averify-approval-blocked builder's review dials from'none'(dead) to'diff'(navigating the diff). This is correct and desirable — symmetric withdev-approval/pr; the dials should work while a human reviews finished work. Pinned with an addedreviewModeassertion.Test Plan
phaseArtifactVerb(verify-approval)→view-diffandreviewMode(verify-approval)→diff(both fail without the fix:phaseArtifactVerbreturnsundefined,reviewModereturnsnone)