Repository navigation
chore(gateway): cover accepted replies with lost QA acknowledgements - #176000
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review in progressClawSweeper is reviewing this revision. This supersedes any previous blocked status. |
|
@clawsweeper re-review Please review the current head |
|
🦞👀 Re-review progress:
|
|
Codex review: needs maintainer review before merge. What this changesAdds a Gateway integration test that prevents duplicate source replies after QA accepts a message but loses its HTTP acknowledgement. Example: QA accepts “One accepted source reply” for qa-source-turn, then the proxy drops its response.
Review scores
ProductKind: Test only · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this maintainer-authored PR adds useful, distinct transport-and-receipt coverage; the pinned diff has no actionable findings and its exact-head CI gates passed. Priority: P3 Before mergeNone. FindingsNone. Tests
Agent review detailsHow this fits togetherThe Gateway message.action handler validates an admitted agent request, records its source-reply intent through the session actor, and dispatches through the QA plugin’s native HTTP client; uncertain delivery leaves the receipt pending and suppresses another same-source send. flowchart TD
A[Admitted agent request] --> B[Gateway message action]
B --> C[SQLite source reply receipt]
B --> D[QA channel HTTP client]
D --> E[Test response proxy]
E --> F[QA bus business message]
E --> G[Lost acknowledgement]
C --> H[Distinct retry suppressed]
Technical reviewBest possible solution: Retain this focused composition in the existing Gateway database-worker test lane. Do we have a high-confidence way to reproduce the issue? This is coverage for an existing contract, rather than a reported current production failure; inspection confirms the intended fault and assertions, and GitHub confirms the linked shard succeeded. Is this the best way to solve the issue? The smallest complete change is one integration case plus existing worker-lane registration: preserve ambiguity after accepted delivery and reject a distinct same-source send through the owners already present. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 51cf7e45b2bc. TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
PR surfaceTests +327. Total +327 across 2 files. Added test files: 1. View PR surface stats
Review metrics
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 17, 2026, 10:40 PM ET / October 18, 2026, 02:40 UTC. |
|
Merged via squash.
|
…penclaw#176000) * chore(gateway): cover accepted replies with lost QA acknowledgements * test(gateway): respect QA facade and fixture static contracts
What Problem This Solves
The existing tests do not compose a real QA message commit and lost HTTP acknowledgement with the Gateway's authoritative pending source-reply receipt.
User Impact
No production behavior changes. This regression test checks that an uncertain acknowledgement does not permit a duplicate reply for the same admitted source.
Why This Change Was Made
The test uses the real Gateway handler, capability and approval validation, ordinary SQLite source admission, and QA bus. A test-local proxy fully consumes the upstream response and verifies the committed business message before dropping the downstream acknowledgement. A distinct second call and idempotency key must preserve the original pending receipt and return
delivery_ambiguouswithdelivered: false, without another HTTP request or message.Related: #119057. This covers one remaining native transport composition, not the entire older PR. It complements #175535 and #175616 without replaying their separate experiments.
Evidence
cad451f3c60e78d347236496411f46ae106573d3, tested mergeafe4e0c1defab616e21c597946295af8dcc159f3, main parent5588de47ba5cbec1cbd5bd997b446b8f2b27014e.281c993f0a8a33851d7f6adce8538cc54ee4affapassed CI run 39090070936: 34 successful jobs, 28 skipped. The exact case passed 1/1 with exit 0 and generation cleanup on merge9ab64aa61afc4fdc9c3cb97da8abbcbd4ae7265a, main parent90e30d0c40d85e6c09479759d72fb4e893a8f33a. Production/test types, lint and boundary gates passed. Build was skipped, not claimed. Determining Gateway/receipt/QA owners are unchanged between the frozen source and this tested main parent.