You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit c3ff7f9
Browse filesBrowse the repository at this point in the historyBrowse files
feat(buzz): preserve bot identities when adding named accounts (#132226)
* feat(buzz): preserve root identity across named account setup
Keep named credentials, rooms, lifecycle, and setup writes account-owned; preserve static root-layout policy through Doctor without importing disabled plugin runtimes. Fixes#130062.
Co-authored-by: yu-xin-c <[email protected]>
* fix(buzz): resolve setup credentials without disabling accounts
Preserve authored secret references and reject unavailable credentials without saving account changes. Require an authorized room selection to finish setup.
Co-authored-by: yu-xin-c <[email protected]>
* fix(channels): distinguish preserved roots from empty promotion
Keep ordinary env-only account promotion seeding accounts.default while an
explicit preserve-root owner keeps its root intact, including empty roots.
Use one canonical promotion result and remove the unused keys-only wrapper.
Co-authored-by: yu-xin-c <[email protected]>
* fix(outbound): resolve local account defaults before formatting
Carry one locally resolved account through prefixing, target resolution and
delivery. Preserve explicit, host and binding precedence, and keep omitted
account input absent when delegating to a remote Gateway.
Co-authored-by: yu-xin-c <[email protected]>
* fix(buzz): report the selected account's missing room path
Use the canonical account configuration path in startup recovery guidance.
Cover missing, empty and disabled room lists for implicit root, named and
explicit-default identities before opening a relay or recovery store.
Co-authored-by: yu-xin-c <[email protected]>
* fix(buzz): settle account work before scoped reloads
Keep sibling identities connected during named-account edits. Fence profile
publication after cancellation and join pending profile work after relay close
so replacement account lifetimes cannot overlap stale profile effects.
Co-authored-by: yu-xin-c <[email protected]>
* fix(gateway): reconcile channel lifetimes after secret resolution
Route no-op secret publication through the existing reload transaction and
merge resolved channel effects with its authored restart scope. Leave cold
accounts stopped without masking lifecycle failures or undoing manual stops.
Preserve shared-auth generation ownership across provider-only changes.
Discovered while verifying Buzz multiaccount setup and isolated recovery.
Co-authored-by: yu-xin-c <[email protected]>
* fix(buzz): align setup reload policy and account guidance
Declare isolated named-account reloads on the standalone setup descriptor.
Cover both public descriptors and document nested room and auth-tag paths,
including the implicit-root-only environment fallback.
Co-authored-by: yu-xin-c <[email protected]>
---------
Co-authored-by: yu-xin-c <[email protected]>
Copy file name to clipboardExpand all lines: docs/gateway/secrets.md
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,6 +24,7 @@ Plaintext credentials remain agent-readable when they sit in files the agent can
24
24
- Secrets resolve into an in-memory runtime snapshot, eagerly during activation, not lazily on request paths.
25
25
- Cold Gateway startup isolates a retryable SecretRef failure to a known non-Gateway owner when that owner supports isolation. Mapped owner classes include model providers and skills, media/TTS/cron providers, eligible auth profiles, per-agent memory, sandbox SSH, channel accounts, and manifest-declared plugin routes. The Gateway starts, records the owner as configured-unavailable, and emits a redacted degradation warning. Gateway ingress auth, structurally invalid refs or resolved values, fail-closed owners, and refs whose runtime owner is not mapped still fail startup.
26
26
- Reload validates each mapped owner independently, then publishes one atomic snapshot. Healthy owners refresh. An eligible failed owner keeps its last-known-good value and becomes stale only when its ref identities, provider definitions, and complete non-secret owner contract are unchanged; a changed or new failed owner becomes cold. A strict failure rejects the reload and preserves the active snapshot.
27
+
- Config reload also reconciles channel connections when a secret-provider edit changes resolved credentials. Plugins that support account-scoped reload restart only the affected named accounts; shared, default, removed, or unresolved account changes use the plugin's whole-channel restart policy. Cold accounts stop, eligible stale accounts keep using their last-known-good credentials, and recovery preserves manual stops.
27
28
- Policy violations (for example an OAuth-mode auth profile combined with SecretRef input) fail activation before the runtime swap.
28
29
- Runtime requests read only the active in-memory snapshot. Model-provider SecretRef credentials pass through auth storage and stream options as process-local sentinels until egress. Outbound delivery paths (Discord reply/thread delivery, Telegram action sends) also read that snapshot and do not re-resolve refs per send.
29
30
- Read-only channel capability discovery evaluates accounts independently. A configured-but-unavailable account does not hide healthy sibling accounts' message actions, while direct sends through the unavailable account still fail closed.
Copy file name to clipboardExpand all lines: docs/plugins/sdk-setup.md
+4-1Lines changed: 4 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -437,14 +437,17 @@ When a channel upgrades from a single-account top-level config to `channels.<id>
437
437
438
438
Every channel plugin can extend or narrow that promotion through its setup adapter:
439
439
440
+
-`configPromotion: "preserve-root"`: keep all root values in place, including common name, policy, and delivery fields; the plugin owns its account layout
440
441
-`singleAccountKeysToMove`: extra top-level keys that should move into the promoted account
441
442
-`namedAccountPromotionKeys`: when named accounts already exist, only these keys move into the promoted account; shared policy/delivery keys stay at the channel root
442
443
-`resolveSingleAccountPromotionTarget(...)`: choose which existing account receives promoted values
443
444
444
-
The presence of `singleAccountKeysToMove` marks the promotion contract complete. Declare the field even when it is an empty array to opt out of legacy key promotion. Adapters that omit the field retain a reader-backed pre-declaration promotion tier for already-published plugins. The 2026-07-22 registry sweep removed 23 keys with no published dependents and retained six common keys plus the setup-only `rooms` key. Each retained key is deleted as soon as its published readers migrate to declarations; no version boundary is required.
445
+
The presence of `singleAccountKeysToMove` marks the promotion contract complete. Declare the field even when it is an empty array to opt out of legacy key promotion; an empty array does not suppress common fields. Adapters that omit the field retain a reader-backed pre-declaration promotion tier for already-published plugins. The 2026-07-22 registry sweep removed 23 keys with no published dependents and retained six common keys plus the setup-only `rooms` key. Each retained key is deleted as soon as its published readers migrate to declarations; no version boundary is required.
445
446
446
447
Declare `openclaw.setupFeatures.configPromotion: true` in the plugin package manifest when doctor must load these declarations from the lightweight bundled setup artifact. The setup-only plugin surface and the full channel plugin must expose the same declarations.
447
448
449
+
For a plugin-owned root layout, also declare `openclaw.setupFeatures.configPromotion: "preserve-root"` in `package.json`. Doctor reads this static declaration for installed and bundled plugins, including disabled plugins, without executing their runtime. Omitting the declaration or using `false` does not opt out of promotion. The runtime declaration belongs on the adapter passed to `defineChannelSetupContract`, and covers shared CLI, declarative wizard, and policy-writer promotion. It does not change helpers that explicitly migrate a base name; use a selected-account writer when the root remains an implicit identity. Buzz is an example of this layout.
450
+
448
451
When calling `moveSingleAccountChannelSectionToDefaultAccount(...)` with an already resolved plugin, pass its setup adapter as `setupSurface`. Caller-supplied setup surfaces take precedence over loaded and bundled lookup, which keeps scoped or setup-only plugins independent of global registration.
0 commit comments