Repository navigation
fix: avoid session-list rebuilds when authentication availability changes - #151920
Conversation
Keep authentication availability publications for metadata consumers while telling the session projection when model facts are unchanged. Incomplete catalogs and real owner or model changes retain their invalidation paths.
|
🦞👀 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 18, 2026, 1:25 PM ET / 17:25 UTC (Revision 3). ClawSweeper reviewWhat this changesThe PR preserves cached session-list rows when authentication availability changes, adds binding and revocation regression coverage, and strengthens a Codex process-poll output assertion. Merge readiness✅ Ready for maintainer review The PR remains useful: current main still rebuilds session rows for authentication-only publications. No actionable correctness or security findings remain, and the protected maintainer submission should stay open for normal landing. Priority: P2 Review scores
Verification
How this fits togetherThe Gateway builds session-list rows using published model metadata. Authentication availability also feeds model-picker metadata, but does not change the model facts used to build those rows. flowchart TD
A[Authentication bound or revoked] --> B[Prepared runtime publisher]
B --> C[Model-picker metadata refresh]
B --> D{Complete cached catalog and unchanged model facts?}
D -->|Yes| E[Reuse session rows]
D -->|No| F[Refresh catalog and session rows]
E --> G[Session-list response]
F --> G
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource 0, Tests +47. Total +47 across 5 files. View PR surface stats
Review metrics
Technical reviewBest possible solution: Keep authentication availability publications intact while rebuilding session rows only when their model facts change or their catalog needs recovery. Do we have a high-confidence way to reproduce the issue? Yes, from source: binding or revoking runtime authentication on current main emits two publications that invalidate resident session rows despite unchanged catalog facts. The supplied regression exercises that path; this read-only review did not execute it. Is this the best way to solve the issue? Yes. The existing publisher supplies the unchanged-facts signal, and the existing projection consumes it conservatively without adding another cache, changing authentication decisions, or suppressing incomplete-catalog recovery. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against d8b6873518d2. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
History |
|
Merged via squash.
|
* origin/main: test(gateway): isolate session resolution channel fixtures (#151945) fix(clickclack): drain discussion opens before shutdown (#151978) fix(test): restore trusted packaging harness startup (#151967) improve(codex): batch session adoption binding reads (#151979) improve(cron): reduce allocations for busy stream sources (#151956) fix(file-transfer): avoid repeated directory record encoding (#151987) fix: avoid session-list rebuilds when authentication availability changes (#151920) fix(updates): explain externally managed update refusals (#151942) improve(heartbeat): avoid unused config work in membership checks (#151867) fix(android): keep status text readable and label accessibility actions (#151342) improve(ui): show OS and size in the environment selector (#151947) fix(android): keep tool errors visible in collapsed chat activity (#151332)
…nges (openclaw#151920) * perf: preserve session rows across auth availability changes Keep authentication availability publications for metadata consumers while telling the session projection when model facts are unchanged. Incomplete catalogs and real owner or model changes retain their invalidation paths. * test(codex): check output in process poll delivery proof
What Problem This Solves
Session lists can rebuild every cached row when a model authentication route is recorded or revoked, even though the model catalog is unchanged.
User Impact
Session lists reuse their existing rows across authentication availability changes. Model-picker availability and revocation still refresh; real model, configuration, and owner changes still invalidate session rows. No configuration or database migration is required.
Why This Change Was Made
The existing authentication-materialization publisher now identifies publications that leave model facts unchanged. The session catalog projection consumes that fact only after it has a complete catalog. Existing publication phases and stale-owner guards remain intact.
Evidence
sessions.listoutput; the published authentication facts still change.success: false; the failure output omitted its response text. The exact 11-file group passes 129/129 tests on both baseline and candidate under Node 24.20.0 with three workers. The test now also checks its synthetic completed output, exposing response content on failure while preserving all acknowledgement assertions and timeouts. The hosted failure cause remains unverified.CI also reported a Vitest fork shutdown error after all 434 tests in the affected shard passed. The named transcript test and its cleanup owners came unchanged from the exact main parent; inspection found no causal connection to this diff. The missing worker shutdown response remains unexplained, and its retained log is part of the investigation evidence.
Exact-head CI run 35368653213 passed on
10ee5df0aae3e704c1e69be7dcbe900b2aa2cd58after one bounded retry of that failed shard. The previously failing process-poll shard passed on this head. Neither earlier failure cause is claimed fixed by the retry.