fix: speed up status json channel detection#79269
Conversation
|
Codex review: needs maintainer review before merge. Summary Reproducibility: yes. The linked issue has live timing and trace evidence, and current main still shows the Real behavior proof Next step before merge Security Review detailsBest possible solution: Keep the lean JSON status path off manifest-registry construction for the cold-start channel boolean, with focused regression coverage and the changelog entry already included here. Do we have a high-confidence way to reproduce the issue? Yes. The linked issue has live timing and trace evidence, and current main still shows the Is this the best way to solve the issue? Yes. This is a narrow maintainable fix because it changes only the lean JSON cold-start channel-presence dependency while leaving full status and channel-detail paths on the manifest-backed policy. What I checked:
Likely related people:
Remaining risk / open question:
Codex review notes: model gpt-5.5, reasoning high; reviewed against fd08fd0b1fee. |
Signed-off-by: sallyom <[email protected]>
Summary
openclaw status --json --timeout 1000could take about 27s because the lean JSON path still used manifest-backed configured-channel policy.status --all, channel detail rendering, plugin manifest policy, and plugin activation semantics are unchanged.Change Type (select all)
Scope (select all touched areas)
Linked Issue/PR
openclaw status --jsontake ~27s on 2026.5.7 #79129Real behavior proof (required for external PRs)
openclaw status --json --timeout 1000should stay on the lean read-only path and return promptly instead of spending tens of seconds in repeated plugin metadata discovery.issue-79129ate7a18379177c5293e75bdea92886f03f63da358d, builtdist/entry.jsinvoked directly to avoid source-launcher rebuild timing noise./usr/bin/time -p node dist/entry.js status --timeout 1000 --jsonstracesyscall counts locally, and the local gateway socket probe was blocked by sandbox network policy (EPERM), so this proof covers command completion and the patched branch behavior rather than a reachable gateway.openclaw status --jsontake ~27s on 2026.5.7 #79129 reportselapsed=27.19on2026.5.7and a partial trace with 59,078openclaw.plugin.jsonreferences from repeated plugin metadata scanning.Root Cause (if applicable)
hasConfiguredChannelsForReadOnlyScope, which can load installed channel manifest records and build plugin manifest registry data even thoughstatus --jsondoes not render channel/plugin details.Regression Test Plan (if applicable)
src/commands/status.scan.fast-json.test.tsscanStatusJsonFastuses cheap channel presence detection and does not call manifest-backed configured-channel policy or preload plugin registries.User-visible / Behavior Changes
openclaw status --jsonavoids unnecessary plugin manifest discovery during lean status scans and should return faster on installs with many bundled plugin manifests.Diagram (if applicable)
Security Impact (required)
Yes/No) NoYes/No) NoYes/No) NoYes/No) NoYes/No) NoYes, explain risk + mitigation: N/ARepro + Verification
Environment
dist/entry.jsSteps
/usr/bin/time -p node dist/entry.js status --timeout 1000 --json.Expected
Actual
real 2.06.Evidence
Supplemental checks:
Human Verification (required)
What I personally verified (not just CI), and how:
status --jsonrun from the built CLI entry; focused regression tests for the fast JSON status path.--allmemory inspection coverage remains in the existing fast JSON test suite.Review Conversations
Compatibility / Migration
Yes/No) YesYes/No) NoYes/No) NoRisks and Mitigations
status --alland full channel/plugin paths still use manifest-backed policy when they need reason-rich channel/plugin answers.