Repository navigation
fix(openclaw): read scoped plugin configuration - #4044
Open
yufanyang214-lab wants to merge 1 commit into
Open
yufanyang214-lab wants to merge 1 commit into
yufanyang214-lab wants to merge 1 commit into
Conversation
📊 Automated PR Analysis
SummaryFixes the OpenClaw plugin to read the scoped, validated Review Checklist
Analyzed automatically by wshm · This is an automated analysis, not a human review. |
4 of 6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The OpenClaw plugin reads the host-wide
api.configas its own settings. Consequently, the documentedplugins.entries["rtk-rewrite"].config.enabled = falsestill registers the rewrite hook, andconfig.verbose = trueproduces no rewrite logs.Read the validated
api.pluginConfiginstead, keeping the existing defaults. Six dependency-free Node tests exercise the actual plugin entry, covering both configuration regressions and the existing rewrite/exit-code behavior.Related: #1717 (verbose diagnostics). Its separate hook discovery/activation problem remains outside this fix.
Test plan
cargo fmt --all --checkcargo clippy --all-targetscargo test— 3,781 passed, 8 ignored, with Rust 1.98.1 and Git 2.51.0 on Linux.node --test openclaw/index.test.mjs— all 6 pass on Node 22.22.3 and 24.19.0.develop(d402152ffa050ca3753672e3d49c3f2ff498a07b) fail the two configuration cases and pass the other four cases.git diff --checkand clean patch-application check against that base.The Node tests mock the child-process boundary; they do not start RTK or an OpenClaw Gateway. They are currently run manually because the existing Cargo CI does not run Node tests. Exit 1 still passes through, exit 2 blocks, and exit 3 requires approval.
The first Cargo run with Git 2.43.0 hit the existing
git_log_malformed_digit_run_propagates_real_git_errorassertion: that version says "not a non-negative integer", whereas the test expects "not an integer". The complete suite passes with the Git 2.51.0 version named by that test. No Rust code or test assertions were changed.Host API contract
OpenClaw provides host configuration and plugin configuration separately in v2026.9.4 and the API builder.