Repository navigation
refactor(extensions): deslop non-channel tool extensions - #164582
Conversation
Remove private forwarding layers, duplicate projections, unused options, and repeated normalization while preserving existing lifecycle, authority, and data owners. User-facing configuration, protocol shapes, model instructions, and CLI output stay unchanged.
Retain existing projection and startup-error construction, build optional Doctor repairs directly, and document the moved protocol assertions. Regenerate only the affected assertion debt entries and exclude the runtime file owned by the cache lane.
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: blocked before merge. Reviewed October 3, 2026, 6:23 PM ET / 22:23 UTC. ClawSweeper reviewWhat this changesThis PR simplifies private browser, Codex, memory, diagnostics, policy, voice-call, and Workboard helpers while preserving their existing user-facing contracts. Merge readiness⛔ Blocked before merge - 3 items remain The refactor remains useful and is member-authored. No concrete blocking regression was found in the introduced changes; available validation supports normal PR review. Priority: P3 Review scores
Verification
How this fits togetherThese bundled plugins receive agent requests, CLI commands, provider events, and stored state. Their existing owners perform browser actions, manage sessions and memory, export diagnostics, enforce policy, and handle calls or work items. flowchart TD
A[Agent requests and CLI commands] --> C[Bundled plugin owners]
B[Provider events and stored state] --> C
C --> D[Existing validation and authority checks]
D --> E[Browser and provider operations]
D --> F[Memory and work item updates]
D --> G[Diagnostics and command results]
Before merge
Agent review detailsSecurityNone. PR surfacePR surface statistics unavailable: the file list is incomplete. Review metrics
Stored data modelPersistent data-model change detected: Technical reviewBest possible solution: Keep the existing plugin owners and simplify their private adapters while preserving current validation, lifecycle, and stored-state contracts. Do we have a high-confidence way to reproduce the issue? Not applicable: this PR proposes behavior-preserving cleanup rather than a reported bug, and no failing runtime scenario was established. Is this the best way to solve the issue? Yes: consolidating private forwarding and normalization into existing owners is a maintainable approach; inspection found no concrete introduced defect. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 695fdbfc5e9c. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
…4582) ## What Problem This Solves Large non-channel tool extensions carry private factories, forwarding modules, duplicate projections, and configuration branches that their actual callers do not need. ## User Impact No user-visible change. Configuration keys, persisted data, protocol shapes, CLI output, model-facing descriptions, and UI behavior remain the same. No public SDK changes or migrations. ## Why This Change Was Made This batch removes 1,026 net production TypeScript lines, excluding tests and test support, while keeping each responsibility with its existing owner. - Browser: remove unused CDP session arguments; simplify iframe line expansion and action dispatch; inline one-use Chrome diagnostics, MCP predicates, target mapping, snapshot-delta factories, enumeration projections, and CLI/route forwarding. Cancellation, frame identity, reconnect classification, and error text stay with their current owners. - Codex: remove unused clock injection and notification forwarding, Computer Use helper chains, repeated diagnostic target resolution, catalog adapters, and redundant media bookkeeping. Reuse the existing approval-policy parser and simplify private cache/configuration projections without changing authority or lifecycle fences. - Memory: remove redundant whole-state decoding shells while retaining persisted-row validation; consolidate hybrid candidate construction; inline one-use embedding, CLI, backfill, and wiki mutation adapters; rely on the existing transactional SQL selection for standing-intent eligibility; remove a dead wiki write normalizer and LanceDB error-formatting wrappers. - Diagnostics: share ordinary/security log construction and transport emission, preserving trust checks, redaction, trace flags, failure reporting, and stdout delivery after OTLP failure. - Policy: replace an injected Doctor check factory with direct registration; share evaluation setup; carry resolved ingress values and their provenance once; remove intermediate approval-entry projections and redundant secret-input checks. - Voice: remove tunnel and response-body forwarding layers, duplicate status DTOs, and unreachable admitted-config branches; share credential errors and CLI call actions; reuse prepared Twilio URLs and one sorted latency sample. - Workboard: remove unused subscription-update options, private CLI/slash adapters, and the one-use workspace-check mode; keep canonical label and record normalization at their existing owners. - OpenAI realtime: delete an unused audio callback/decoder from the delegation controller. Neither production constructor provides it; media workers and WebRTC continue to own audio. ## Evidence Remote Linux proof on the reviewed candidate used Node 24.21.0 and pnpm 12.5.1. The exact Git commit and changed-file hashes were verified before execution; lint repairs and the final scope withdrawal were tested separately. - Focused owner and sibling tests: 2,646 passed across 128 files (476 seconds). - Both import-cycle checks: 0 cycles. Line-cap ratchet: passed. - Plugin contracts: 1,131 passed; one inherited failure in `extension-package-project-boundaries.test.ts` reports `packages/memory-host-sdk/src/host/config-utils.ts` as an extra core bridge. Neither the package directory nor that test is changed here. The earlier `.test-api` dependency-scanner failure was resolved by rebasing onto the existing main fix in openclaw#164483. - New Doctor check test: 2 cases, 56 ms test execution; `pnpm test extensions/policy/src/doctor/checks.test.ts --maxWorkers=1` took 24 seconds including test-worker preparation. The CI file adds two cases and replaces the old factory suite. `check-changed` passed both extension typechecks, all static ratchets, and all dead-export scans. Its lint findings were repaired and the affected extension lint and tests passed. No lint rules or tests were weakened. The generated assertion baseline shrinks only seven affected entries. Independent autoreview completed. Its six concerns were rejected after inspecting the retained secret-key suffix predicates, inherited-setting selection, early media-ID registration, shared approval parser, canonical label normalizer, and final app-ID sort. None of those findings is actionable against the owning code. A fresh review of the lint follow-up reported no P0–P2 findings. The current open-deslop census has no overlapping production files. The shared assertion baseline is regenerated only for seven entries owned by this batch; the other open lanes modify different entries. Codex protocol and dependency contracts were inspected directly in the sibling source checkout before edits.
Resolve the command-service.ts conflict with openclaw#164582: keep the registration-authority fencing and runtime selectors, adopt main's removal of the VoiceCallStatus alias and its inferred toVoiceCallStatus return type.
What Problem This Solves
Large non-channel tool extensions carry private factories, forwarding modules, duplicate projections, and configuration branches that their actual callers do not need.
User Impact
No user-visible change. Configuration keys, persisted data, protocol shapes, CLI output, model-facing descriptions, and UI behavior remain the same. No public SDK changes or migrations.
Why This Change Was Made
This batch removes 1,026 net production TypeScript lines, excluding tests and test support, while keeping each responsibility with its existing owner.
Evidence
Remote Linux proof on the reviewed candidate used Node 24.21.0 and pnpm 12.5.1. The exact Git commit and changed-file hashes were verified before execution; lint repairs and the final scope withdrawal were tested separately.
extension-package-project-boundaries.test.tsreportspackages/memory-host-sdk/src/host/config-utils.tsas an extra core bridge. Neither the package directory nor that test is changed here. The earlier.test-apidependency-scanner failure was resolved by rebasing onto the existing main fix in fix(ci): repair full release validation blockers #164483.pnpm test extensions/policy/src/doctor/checks.test.ts --maxWorkers=1took 24 seconds including test-worker preparation. The CI file adds two cases and replaces the old factory suite.check-changedpassed both extension typechecks, all static ratchets, and all dead-export scans. Its lint findings were repaired and the affected extension lint and tests passed. No lint rules or tests were weakened. The generated assertion baseline shrinks only seven affected entries.Independent autoreview completed. Its six concerns were rejected after inspecting the retained secret-key suffix predicates, inherited-setting selection, early media-ID registration, shared approval parser, canonical label normalizer, and final app-ID sort. None of those findings is actionable against the owning code. A fresh review of the lint follow-up reported no P0–P2 findings.
The current open-deslop census has no overlapping production files. The shared assertion baseline is regenerated only for seven entries owned by this batch; the other open lanes modify different entries. Codex protocol and dependency contracts were inspected directly in the sibling source checkout before edits.