Skip to content

fix(status): stop reporting disabled memory plugins as enabled - #164722

Closed
ooiuuii wants to merge 2 commits into
openclaw:mainfrom
ooiuuii:fix/memory-status-disabled-entry-164720
Closed

ooiuuii wants to merge 2 commits into
openclaw:mainfrom
ooiuuii:fix/memory-status-disabled-entry-164720

Conversation

@ooiuuii

@ooiuuii ooiuuii commented Oct 4, 2026 •

Copy link
Copy Markdown
Contributor

Closes #164720

What Problem This Solves

Fixes status reporting a selected memory plugin as enabled when its configuration entry explicitly disables it.

User Impact

Users see the disabled selection and its reason without confusing it with an unprobed backend or disabled memory search. No configuration, migration, or plugin activation behavior changes.

Why This Change Was Made

The status owner now uses canonical normalized plugin entries before reporting enablement. The existing pure normalizer is mechanically separated from its channel-dependent sibling so status does not import catalog/filesystem/cache code; the previous module re-exports its existing interface unchanged.

Evidence

  • Actual production resolver → formatter proof: baseline emits enabled (plugin memory-core) · not checked for a synthetic explicitly disabled entry and fails both assertions; the repaired owner emits disabled (plugins.entries.memory-core.enabled=false) and passes both. No copied decision logic, plugin loading, private config, database, or provider call.
  • Identical focused regression/control matrix: 7 failed / 12 passed → 19 passed → 7 failed / 12 passed when only the entry-disabled check is reverted. Nine unrelated existing formatter tests are unselected; this is not a full-file or full-suite claim.
  • Controls preserve default/custom/trimmed selections, normalized entry precedence, global disable, slot none, unrelated disabled entries, independent search-disabled state, and enabled-but-unprobed not checked output.
  • Mechanical extraction preserves the original normalization algorithm and channel helper; 14 original-versus-extracted normalization cases match. Eight existing consumer import contracts remain intact. Static and executed status import traces contain only eight pure modules, without catalog/filesystem/cache/activation/database imports.
  • Node 24.19.0 with pinned patched Vitest 5.0.1: focused baseline/candidate/mutation one-worker wall times 0.686s / 0.679s / 0.719s. These are isolated harness timings, not the standard repository wrapper or CI seconds. Pinned root-config oxlint 1.83.0, oxfmt 0.68.0, and strict patch applicability pass.
  • One independent bounded P0–P2 review found no findings and independently replayed Node RED/GREEN, the 19-case Vitest matrix/mutation, and normalizer parity. This is not a canonical AutoReview-helper verdict.

Unrun / pending: full CLI/Gateway integration, schema execution, complete repository suites/build/type-aware checks, canonical isolated-file command timing, with hosted CI results recorded separately below. The actual null-backend formatting boundary is proven with color decoration and unrelated uncalled imports isolated; it is not a full status command run. This PR is offered for review with these limits, not as all-green or merge-ready. It does not add or change activation, permission, or allow/deny policy.

Current-head CI follow-up

Current head: ad401930260e3d812b7de8bb61b635886324ee74. The initial CI run 37172345044 failed. This follow-up corrects two introduced integration issues: contextual typing for the unchanged test cases, and the required pure-module entry in the existing wrapper source inventory. No CI logic or guard was weakened.

  • Exact pinned TypeScript 7.1.0-dev.20260920.1 reproduces the original TS2345 and then exits 0. This is a targeted projection using the actual plugin schema fragments and Vitest declarations, not a full repository typecheck.
  • The actual runtime-import-closure owner reproduces two missing/unresolved-source failures, then passes both after the single inventory entry. This covers the affected seven-file pure closure, not the entire wrapper boot.
  • Updated behavioral matrix remains 7 failed / 12 passed → 19 passed → 7 failed / 12 passed, with the same nine unrelated tests unselected. One-worker wall times: 0.726s / 0.688s / 0.725s. Formatting, non-type-aware lint, and patch checks pass. Independent bounded follow-up review replayed these checks with no P0–P2 findings.
  • Two other initial CI failures have base-source attribution. The suppression inventory mismatch comes from two comments already present in exact CI base b02aaf1e3e0725e60772da600c1773b194f8f16c, with identical base/test-merge source and expected-inventory blobs. The mock-export ENOBUFS is consistent with the unchanged base helper reading a 1,675,312-byte baseline through execFileSync without a maxBuffer override. That failing invocation was not logged; this is a specific source-level explanation, not an executed exact-base reproduction. Those unrelated files are not modified here.

