Repository navigation
fix(gateway): align history test fixture with projection state - #139794
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. Reviewed September 6, 2026, 1:40 AM ET / 05:40 UTC. ClawSweeper reviewWhat this changesUpdates two Gateway history test fixture fields to match the current projection result type while preserving pagination assertions. Merge readiness✅ Ready for maintainer review The repair remains necessary on fetched main and correctly restores the fixture’s type contract without weakening pagination coverage. No actionable findings; maintainer-owned work stays open. Priority: P3 Review scores
Verification
How this fits togetherGateway history projection turns stored conversation messages into displayable pages and streaming updates. This fixture tests that interleaved message groups remain together when history is paginated. flowchart LR
A[Stored conversation messages] --> B[Display projection]
B --> C[Messages and projection state]
F[Regression fixture] --> C
C --> D[History pagination]
D --> E[History pages and streaming updates]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceTests 0. Total 0 across 1 file. View PR surface stats
Review metricsNone. Technical reviewBest possible solution: Keep the existing pagination regression intact and align its fixture with the canonical projection result type. Do we have a high-confidence way to reproduce the issue? Yes, source inspection establishes the fixture’s incompatible property names against the declared return type. The PR reports a failing-before/passing-after Gateway test typecheck; this review did not execute it. Is this the best way to solve the issue? Yes. Replacing the obsolete fields directly preserves the meaningful pagination regression without adding aliases, casts, or weaker assertions. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against cbd94188df13. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
Bring in the canonical Gateway test-fixture repair from openclaw#139794 so fresh CI can validate the filename change. Preserve the contributor history and verified file-fetch source and test bytes.
Import the canonical Gateway projection-fixture repair from openclaw#139794 after the previous CI merge used its retired fields. Preserve the Devices repair and contributor ancestry; the UI delta remains five files with net-negative production lines.
What Problem This Solves
Gateway history test-type validation fails after the assistant error projection state was renamed in #139753. The interleaved pagination regression fixture added in #139715 still uses the previous result fields.
Why This Change Was Made
Update the existing fixture to the current projection result contract:
assistantErrorPendingandassistantErrorRecoveryObserved, bothfalse. Keep its messages, pagination options, and assertions unchanged.User Impact
No runtime behavior changes. Maintainers can validate the Gateway history tests against the current projection contract while retaining the pagination regression coverage.
Evidence
The canonical changed-paths typecheck selected
gateway-rootand reproduced TS2353 on the original fixture; the same command passes with this repair. All 30 existing session-history state tests pass. Targeted formatting, lint, andgit diff --checkpass.Commands:
node scripts/run-tsgo-core-test-shards.mjs --changed-paths-json '["src/gateway/session-history-state.test.ts"]';node scripts/run-vitest.mjs src/gateway/session-history-state.test.ts.Independent source review and isolated Codex autoreview found no actionable issue. No production code or pagination assertions change.