Repository navigation
refactor(channels): unify bundled setup ownership and remove duplicate paths - #117188
Conversation
|
Codex review: needs maintainer review before merge. Reviewed July 31, 2026, 11:24 PM ET / August 1, 2026, 03:24 UTC. ClawSweeper reviewWhat this changesThis PR consolidates setup metadata, account-promotion behavior, and status ownership for bundled Slack, Matrix, and Nostr channel plugins while keeping their heavier runtime code lazy and plugin-owned. Merge readinessKeep this PR open for normal maintainer merge review. The inspected refactor preserves the existing setup-contract precedence and lazy plugin-runtime boundary, with no discrete patch regression found; the Priority: P2 Review scores
Verification
How this fits togetherOpenClaw’s channel setup path turns guided or CLI setup input into canonical channel configuration, then loads the channel plugin runtime and Doctor diagnostics as needed. This change moves duplicated setup definitions to lightweight plugin-owned surfaces while shared helpers retain account-name and legacy single-account promotion behavior. flowchart LR
Input[Guided or CLI channel setup] --> Contract[Channel setup contract]
Contract --> Config[Canonical channel configuration]
Config --> Promotion[Account promotion and naming]
Config --> Plugin[Lightweight plugin setup metadata]
Plugin --> Runtime[Lazy channel runtime]
Runtime --> Doctor[Status and Doctor diagnostics]
Decision needed
Why: The patch is a broad ownership refactor across shared setup logic and three bundled channel plugins; automated review found no concrete defect, but the protected maintainer workflow requires a human merge decision. Before merge
Agent review detailsSecurityNone. PR surfaceSource -228. Total -228 across 8 files. View PR surface stats
Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Land one canonical lightweight setup surface per bundled channel while retaining the released setup SDK compatibility boundary and the existing account-promotion semantics for upgraded configurations. Do we have a high-confidence way to reproduce the issue? Not applicable: this PR is a behavior-preserving ownership refactor rather than a report of a failing user path. The relevant evidence is setup-contract and account-promotion coverage plus the supplied packaged operator proof. Is this the best way to solve the issue? Yes. Keeping lightweight setup metadata in plugin-owned setup surfaces while retaining the shared canonical mutation helpers is the narrower maintainable design and preserves the existing lazy-runtime boundary. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 865a7286c8a5. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
|
ClawSweeper status: review started. I am starting a fresh review of this pull request: refactor(channels): unify bundled setup ownership and remove duplicate paths This is item 3/3 in the current shard. Shard 8/46. This placeholder means the worker is alive and reading the current context. I will edit this same comment with the actual review when the claws are done clicking. Crustacean status: shell secured, claws on keyboard, evidence pebbles being sorted. |
* origin/main: fix(onboard): stop a full reset from resetting the default workspace when the config is unreadable (openclaw#114110) refactor(i18n): remove unused Apple contradiction report (openclaw#117182) fix(google): stop scraping Gemini CLI OAuth credentials (openclaw#117167) perf: count large histories before Gateway prewarm (openclaw#117118) fix(signal): restore provider-safe original attachment filenames (openclaw#115107) refactor(channels): unify setup ownership across bundled channels (openclaw#117188) fix: allow gateway service commands for named profiles (openclaw#116314) fix(plugins): invalidate bundled artifact locations after metadata refresh (openclaw#117041) fix(ollama): honor model requests and pull completion contracts (openclaw#117171) fix(agents): prevent fallback after stale lifecycle abort (openclaw#117168) fix(telegram): confirm polling before long poll (openclaw#116970) fix(tlon): wire autoDiscoverChannels through the settings-store round-trip (openclaw#114949) fix(gateway): yield before post-ready background work (openclaw#117083) test(google): cover live transcript overflow fix(google): bound live transcript accumulation
* commit '441d6ab254df14fb6939a8a261f474904ff9c500': (388 commits) fix(qqbot): ignore blank app id fallbacks (openclaw#109460) fix(feishu): consume implicit reply targets across media delivery (openclaw#117196) fix(exec): preserve approved command output when sessions resume (openclaw#117177) fix(qa): use public subagent fanout evidence (openclaw#116832) fix(googlechat): cancel unread auth response bodies before release (openclaw#115873) fix(queue): prevent cron saturation from starving hook dispatch (openclaw#116666) fix(gateway): sessions.steer retry no longer interrupts an active run when replaying a cached idempotency key (openclaw#116969) fix(irc): config validation rejects documented channels.irc.configWrites key (openclaw#112392) fix(mistral): keep terminal error branch lint-clean fix(onboard): stop a full reset from resetting the default workspace when the config is unreadable (openclaw#114110) refactor(i18n): remove unused Apple contradiction report (openclaw#117182) fix(google): stop scraping Gemini CLI OAuth credentials (openclaw#117167) perf: count large histories before Gateway prewarm (openclaw#117118) fix(signal): restore provider-safe original attachment filenames (openclaw#115107) refactor(channels): unify setup ownership across bundled channels (openclaw#117188) fix: allow gateway service commands for named profiles (openclaw#116314) fix(plugins): invalidate bundled artifact locations after metadata refresh (openclaw#117041) fix(ollama): honor model requests and pull completion contracts (openclaw#117171) fix(agents): prevent fallback after stale lifecycle abort (openclaw#117168) fix(telegram): confirm polling before long poll (openclaw#116970) ...
* origin/main: fix(onboard): stop a full reset from resetting the default workspace when the config is unreadable (openclaw#114110) refactor(i18n): remove unused Apple contradiction report (openclaw#117182) fix(google): stop scraping Gemini CLI OAuth credentials (openclaw#117167) perf: count large histories before Gateway prewarm (openclaw#117118) fix(signal): restore provider-safe original attachment filenames (openclaw#115107) refactor(channels): unify setup ownership across bundled channels (openclaw#117188) fix: allow gateway service commands for named profiles (openclaw#116314) fix(plugins): invalidate bundled artifact locations after metadata refresh (openclaw#117041) fix(ollama): honor model requests and pull completion contracts (openclaw#117171) fix(agents): prevent fallback after stale lifecycle abort (openclaw#117168) fix(telegram): confirm polling before long poll (openclaw#116970) fix(tlon): wire autoDiscoverChannels through the settings-store round-trip (openclaw#114949) fix(gateway): yield before post-ready background work (openclaw#117083) test(google): cover live transcript overflow fix(google): bound live transcript accumulation
* commit 'ae4e662145b6aa162777cdb1c011b3f04ddd230d': (388 commits) fix(qqbot): ignore blank app id fallbacks (openclaw#109460) fix(feishu): consume implicit reply targets across media delivery (openclaw#117196) fix(exec): preserve approved command output when sessions resume (openclaw#117177) fix(qa): use public subagent fanout evidence (openclaw#116832) fix(googlechat): cancel unread auth response bodies before release (openclaw#115873) fix(queue): prevent cron saturation from starving hook dispatch (openclaw#116666) fix(gateway): sessions.steer retry no longer interrupts an active run when replaying a cached idempotency key (openclaw#116969) fix(irc): config validation rejects documented channels.irc.configWrites key (openclaw#112392) fix(mistral): keep terminal error branch lint-clean fix(onboard): stop a full reset from resetting the default workspace when the config is unreadable (openclaw#114110) refactor(i18n): remove unused Apple contradiction report (openclaw#117182) fix(google): stop scraping Gemini CLI OAuth credentials (openclaw#117167) perf: count large histories before Gateway prewarm (openclaw#117118) fix(signal): restore provider-safe original attachment filenames (openclaw#115107) refactor(channels): unify setup ownership across bundled channels (openclaw#117188) fix: allow gateway service commands for named profiles (openclaw#116314) fix(plugins): invalidate bundled artifact locations after metadata refresh (openclaw#117041) fix(ollama): honor model requests and pull completion contracts (openclaw#117171) fix(agents): prevent fallback after stale lifecycle abort (openclaw#117168) fix(telegram): confirm polling before long poll (openclaw#116970) ...
What Problem This Solves
Bundled Slack, Matrix, and Nostr channels duplicated setup metadata, account-state handling, status resolvers, and runtime plugin definitions. Core setup account mutation likewise repeated root/named-account writes and promotion paths, increasing drift risk during onboarding and upgrades.
Why This Change Was Made
Make lightweight setup definitions authoritative for shared channel metadata while keeping heavy runtime functionality lazy and plugin-owned. Reuse canonical account-section reads/writes, one promotion path, typed Nostr setup input, and a shared Nostr status owner. Preserve every shipped external Plugin SDK setup export, released legacy setup/setupWizard adapters, setupContract precedence, CLI flags, account-key spelling, disabled-account semantics, Matrix capability differences, and Slack runtime security/doctor behavior.
Production LOC: 173 added / 401 removed = 228 fewer lines; zero test deletions and zero public SDK surface changes.
User Impact
No intended user-visible behavior change. Operators retain existing guided and non-interactive setup, named/default accounts, pairing/allowlist policies, plugin compatibility, and all Slack, Matrix, and Nostr capabilities.
Evidence
pnpm check:changedpassed: public Plugin SDK API baseline, plugin-boundary guard, dead-export scans, core/core-test/plugin/plugin-test type checks, changed lint, formatting, dependency/security/database guards, and zero runtime import cycles.pnpm buildpassed, including all 148 public Plugin SDK subpaths and bundled-plugin/runtime startup imports.channels addconfigured Nostr, Slack, and Matrix;channels list --jsonreturned all three installed/configured default accounts;doctor --non-interactivecompleted and preserved security, pairing, and allowlist diagnostics.gpt-5.6-sol/high, clean; confidence 0.99.v2026.6.33,v2026.7.2-beta.5, anddocs/plugins/sdk-setup.md/docs/plugins/sdk-migration.md.