Current-head CI run 37173998881 completed with 51 successful jobs, 26 skipped jobs, and two failing checks plus the aggregate gate. The corrected test-type graph passed (job 111352971384); the full native eager-import-closure test file passed 17/17 (job 111352853500). The remaining check failures are the same suppression-inventory mismatch and mock-export ENOBUFS. Their relevant source blobs/config tree match between the new exact CI base 47206579b8e226097f26df39b93bf590edf5c912 and test merge bbd8061dada2b9c99d35f870e6dfa9b595cba3c7, unchanged from the source attribution above; no exact-base reproduction is claimed. Full status-command integration and other unrun checks remain open. CI is not green and this is not a merge-readiness claim.

@clawsweeper

clawsweeper Bot commented Oct 4, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added commands Command implementations size: L labels Oct 4, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. labels Oct 4, 2026
@clawsweeper

clawsweeper Bot commented Oct 4, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs real behavior proof before merge.

What this changes

The PR makes memory status honor explicitly disabled plugin entries, separates the existing pure configuration normalizer, and adds regression coverage.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The patch is focused and source-consistent, with useful regression evidence, but real-setup validation remains incomplete.
Proof confidence 🦐 gold shrimp (3/6) Real behavior proof is necessary before merge. See Before merge.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Merge readiness

⛔ Blocked before merge - 2 items remain

The fix remains necessary: current main and the latest release still ignore the selected plugin’s disabled entry. No introduced correctness defect was found, but the supplied isolated execution does not yet satisfy the real-setup proof gate.

Priority: P2
Reviewed head: ad401930260e3d812b7de8bb61b635886324ee74

Before merge

  • Add real behavior proof - Needs real behavior proof before merge: captured isolated execution exercises the actual memory status resolver and formatter and shows the repaired disabled output, but substituted imports and the explicitly unrun status command leave the external-contributor real-setup gate incomplete. No stored-data contract changes are introduced. After adding proof, update the PR body, then request a new review with @clawsweeper re-review. The PR author or someone with repository write access can request it.
  • Complete next step - Add after-fix real status-command proof for disabled and enabled selected-entry controls, and record canonical one-worker test timings with CI seconds when available. Terminal output, logs, or terminal screenshots count; redact keys, IP addresses, phone numbers, private endpoints, and other private data. Update the PR body to trigger re-review; if that does not happen, ask a maintainer to comment @clawsweeper re-review.

Findings

None.

Agent review details

How this fits together

OpenClaw’s status subsystem reads plugin configuration to describe the selected memory backend and decide whether to inspect it. Its result feeds CLI status formatting and the Gateway’s CLI status projection.

flowchart TD
  A[Plugin configuration] --> B[Shared configuration normalizer]
  B --> C[Memory status resolver]
  C --> D{Selected plugin enabled}
  D -->|No| E[Disabled status and reason]
  D -->|Yes| F[Backend status or not checked]
  E --> G[CLI status output]
  F --> G
Loading

Technical review

Best possible solution:

Keep memory enablement reporting aligned with normalized plugin entries while preserving search-disabled and enabled-but-unprobed states.

Do we have a high-confidence way to reproduce the issue?

Yes, source establishes a focused reproduction: select memory-core, set its entry enabled=false, and pass the resolver result to status formatting. Current main still returns enabled; this review did not execute target code.

Is this the best way to solve the issue?

Yes, the repair uses the existing normalization owner and disabled-output path, preserves previous exports, and avoids adding configuration or activation policy.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against d0c59630c5a6.

Security

None.

Evidence

