Repository navigation
fix(beam): open uploads at canonical catalog URLs - #120927
Conversation
962d035 to
2dd8540
Compare
|
Codex review: needs maintainer review before merge. Reviewed August 9, 2026, 4:49 AM ET / 08:49 UTC. ClawSweeper reviewWhat this changesBeam upload responses switch from a legacy session-key URL to the canonical catalog route, and minimal Gateway startup avoids an unnecessary metadata refresh. Regression provenancePossible regression — probable (reproduction; reviewed change). No predecessor PR is attributed. Merge readinessNo blocking code findings. The PR remains necessary because current main still returns Beam’s obsolete session URL; the proposed shared URL owner is the appropriate fix. It needs normal maintainer review after the remaining exact-head check completes. Priority: P2 Review scores
Verification
How this fits togetherBeam accepts uploads and returns a Control UI URL; the session URL contract turns Beam’s catalog identity plus agent and base-path settings into a route the Control UI can reopen. Separately, Gateway startup attaches metadata listeners for full Gateways while minimal test Gateways refresh lazily on their first read. flowchart LR
A[Beam upload] --> B[Beam request handler]
C[Agent and Control UI settings] --> D[Canonical catalog URL builder]
B --> D
D --> E[Control UI catalog route]
E --> F[Catalog session]
G[Gateway startup] --> H[Metadata listener decision]
Before merge
Agent review detailsSecurityNone. PR surfaceSource +27, Tests +218, Docs 0, Generated 0. Total +245 across 11 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep one canonical catalog URL builder, land it after exact-head validation, and explicitly accept the documented Beam response-format transition. Do we have a high-confidence way to reproduce the issue? Yes. The PR body records an authenticated isolated-Gateway upload returning the canonical route and an HTTP 200 route fetch; current source independently shows main still returns the obsolete session-key URL. Is this the best way to solve the issue? Yes. The shared session URL contract already owns path normalization and encoding, so placing catalog URL construction there removes Beam-specific duplicated routing logic. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 29c442d48389. LabelsLabel 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)
|
|
@clawsweeper re-review The new head adds a bounded Gateway behavior repair after the prior review: minimal Gateways remain lazy and sidecar-free, while full Gateways still await listener catch-up. The PR body contains the root cause and focused exact-source/Testbox proof. |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
67aa454 to
7cf9c41
Compare
* fix(beam): emit canonical catalog URLs * fix(beam): type readonly runtime config * fix(gateway): keep minimal metadata startup lazy * chore(plugin-sdk): refresh API baseline
What Problem This Solves
Fixes an issue where users opening a Beam upload from the returned Control UI URL would receive the stale
?session=route. That route no longer preserved the Beam catalog identity, so the UI could not reliably reopen the uploaded session, especially when the operator configured a non-main default agent or a nested Control UI base path.Why This Change Was Made
Beam now emits the canonical catalog route,
/chat/<agent>?catalog=beam&host=gateway&thread=<beamId>, using the configured default agent and Control UI base path. URL construction lives in the shared session URL contract and is exposed to Beam through the private/local session-catalog runtime facade, keeping catalog routing policy with the existing session URL owner without adding public Plugin SDK surface.The old Beam-only session-key encoder and base-path normalizer are removed. This intentionally limits the change to canonical catalog URL emission; it does not add compatibility aliases or broaden session URL normalization elsewhere.
User Impact
Beam upload responses now link directly to the uploaded catalog session. The link works with the default
mainagent, a configured default agent, and nested Control UI base paths.Release-note context: Beam upload links now open the correct catalog-backed Control UI session instead of returning the obsolete
?session=URL.Evidence
packages/session-url-contract/src/index.test.ts(7),extensions/beam/src/beam.test.ts(8), andui/src/lib/sessions/route-navigation.test.ts(7)./admin/openclaw/chat/research?catalog=beam&host=gateway&thread=<id>; requesting that route returned HTTP 200.pnpm plugin-sdk:surface:checkpassed with public SDK counts unchanged: 151 entrypoints, 4,844 exports, and 0 package-exported forbidden subpaths.pnpm plugin-sdk:api:genrefreshed the generated API baseline against the rebased Plugin SDK generator: all 151 modules were retained, with 48 hash rotations and no module additions/removals or budget changes.pnpm plugin-sdk:api:checkandpnpm plugin-sdk:surface:checkboth passed on that generated output.git diff --check origin/main...HEADpassed.Exact-head CI blocker repaired
This PR also repairs a current-
mainminimal Gateway startup regression that repeatedly blocked its exact-head CI. Commit3bfe82180e1dmade the chat metadata catch-up refresh unconditional: minimal Gateways intentionally register no listener sidecar and already refresh lazily throughbeforeRefreshplusrefreshOnRead, but startup nevertheless awaited prepared-model publication for up to 120 seconds. The catch-up now remains awaited only when listener registration actually returns a sidecar, preserving full Gateway reconciliation while keeping minimal startup lazy.tbx_01kzjr6epgrgxwax8jk78e7kpj: build passed in 5m3.95s; the full two-filecheck-changedplan passed in 5m45.29s.