-
-
Notifications
You must be signed in to change notification settings - Fork 79.2k
plugins registry --refresh (refreshReason: policy-changed) drops path/npm-origin plugins from plugins[] #89606
Copy link
Copy link
Open
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.ClawSweeper found a clear likely implementation shape for this issue.clawsweeper:queueable-fixClawSweeper marked this issue as an existing queue_fix_pr work candidate.ClawSweeper marked this issue as an existing queue_fix_pr work candidate.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:otherThis issue has meaningful maintainer-visible impact outside the owned taxonomy.This issue has meaningful maintainer-visible impact outside the owned taxonomy.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Metadata
Metadata
Assignees
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.ClawSweeper found a clear likely implementation shape for this issue.clawsweeper:queueable-fixClawSweeper marked this issue as an existing queue_fix_pr work candidate.ClawSweeper marked this issue as an existing queue_fix_pr work candidate.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:otherThis issue has meaningful maintainer-visible impact outside the owned taxonomy.This issue has meaningful maintainer-visible impact outside the owned taxonomy.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Summary
When OpenClaw's plugin registry regenerates with
refreshReason: "policy-changed"(which happens on the first sandbox run after a runtime policy mutation), the rebuild ofplugins[]excludes any plugin whoseinstallRecords[id].sourceis"path"or"npm". Only bundled extensions (origin:"bundled") survive the regen.Impact
openclaw plugins inspect <id>→Plugin not foundopenclaw config set plugins.allow ...silently strips the entry because the validator only consultsplugins[], notinstallRecordsopenclaw <plugin-id>) unreachable until someone re-runsopenclaw plugins registry --refreshmanuallyReproduced on:
Common factor: sandbox onboard with GPU enabled, which mutates policy between build and first runtime. No-GPU onboard does not trigger the regen and the bug does not manifest.
Evidence
Right after first sandbox run on fresh image:
{ "refreshReason": "policy-changed", "installRecords": { "nemoclaw": {"source": "path", "installPath": "/sandbox/.openclaw/extensions/nemoclaw"}, "openclaw-weixin": {"source": "npm", "spec": "@tencent-weixin/openclaw-weixin@2.4.3"} }, "plugins": [ /* 93 entries — all origin: "bundled" — nemoclaw + weixin missing */ ] }installRecordsis preserved (file is on disk, installer ran).plugins[]is rebuilt from bundled discovery only, so the runtime view forgets both entries.Reproducer
Workaround
openclaw plugins registry --refresh(as the sandbox user,HOME=/sandbox) restores both plugins to the runtime registry. This works as a manual recovery but should not be required after onboard. NemoClaw is shipping a temporary post-gateway-start refresh call in their sandbox entrypoint (see related issue below); intent is to remove that workaround once this issue is fixed upstream.Suggested fix
Either of these closes the issue:
plugins[]frominstallRecords ∪ bundled discovery— not bundled only. Path/npm-origin plugins survivepolicy-changedregen.plugins.allowvalidator consultsinstallRecordsas a fallback when an id isn't inplugins[]— so users can pinplugins.alloweven if the regen view is stale.Option (1) is the cleaner fix because it removes the source-of-truth split between
installRecordsandplugins[].Related