Skip to content

fix(plugin): registry loading for configure onboard#17229

Closed
soimy wants to merge 2 commits intoopenclaw:mainfrom
soimy:fix/plugin-registry-loading-for-configure-onboard
Closed

fix(plugin): registry loading for configure onboard#17229
soimy wants to merge 2 commits intoopenclaw:mainfrom
soimy:fix/plugin-registry-loading-for-configure-onboard

Conversation

@soimy
Copy link

@soimy soimy commented Feb 15, 2026

Problem

External channel plugins (like DingTalk) were not appearing in interactive menus for openclaw configure --section channels and openclaw onboard, even though the plugins were properly loaded and configured.

Root Cause

The PLUGIN_REQUIRED_COMMANDS whitelist in src/cli/program/preaction.ts only included 'message', 'channels', and 'directory'. This controlled which commands triggered ensurePluginRegistryLoaded() in the preAction hook.

Without plugin registry initialization, channel selection menus fell back to core-only channels, excluding external plugins from being visible to users during interactive configuration.

Solution

Add 'configure' and 'onboard' to PLUGIN_REQUIRED_COMMANDS to ensure the plugin registry is loaded before these commands display their interactive menus.

Changes

  • Modified PLUGIN_REQUIRED_COMMANDS in src/cli/program/preaction.ts to include 'configure' and 'onboard' commands
  • File: src/cli/program/preaction.ts
  • Change: Expanded from 3 to 5 commands in the whitelist

Impact

External channel plugins are now discoverable in interactive menus:

  • openclaw configure --section channels now shows linked plugins in channel selection
  • openclaw onboard now shows linked plugins during onboarding flow
  • DingTalk channel (and other external plugins) now appear in channel status lists

No performance impact:

  • These commands already load configuration, so plugin loading adds no new overhead
  • Lazy-loading pattern still preserved for other commands

Backward compatible:

  • Existing commands (channels, message, directory) continue to work unchanged
  • Core channels remain visible in all contexts

Verification

Tested with DingTalk plugin (linked locally via openclaw plugins install -l .):

$ openclaw channels status
Checking channel status…
- Telegram default: enabled, configured, running
- DingTalk default: enabled, configured, stopped  ✅ Now visible!

$ openclaw configure --section channels
# Channel status section shows both Telegram and DingTalk ✅

Related Patterns

This follows the existing pattern used in:

  • channels command: loads plugins to display channel status
  • message command: loads plugins for message routing
  • directory command: loads plugins for provider discovery

The same plugin discovery mechanism is now available to configure and onboard for interactive user flows.

Greptile Summary

Adds configure and onboard to PLUGIN_REQUIRED_COMMANDS whitelist in src/cli/program/preaction.ts:23-29, ensuring external channel plugins (like DingTalk) appear in interactive menus.

Key changes:

  • Expanded PLUGIN_REQUIRED_COMMANDS Set from 3 to 5 entries by adding 'configure' and 'onboard'
  • Both commands call listChannelPlugins() in their wizards (src/commands/configure.channels.ts:18 and src/commands/onboard-channels.ts:116), which requires the plugin registry to be loaded
  • Follows existing pattern used by channels, message, and directory commands

Impact:

  • External channel plugins now visible in openclaw configure --section channels and openclaw onboard interactive flows
  • No performance impact (commands already load config, plugin loading is lazy-initialized)
  • Backward compatible with existing workflows

Confidence Score: 5/5

  • This PR is safe to merge with no risk
  • Simple, well-scoped fix that adds two strings to a Set constant. The change is well-tested in production (verified with DingTalk plugin), follows existing patterns, has zero risk of regression, and solves a real bug where external plugins were missing from interactive menus
  • No files require special attention

Last reviewed commit: feb4e41

(3/5) Reply to the agent's comments like "Can you suggest a fix for this @greptileai?" or ask follow-up questions!

Copilot AI review requested due to automatic review settings February 15, 2026 15:10
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a bug where external channel plugins (like DingTalk) were not appearing in interactive menus for openclaw configure --section channels and openclaw onboard commands. The fix ensures the plugin registry is loaded before these commands display their channel selection menus by adding them to the PLUGIN_REQUIRED_COMMANDS whitelist.

Changes:

  • Extended PLUGIN_REQUIRED_COMMANDS constant to include 'configure' and 'onboard' commands
  • This ensures external channel plugins are loaded and visible in interactive configuration flows

@soimy soimy changed the title Fix/plugin registry loading for configure onboard fix(plugin): registry loading for configure onboard Feb 15, 2026
@openclaw-barnacle openclaw-barnacle bot added cli CLI command changes size: XS labels Feb 15, 2026
@soimy
Copy link
Author

soimy commented Feb 15, 2026

CI Error seems to be pre-existed, not related to this PR's file change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli CLI command changes size: XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants