Conversation
Stop accumulating overlapping assistant request totals for the chat context footer. Let authoritative session usage reconcile lower totals and clear stale percentages while cached final-message fallbacks preserve newer per-message usage until the session snapshot arrives. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
|
Codex review: blocked before merge. Reviewed September 25, 2026, 7:41 PM ET / 23:41 UTC (Revision 2). ClawSweeper reviewWhat this changesThe branch changes the Windows chat footer to use the latest assistant request total and accept session-list usage corrections, with a separate event for fresh list responses and focused regression tests. Merge readiness⛔ Blocked before merge - 4 items remain Keep open. Current main and the latest release retain the reported footer defect. The follow-up addresses the two earlier review findings, but the branch still has a source-proven ordering gap and incomplete required validation. Priority: P2 Review scores
Verification
How this fits togetherThe Gateway supplies assistant usage frames, session-list responses, and activity updates to the Windows chat provider. The provider reconciles those values into conversation snapshots that the WinUI chat footer formats as context usage. flowchart LR
A[Assistant usage frames] --> D[Usage reconciliation]
B[Session list responses] --> D
C[Cached activity updates] --> E[Conversation snapshot]
D --> E
E --> F[WinUI context footer]
Before merge
Findings
Agent review detailsSecurityNone. Review metrics
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Order session-list snapshots against live assistant usage, retain legitimate lower corrections such as compaction, and verify the corrected footer in an isolated WinUI run when the scheduled pool is available. Do we have a high-confidence way to reproduce the issue? Yes. Source supports a deterministic bridge sequence: emit a newer assistant final, then deliver an older delayed session-list response; this read-only review did not run it. Is this the best way to solve the issue? No. Separating cached activity from list responses addresses the earlier findings, but list provenance alone cannot establish that a response is newer than an assistant frame. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 5a59535216ee. LabelsLabel changes: No label changes. Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
|
Maintainer follow-up on this draft at |
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
|
@shanselman Addressed the unresolved feedback in additive commit cceafd9. Fresh sessions.list usage now travels through a separate SessionUsageSnapshotUpdated event, while activity-only cached republishes remain presentation-only and cannot reconcile footer usage. The contribution marker is retained across authoritative reconciliation so a replayed terminal frame cannot lower the corrected total. Added focused regressions for activity-only updates before and after authoritative correction, duplicate finals after an intervening correction, and fresh-event provenance. Build, 3068 Tray tests, and 441 focused chat/context tests pass. The full Shared suite still exposes an unrelated order/load-dependent McpHttpServerTests.Dispose_DuringInFlightHandler_DoesNotSurfaceObjectDisposedException failure, while that test passes alone; exact-head CI is running. There are no inline review threads on this PR to resolve. |
Summary
sessions.listusage snapshots from activity-only cached session republishesFixes #1433
Required proof pools
windows-winui-interactive: chat footer context usage display changed; maintainer-scheduled visual proof can verify the rendered footer in the isolated WinUI app.Validation
Current head:
cceafd9ae7269dde4b600f9f1a2a140fabfbe672$env:OPENCLAW_REPO_ROOT=(Get-Location).Path; .\build.ps1- passed. All builds succeeded and documentation validation checked 50 Markdown files.dotnet test .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj --no-restore- passed. Failed: 0, Passed: 3068, Skipped: 0, Total: 3068.McpHttpServerTests.Dispose_DuringInFlightHandler_DoesNotSurfaceObjectDisposedExceptionrace failed under full-suite load. The same test passed when rerun alone. Exact-head CI remains the authoritative closeout for that order/load-dependent failure.Real behavior proof
sessions.listparsing now emitsSessionUsageSnapshotUpdated; tool/job activity continues to emit only genericSessionsUpdated, so cached activity cannot reconcile footer usage.Not verified / blocked: visual
windows-winui-interactiveproof was not run locally for this draft; automated focused tests cover the footer accounting state that drives the UI text.