Skip to content

fix(openclaw): read plugin settings from api.pluginConfig - #4372

Open
Cedric921 wants to merge 1 commit into
rtk-ai:developfrom
Cedric921:fix/openclaw-read-plugin-config
Open

Cedric921 wants to merge 1 commit into
rtk-ai:developfrom
Cedric921:fix/openclaw-read-plugin-config

Conversation

@Cedric921

Copy link
Copy Markdown
Contributor

Summary

  • The OpenClaw plugin read its settings from api.config, which on current OpenClaw hosts is the host config and carries no enabled/verbose — so both settings were silently ignored.
  • Read api.pluginConfig first (where OpenClaw now hands a plugin its resolved settings), falling back to api.config for older hosts.

Fixes #4358

Test plan

No Rust changed, and the plugin has no TS test suite, so I exercised register() against a mocked api (via tsx, with a locally built rtk on PATH):

api shape before after
{ pluginConfig: { verbose: true }, config: {...} } no [rtk] logs rewrite + registration logged
{ pluginConfig: { enabled: false }, config: {} } hook still registered hook not registered
{ config: { verbose: true } } (older host) logs logs (fallback preserved)
  • Manual testing: register() behaviour inspected before/after
  • cargo fmt --all && cargo clippy --all-targets && cargo test — n/a, TypeScript-only change
  • Not tested against a live OpenClaw Gateway.

OpenClaw now hands a plugin its resolved settings as api.pluginConfig;
api.config is the host config and carries no enabled/verbose, so both
settings were silently ignored. Fall back to api.config for older hosts.

Fixes rtk-ai#4358
@rtk-wshm-sync-bot rtk-wshm-sync-bot Bot added bug Something isn't working config openclaw labels Oct 1, 2026
@rtk-wshm-sync-bot

Copy link
Copy Markdown

wshm · Automated triage by AI

📊 Automated PR Analysis

🐛 Type bug-fix
🟢 Risk low

Summary

Fixes the OpenClaw plugin to read settings from api.pluginConfig (where current OpenClaw hosts place a plugin's resolved config), falling back to api.config for older hosts. Previously the plugin always read api.config, which on current hosts is the host config and lacks enabled/verbose, so those settings were silently ignored.

Review Checklist

  • Tests present
  • Breaking change
  • Docs updated

Linked issues: #4358


Analyzed automatically by wshm · This is an automated analysis, not a human review.

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

Labels

bug Something isn't working config openclaw

Projects

None yet

Development

Successfully merging this pull request may close these issues.

openclaw plugin: reads legacy api.config; verbose setting has no effect

1 participant