Repository navigation
fix: installing an official plugin on a beta gateway lands the stable release - #127791
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 27, 2026, 12:51 AM ET / 04:51 UTC. ClawSweeper reviewWhat this changesRoutes fresh managed installs of official plugins on beta gateways to the beta release stream and prevents an unavailable beta artifact from silently installing stable latest. Regression provenancePossible regression — probable (reproduction; reviewed change). No predecessor PR is attributed. Merge readinessThe PR addresses a real current-main gap and has strong exact-head install evidence, but its deliberate change from a stable fallback to a terminal beta-cohort failure needs maintainer product acceptance before merge. Priority: P1 Review scores
Verification
Live VerificationCommand: Result: PASS (completed) Assertions:
How this fits togetherOfficial-plugin installation is shared by the CLI, chat commands, and Gateway management. It resolves an official source, installs it, records the operator-facing selector, and feeds plugin loading and later recovery flows. flowchart LR
A[Plugin install request] --> B[Managed install boundary]
B --> C[Release-channel selection]
C --> D[Registry or ClawHub artifact]
D --> E[Install record]
E --> F[Gateway plugin loading]
C --> G[Visible recovery or terminal result]
Decision needed
Why: The patch intentionally changes an established fallback on a compatibility-sensitive installation path; source and proof establish the mechanics, but maintainers must choose the operator policy. Before merge
Agent review detailsSecurityNone. PR surfaceSource +219, Tests +359, Docs +2. Total +580 across 15 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Adopt one explicit release-cohort policy: fresh official beta installs fail visibly when no matching artifact exists, while recovery paths retain their documented, visible fallback behavior. Do we have a high-confidence way to reproduce the issue? Yes, source makes the current-main path reproducible: managed installs pass a bare official selector, and the PR body records a live exact-head A/B npm install showing stable versus beta resolution. Is this the best way to solve the issue? Yes for the technical repair: resolving at the shared managed-install owner prevents CLI, chat, and Gateway drift while the recovery callers retain visible fallbacks; the remaining question is the intended fresh-install policy. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 4bc659744181. LabelsLabel 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 (10 earlier review cycles; latest 8 shown)
|
ae2f862 to
d6380d9
Compare
… release Official plugin installs resolved the registry default instead of the release stream the gateway runs, so a fresh install landed a plugin the gateway then reported as drifted, and a channel could load against a plugin-sdk surface the running host no longer exports. Resolution now happens once on the boundary every managed install path passes through, sharing the release-cohort rule with the drift report. Version-bound resolution normalizes correction releases, so a gateway packaged as 2026.7.1-2 targets the published 2026.7.1 plugin instead of an unpublished version. When the resolved release has no artifact the install widens to the operator's own selector and says so.
The channel fallback only wrapped the npm attempt, so a beta gateway whose official ClawHub release is unpublished switched install source or failed instead of retrying the operator's own selector, unlike the CLI and chat paths. Both setup paths now consume the same fallback contract, and the degrade stays visible on their success paths. Also folds duplicate module imports and moves the chat release-stream test into its own file so the host suite stays under the line budget.
…ll suite Adding a test file shifts the oxlint shard partition and the node test plan counts, which surfaced as unrelated lint and plan failures. Fold the case into the sibling suite instead so the file inventory stays unchanged.
The managed install boundary resolved the gateway's release stream but still carried the resolver's fallback selector, so an unpublished beta artifact retried the bare npm/ClawHub spec and landed the stable `latest` build — the exact cross-release install the boundary exists to prevent. A managed install has no operator-chosen selector to honour, so it now reports the unpublished cohort instead of widening. Restrict the boundary to the beta stream as well. The version-bound stable tracks key off a per-plugin `versionBoundToOpenClaw` descriptor that a managed install request does not carry, and answering for them here would pin plugins the policy never opted in.
d6380d9 to
d5763b1
Compare
Carry hosted official provenance into beta release selection and make a missing cohort terminal before hook fallback. Align the plugin docs with the fresh-install and recovery policies.
|
Thanks @edenfunf! |
|
Maintainer decision: accept the release-cohort policy. Fresh official beta installs must stop with explicit-version guidance when the matching beta artifact is absent; they must not silently install stable latest. The required exact current-main versus exact-head A/B and exact-head CI are complete in the PR body. |
Keep official plugins on the gateway release stream so beta gateways do not silently install stable artifacts. Resolve hosted catalog entries at the shared boundary, stop missing cohorts before hook fallback, and keep recovery notices visible. Co-authored-by: 許元豪 <[email protected]> Co-authored-by: Ayaan Zaidi <[email protected]>
Related #97680
Related #122655
What Problem This Solves
An official plugin installed on a beta gateway used the registry default selector.
That selector can resolve the stable plugin while the gateway runs a beta release.
The gateway then reports version drift, and an incompatible plugin can fail before it handles messages.
Root Cause
The CLI, chat command, and Gateway install paths share
installManagedPluginSource.That owner passed bare official npm and ClawHub selectors to the installer without applying the gateway release channel.
The update and repair flows already used the shared release-channel resolver.
Fix
@betafor a beta gateway.Evidence
Exact Current-Main Versus Exact-Head A/B
Both legs used the source CLI from the named commit, exact revision dependencies, live npm, and separate disposable state directories.
The config set
update.channeltobeta.origin/main@71d4a8c3e305c623aa3ffe92696eec18f116cfc6@openclaw/line2026.7.1@openclaw/line94ba9f9fd0b1d51365b425ac9ee83214865f8c06@openclaw/line@beta2026.8.1-beta.3@openclaw/lineLive registry state during the run:
This proves the current-main failure and the exact-head repair through the real install path.
It does not depend on Crabbox or a package-build approval.
Regression Proof
The hosted-only and hook-fallback assertions failed on the pre-repair code:
They pass after the repair.
Focused suites:
Additional checks:
Telegram Changed-Command Proof
The dedicated QA user sent this command to an isolated exact-head Gateway:
The Gateway log recorded
Installing @openclaw/line@beta, thenInstalled plugin: line.Telegram recorded the bot reply
Installed plugin "line". Gateway restart will load the new plugin source.after 6.0 seconds.The mock provider received zero requests because the command completed before model execution.
Scope
+217net lines.+360net lines.+2net lines.The production growth adds one shared install policy, visible recovery behavior, and explicit terminal handling across npm and ClawHub paths.
User Impact
Fresh official plugin installs on beta gateways now use the beta release stream.
If that release is absent, OpenClaw names the missing target and asks for an explicit version instead of silently installing stable latest.