What I checked:

  • Introduced repair: The pinned merge-base-to-head diff adds the selected-entry enabled=false check. The normalizer extraction preserves the previous algorithm and re-exports its existing interface; the wrapper inventory includes the new source module. (src/status/memory-plugin.ts:20, ad401930260e)
  • Current-main necessity: Current main checks global plugin enablement and the memory slot, then returns enabled without checking the selected plugin entry. (src/status/memory-plugin.ts:24, d0c59630c5a6)
  • Latest-release behavior: The latest release, v2026.9.8, contains the same resolver without the selected-entry disable check. (src/status/memory-plugin.ts:24, fc23bc864e45)
  • Existing configuration contract: The plugin documentation states that an entry-level disable blocks a selected slot owner. The repair changes status reporting rather than introducing a new activation policy. Public docs: docs/tools/plugin.md. (docs/tools/plugin.md:216, ad401930260e)
  • Production callers and output: The resolver feeds the Gateway CLI projection and local status scans. The formatter already renders disabled results with their reason, and memory inspection already returns early for a disabled result. (src/commands/status.command-sections.ts:114, ad401930260e)
  • Captured proof and re-review continuity: Captured body sourceRevision f60c4661a32bae91de54420fcb35f852dcc654c3ae9ac8d9fcc016d1a76a008d reports actual resolver-to-formatter RED/GREEN execution and a 19-case mutation matrix, with substituted decoration/unrelated imports. It explicitly leaves the full status command and canonical test timings unrun. This supports the repair but leaves the previous review’s real-setup proof request unresolved; no prior correctness findings were retained. (ad401930260e)

PR surface

Source +8, Tests +110, Other +1. Total +119 across 6 files.

View PR surface stats
Area Files Added Removed Net
Source 3 207 199 +8
Tests 2 110 0 +110
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 1 1 0 +1
Total 6 318 199 +119

Review metrics

Metric Value Why it matters
Production versus regression coverage production net +8 lines; tests +110 lines; tooling inventory +1 line Most apparent production expansion relocates existing normalization code to preserve a pure status import path.

Root-cause cluster

Relationship: fixed_by_candidate
Canonical: #164720
Summary: This PR is the implementation candidate for the linked explicit-disablement report.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: Incorrect memory status can mislead diagnosis, but the established defect has limited scope and does not change plugin activation.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Add redacted after-fix status-command output from an isolated setup with a disabled selected entry and an enabled control; terminal output, logs, or terminal screenshots suffice.
  • Record canonical one-worker timings for the changed test files and CI seconds when available.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

History

Review history (2 earlier review cycles)
  • reviewed 2026-10-04T02:56:04.229Z sha 50aa96f :: needs real behavior proof before merge. :: none
  • reviewed 2026-10-04T03:29:36.968Z sha ad40193 :: needs real behavior proof before merge. :: none

Reviewed October 3, 2026, 11:43 PM ET / October 4, 2026, 03:43 UTC (Revision 3).

@openclaw-barnacle openclaw-barnacle Bot added the scripts Repository scripts label Oct 4, 2026
@openclaw-barnacle

Copy link
Copy Markdown

This pull request has been automatically marked as stale due to inactivity.
Please add updates or it will be closed.

@openclaw-barnacle openclaw-barnacle Bot added the stale Marked as stale due to inactivity label Oct 18, 2026
@openclaw-barnacle

Copy link
Copy Markdown

This pull request has been automatically marked as stale after 7 days without qualifying human activity.
Without new human activity, Barnacle may close it as not planned 7 days after this message was posted. This is administrative inactivity cleanup, not a claim that the problem is fixed.
A human update restarts the inactivity clock; a new PR head also restarts it. A maintainer can add no-stale for a durable hold, or bad-barnacle to suppress Barnacle. Remove the hold when work can resume.

@openclaw-barnacle

Copy link
Copy Markdown

Closing due to inactivity.
If you believe this PR should be revived, post in #clawtributors on Discord to talk to a maintainer.
That channel is the escape hatch for high-quality PRs that get auto-closed.

@openclaw-barnacle openclaw-barnacle Bot closed this Nov 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

commands Command implementations P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. scripts Repository scripts size: L stale Marked as stale due to inactivity status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Status reports a selected memory plugin enabled despite its disabled entry

1 participant