Skip to content

refactor(plugins): deslop tool, search and media plugins - #160552

Merged
steipete merged 7 commits into
mainfrom
deslop/l144-tool-plugins
Sep 29, 2026
Merged

steipete merged 7 commits into
mainfrom
deslop/l144-tool-plugins

Conversation

@steipete

Copy link
Copy Markdown
Contributor

What Problem This Solves

Small tool, search, media, diagnostic, and migration plugins still duplicate existing Plugin SDK utilities and carry forwarding layers or unreachable branches after earlier owner migrations.

User Impact

The cleanup preserves tool names, descriptions and JSON schemas, external requests/endpoints, network and credential policy, manifests/config keys, migration outputs, and persisted schemas. It also restores intended IMAP credential errors and ordinal/positional Markdown edits in OC Path.

Why This Change Was Made

Reuse the existing owners instead of maintaining local copies. This follows the recent plugin sweeps, including #158437 and #158532, without repeating their completed changes. The production diff removes 575 net lines (661 added, 1,236 removed); tests/support add 76 net lines and documentation adds 3. The complete 187-file coverage log below records all production files over 200 lines and why retained code needs its existing owner.

Area Simplification and rationale
Bonjour Use SDK boolean/UTF-8 helpers; remove obsolete multi-service arrays and forwarding functions around the single Gateway advertiser, retaining startup/error/stop ordering.
fal Remove unreachable private-network branches: the existing HTTP owner explicitly fixes allowPrivateNetwork to false; reuse SDK record guards and remove an unused base-URL forwarding option.
Local CLI speech Share temporary workspace, process invocation and conversion lifecycle between ordinary speech and telephony; retain each output format and diagnostic.
ElevenLabs and Fish Audio Replace duplicate record/range wrappers and a forwarded audio-size constant with their SDK owners.
CUA Computer Replace the local promise queue with SDK KeyedAsyncQueue; reuse canonical record/string readers without changing authority checks or opaque references.
Search Reuse SDK numeric/object coercion in Firecrawl, Tavily and SearXNG; remove Exa's redundant post-validation pass/count wrapper and Brave's duplicate configured-credential accessor.
File Transfer and OpenShell Reuse number, deferred-promise, error and remote-command owners; share the existing skill-path validation; remove remote-path validation already performed by the unchanged Zod schema.
LLM Task, Lobster and Diffs Remove private SDK-forwarding barrels and unnecessary factory casts; import original owners directly. LLM Task uses canonical string and result projection.
1Password Use the SDK concurrency runner and secret-file seam; preserve four concurrent reads, per-ID results, secret restrictions and audit values.
ACPX Reuse tolerant JSON parsing, timestamp formatting and record/number coercion while retaining lease and session lifecycle contracts.
Crabbox, Geolocation and Document Extract Replace duplicate input/error coercion and config-field loops with existing SDK helpers.
Logbook and LanceDB memory Remove repeated casts and record/string validation; retain storage, capture, retirement and namespace policy.
Claude/Hermes importers Remove child-record/string-array wrappers and reuse canonical record/string-list projection; preserve import ordering, secrets and output.
OpenTelemetry Reuse SDK endpoint, string and numeric helpers; remove memory forwarding and consolidate repeated token/context/drop metric projection without changing order or zero handling.
Team Reports Reuse abortable sleep and identical metric/date rendering helpers. Before/after HTML and Markdown bytes are compared directly.
OC Path Use the existing resolver for writes and keep source positions coherent; remove forwarding CLI callbacks and temporary insertion-segment construction.

Fixes found along the way

  • IMAP: asNonArrayRecord always returns an object, so malformed or absent passwords were silently deferred as unresolved secret references. asOptionalRecord restores the intended error while retaining deferred handling for unresolved object references. The regression failed before the repair.
  • OC Path: reads and find accepted #N, $first, and $last, but writes repeated slug-only lookup and replaced the first matching key. Writes now use the read resolver and selected source position, including duplicate keys and subsequent multiline/insertion edits. All three addressing regression cases failed before the repair.

Evidence

Validation ran on Blacksmith Testbox lease tbx_01m3m1wj99bmnezmkwvxdve0m3, hosted by https://github.com/openclaw/openclaw/actions/runs/36426070933. Commands used node scripts/crabbox-wrapper.mjs run --provider blacksmith-testbox --id <lease> --timing-json -- OPENCLAW_TESTBOX=1 OPENCLAW_TESTBOX_REMOTE_RUN=1 ... with frozen-lockfile installation. No tests, lint, typechecks, or builds ran on the Mac.

  • pnpm test:extensions:batch acpx,bonjour,brave,crabbox,cua-computer,diagnostics-otel,diffs,document-extract,elevenlabs,exa,fal,file-transfer,firecrawl,fish-audio-speech,geolocation,imap,llm-task,lobster,logbook,memory-lancedb,migrate-claude,migrate-hermes,oc-path,onepassword,openshell,searxng,tavily,team-reports,tts-local-cli: 281 executed files; 3,934 passed, 2 skipped, 792 seconds.
  • pnpm build: passed, 581 seconds, including SDK declarations/exports and Control UI.
  • pnpm plugin-sdk:api:diff --base 465fdd5adba67a2b8cef72fcc8c7fd688b7c9967 --head HEAD: passed, no public API changes, 260 seconds. pnpm plugin-sdk:check-exports: passed.
  • Import-boundary proof: src/infra/fs-safe-import-boundary.test.ts, src/plugins/contracts/core-extension-facade-boundary.test.ts, src/plugins/contracts/model-catalog-core-imports.test.ts, test/scripts/extension-import-boundary-checker.test.ts, and test/scripts/check-extension-package-tsc-boundary.test.ts: 59 tests passed, 35 seconds.
  • Actual plugin registration plus tool/provider factories: 82 descriptors across 34 registration scenarios and all 29 touched plugins were byte-identical before/after. This includes explicit empty inventories and configuration/context variants. Four Team Reports HTML pages and Markdown were also byte-identical. Combined capture: 494,477 bytes, SHA-256 996e08779abf2772326d8900bf3edf05d27b83cf4f3e834d26e65bf6840e17ae.
  • Regression cost measured with pnpm test <file> --maxWorkers=1: OC Path edit.test.ts 19 tests, 3.25 seconds wrapper wall initially (1.98 seconds Vitest); final replay 4.17 seconds wrapper wall (2.41 seconds Vitest); IMAP config.test.ts 2 tests, 3.11 seconds wrapper wall (1.80 seconds Vitest). Other test edits only migrate imports/mocks to their retained owner. CI timings are pending the first published run.
  • Independent Codex autoreview completed. Its sole proposed finding assumed CLI output could be raw PCM; the parser's complete output set excludes PCM, so telephony always converts. Rejected with source evidence; no accepted actionable findings remain.
  • Canonical assertion-baseline regeneration removed 34 allowances in 17 touched plugins; the exact shrink passed its independent review. The native changed-check plan passed extension and extension-test typechecks, extension/script lint, Doctor closure tests, dependency/architecture/legacy-store/coercion guards, and runtime import-cycle checks. Its own unused isQuotedSeg export finding was fixed; the final script, production, and full-tree dead-export scans are clean, the 19-test OC Path replay passes, and targeted parser lint reports zero warnings/errors.
  • The refreshed File Transfer replay passed 33 files / 356 tests (1 skipped), 92 seconds.

Known inherited guard failure: the normal changed-check runner stops at max-lines suppression ratchet because its environment-variable census finds 484 names against budget 483. The actual environment guard also fails identically in a separate clean checkout of freshly fetched main 6b9da9dc02879a2e27abac0318d65bd9b25b0f4b on replacement Testbox tbx_01m3m98em0wvp3cac6awyde4ak (https://github.com/openclaw/openclaw/actions/runs/36441973066). This lane adds no environment-variable names; its only changed OPENCLAW_* expression moves the existing Bonjour flag read. The budget and its checker remain unchanged. Every native planned command was executed with failures retained, so this is an attributed red guard, not a claimed green aggregate. The main-CI coordinator owns that repair.

Both conflict-free rebases preserved the three reviewed patches; the final parent is bc4a18ac08d694bf1f6ad72860240b67dee1676c. The final rebase changed none of this PR's production files or the SDK helper sources. The native changed-check plan and focused File Transfer replay cover the refreshed base, with the inherited aggregate failure recorded above. No CI workflow was manually dispatched or rerun for proof.

Complete production coverage: 187 files over 200 lines, sorted by original size

Lane l144 coverage

Base: 465fdd5adba67a2b8cef72fcc8c7fd688b7c9967. Production files over 200 lines, sorted by original size. All listed files and smaller production owners were read. Excluded model providers and channels: apple-fm, radius, a2a, buzz, clickclack, raft; other user exclusions remain untouched.

187 files covered.

Base LOC Production file Read outcome
1331 extensions/acpx/src/runtime.ts READ — generation admission, lease identity, diagnostics and model scoping own distinct invariants; retained.
1327 extensions/openshell/src/backend.ts READ — imported shared remote-command builders directly from the SDK and removed the cli.ts forwarding exports; mirror/remote lifecycle and retained legacy runtime contracts remain distinct.
965 extensions/acpx/src/codex-auth-bridge.ts READ — generated wrappers need self-contained launch/redaction logic; latest adapter-capture recovery preserved.
896 extensions/comfy/workflow-runtime.ts READ. One owner already handles image/music/video workflows. Kept capability overlays, secret-header resolution, local-host SSRF distinctions, cloud completion/history budgets, upload and output selection; SDK polling changes timeout errors and cloud request budgeting.
872 extensions/fal/image-generation-provider.ts READ. Removed dead private-relay trust policy and hostname matching: the shared fal HTTP owner explicitly sets allowPrivateNetwork:false and the SDK preserves that choice. Remaining model geometry, limits and request fields implement distinct external schemas.
862 extensions/diagnostics-prometheus/src/service.ts READ — prior SDK normalization/projection already centralized; distinct metric and scrape-auth contracts retained.
821 extensions/oc-path/src/oc-path/universal.ts READ — select deepest insertion slot directly; remove temporary segments array and redundant post-length assertion. Existing per-kind edit dispatch remains because encoding/coercion differ.
778 extensions/oc-path/src/oc-path/oc-path.ts READ — removed the orphan isQuotedSeg export after its outside caller disappeared; grammar, quote-aware scanners, resource caps, and diagnostics retain their substrate-specific contracts.
762 extensions/oc-path/src/oc-path/find.ts READ — remove repeated quote detection before canonical unquoteSeg. Existing shared walker dispatch owns expansion; JSONL predicates intentionally exclude null unlike JSONC predicates, so do not merge those conversions blindly.
734 extensions/agentsapi/agentsapi-session.ts READ — admission fences, native function receipts, recovery and settlement are API-specific; authority checks bracket awaits.
731 extensions/device-pair/index.ts READ — recent shared pairing resolver already adopted; local cleartext policy intentionally excludes mapped/CGNAT addresses accepted by shared classifiers.
730 extensions/logbook/src/service.ts READ: reuse SDK coerceErrorMessage; preserve capture rotation, model selection, operation admission, settlement and shutdown ordering. AsyncWorkScope has different context and admission semantics, so no forced lifecycle cutover.
723 extensions/code-mode-quickjs/src/code-mode.worker.ts READ — QuickJS handle ownership, VM snapshots, callback rebinding, budget pauses, cancellation and consumption receipts are engine-specific. Generic orchestration already comes through code-mode-executor-runtime and worker-task-server.
720 extensions/firecrawl/src/firecrawl-client.ts READ: reuse SDK numeric coercion for result count and scrape bounds; retain provider-specific error sanitization, result scanning, cache partitioning and private-endpoint classification.
711 extensions/logbook/src/store.worker.ts READ: existing prepared Kysely queries, worker dispatch, atomic replacement and prune checks have separate storage invariants; no safe remaining consolidation without storage-contract changes.
704 extensions/diffs/src/render.ts READ: remaining render variants share renderSection/buildRenderedBodies from #158532; HTML/CSS and variant-specific output retained byte-for-byte.
695 extensions/diagnostics-otel/src/service.ts READ — removed environment, sample-rate, and endpoint wrappers through SDK helpers.
692 extensions/agentsapi/agentsapi-messages.ts READ — live/canonical projections differ intentionally; shared SDK builders and classification already used.
685 extensions/cua-computer/src/driver-result.ts READ — use SDK record coercion/type guards instead of repeated object/array checks and casts; keep native validation, enum mapping, projection filters, authority generation and opaque references local.
684 extensions/team-reports/src/store.worker.ts READ — recent #159148/#159101 own streaming SQLite aggregation; storage admission, transactions, snapshots, and typed dispatch retained.
679 extensions/crabbox/src/crabbox-worker-warm-image.ts READ — replay, pins, capture, retirement and custody checks have distinct lifecycle obligations.
675 extensions/memory-lancedb/index.ts READ — tool authority, per-agent namespaces, cooldowns, and capture lifecycle already have dedicated owners; tool bytes unchanged.
673 extensions/crabbox/src/crabbox-worker-provider.ts READ — #159357 already centralized command plumbing; preparation/enrollment retain distinct authority and cleanup boundaries.
671 extensions/fal/video-generation-provider.ts READ. Removed dead private-network policy plumbing. Retained fal queue response validation, explicit pending-status vocabulary, custom timeout diagnostics and per-model request controls; canonical polling would change diagnostics and retry behavior.
649 extensions/agentsapi/agentsapi-client.ts READ — official SDK owns requests; local validation checks correlation, artifact bounds and pagination.
631 extensions/agentsapi/agentsapi-attempt.ts READ — shared cancellation, deadlines, lifecycle and prompts already adopted; local cleanup authority/native identity preserved.
629 extensions/beam/src/mirror.ts READ — guarded upload, source consent, cancellation, terminal retries, and receiver-bound acknowledgements are distinct Beam contracts.
627 extensions/agentsapi/agentsapi-tools.ts READ — shared invocation/result owners already used; local output/media projection retains API contract.
621 extensions/crabbox/src/crabbox-worker-warm-image-store.ts READ — atomic compare/retry generations preserve resource custody; no equivalent higher-level SDK loop.
612 extensions/team-reports/src/render/styles.ts READ — vendored Carapace primitives and page-specific responsive/accessibility/print/theme cascade have no SDK stylesheet owner.
610 extensions/cua-computer/src/commands.ts READ — replace plugin-local PromiseQueue with SDK KeyedAsyncQueue for snapshot/action/close FIFO ordering. Native image encoding and display authorization are platform-specific.
608 extensions/canvas/src/host/a2ui-app/bootstrap.js READ: standalone browser renderer retains its Lit/A2UI and bridge contracts; SDK server helpers would change its bundling surface. Read-only reconnect investigation found no supported same-instance detach/reinsert: hidden widgets retain the iframe and resource updates replace its browsing context. No justified behavior change.
592 extensions/diffs/src/browser.runtime.ts READ: remove pass-through type import and narrating header; retain executable search, cache and lease ownership because available SDK executable helpers differ on platform/path/executability semantics.
582 extensions/memory-lancedb/embeddings.ts READ — provider-retirement sequencing, direct OpenAI fallback, timeout phases, and vector normalization preserve distinct dependency contracts.
578 extensions/onepassword/src/broker.ts READ: replace local textParam with SDK readStringValue; preserve empty-string audit values and policy/grant/nonce checks.
568 extensions/acpx/src/session-owner-migration.ts READ — publication, owner claims and recovery fences are required migration boundaries.
565 extensions/openshell/src/fs-bridge.ts READ — replaced the handwritten ENOENT property guard with SDK extractErrorCode; retained fs-safe type guard and mutation preflight ordering.
554 extensions/oc-path/src/cli.ts READ — remove five forwarding action callbacks; Commander directly owns the existing handlers. Bounded file reads and deterministic diff rendering preserve distinct CLI contracts.
553 extensions/file-transfer/src/shared/policy.ts READ — no further sound consolidation: authored glob constraints, exact grants, migration reapproval and runtime-snapshot authority have separate security contracts.
551 extensions/acpx/src/pi-session-store.ts READ — replaced tolerant JSON parse catch with SDK safeParseJson; append bounds/cache identity retained.
550 extensions/agentsapi/agentsapi-native-tool-projection.ts READ — SDK accumulators/formatters already used; enrichment and receipts have separate duties.
547 extensions/file-transfer/src/shared/node-invoke-policy-preflight.ts READ — no further sound consolidation: initial/changed-target retry and archive descendant checks bind different evidence and preserve distinct audit outcomes.
532 extensions/exa/src/exa-web-search-provider.runtime.ts READ: remove one-use result count wrapper, impossible field-map fallback and repeated validation after admission; retain contents field order, exact error strings and request schema.
520 extensions/brave/src/brave-web-search-provider.runtime.ts READ: shared SDK already owns deadline, HTTP, cache, credential and filter operations; remaining web/LLM-context request and response differences are vendor contracts.
515 extensions/github/src/github-api.ts READ: transport already uses canonical response limits, error coercion, retry and cache helpers; fixed-origin redirect, identity revalidation, quota and GraphQL semantics remain GitHub-owned. Public api.ts consumers require its narrow helpers.
513 extensions/diffs/src/tool.ts READ: import SDK types directly; preserve schema, text, errors, render normalization and results. SDK ToolInputError differs by trusted identity/status and is exported only through code-mode runtime, so retained local class.
513 extensions/team-reports/src/aggregate.ts READ — bounded evidence, attribution, retained daily snapshots, and prototype-safe counting are report policy; canonical generic replacement would alter outputs.
510 extensions/github/src/detail.ts READ: public repository identity checks and partial comment/file/check projection guard different boundaries and cannot be unified without altering visibility or failure behavior.
505 extensions/elevenlabs/speech-provider-factory.ts READ. Replaced the normalizeVoiceSetting pass-through with the existing SDK range coercer. Retained directive aliases, talk precedence, output-family mapping and vendor model normalization.
495 extensions/migrate-hermes/auth.ts READ — credential matching, fingerprinting, and OAuth model merge retain required credential contracts.
493 extensions/device-pair/notify.ts READ — one-shot arm identity/CAS cleanup protects overlapping re-arm; stored-row validation and notification projection retain distinct contracts.
493 extensions/team-reports/src/sources/github/index.ts READ — API endpoints, discovery windows, search quotas, merger lookup, and coauthor attribution are GitHub/report contracts.
484 extensions/pixverse/video-generation-provider.ts READ. Already uses SDK auth, request config, polling, multipart and JSON helpers. Remaining code owns the ErrCode/Resp envelope, per-request trace header, region routing and vendor field mapping.
470 extensions/acpx/src/process-reaper.ts READ — wrapper/lease/process identity prevents terminating unrelated processes.
467 extensions/cua-computer/src/driver-client.ts READ — direct/native lazy transport adapters own authorization ceilings, exact session IDs, native error conversion, SDK loading and teardown. Previous #157825 already consolidated shared invocation; no new speculative generic adapter.
467 extensions/migrate-hermes/config-provider-contract.ts READ — replaced childRecord facade; transport aliases/defaults and endpoint/header secret classification remain Hermes-specific.
464 extensions/acpx/src/service.ts READ — startup timeout keeps unref semantics unavailable in shared SDK timeout helper.
463 extensions/crabbox/src/crabbox-worker-profile.ts READ — SDK coercion already adopted; Go duration and replay identity preserve external/persisted formats.
462 extensions/cua-computer/src/mcp-driver-client.ts READ — reuse SDK readStringField for refusal-code extraction and remove repeated record checks/cast. Existing MCP transport already uses canonical agent-harness runtime from #157825.
454 extensions/team-reports/openclaw.plugin.json READ: static capability, config and secret metadata are the unchanged discovery contract; generating or rewriting them would violate the lane manifest constraint.
447 extensions/diffs/src/store.ts READ: import SDK logger directly; current worker-backed blob API already owns persistence; retain token checks, metadata validation and cleanup races.
444 extensions/cua-computer/src/window-actions.ts READ — action-specific native request construction and generation checks are required; previous #157825 consolidated common targeted dispatch. No schema/request changes.
437 extensions/team-reports/src/summaries.ts READ — deterministic digest, prompt, response validation, repair, and fallback output are intentional report contracts.
432 extensions/session-share/src/session-catalog.ts READ: settled-page cache and service-owned hydration implement distinct caller/service authority and paging rules; existing shared SDK handles paging, deadline, transcript and identity projection.
429 extensions/acpx/src/harness-attempt.ts READ — transcript admission, live capability and approval settlement checks own distinct boundaries.
427 extensions/bonjour/src/advertiser.ts READ — replaced handwritten boolean parsing and UTF-8 loop with SDK owners; removed obsolete multi-service array/forwarders for the sole Gateway service.
425 extensions/diagnostics-otel/src/service-recorders-operations.ts READ — removed memory forwarding wrapper and consolidated optional drop-class recording.
424 extensions/crabbox/src/crabbox-managed-binary.ts READ — SDK owns guarded fetch/files/archive/locks; publication and waiter custody remain local.
420 extensions/tts-local-cli/speech-provider.ts READ. Unified synthesis and telephony workspace/process/conversion lifecycle. Kept exact audio detection, byte caps, process-error precedence, log text, command quoting and format projection.
419 extensions/diagnostics-otel/src/service-traces.ts READ — active/retained span lifecycle and trust distinctions are required.
418 extensions/crabbox/src/crabbox-worker-desktop-windows.ts READ — standalone guest PowerShell/C# needs SID/session/process checks before SDK exists.
417 extensions/tavily/src/tavily-client.ts READ: reuse SDK result-count coercion; retain search/extract content budgets, URL spelling, publication-date rules and response projection.
416 extensions/cua-computer/src/frame.ts READ — frame and reference lifecycle are authorization-bearing CUA state, with different uniqueness/invalidation rules; generic map wrappers would conceal those invariants.
414 extensions/diagnostics-otel/src/service-genai-content.ts READ — provider-shape normalization and reasoning redaction preserve distinct contracts.
408 extensions/diagnostics-otel/src/service-recorders-tools.ts READ — switched positive-number validation to SDK owner.
406 extensions/memory-lancedb/memory-capture-sanitization.ts READ — provenance markers, legacy transport shapes, sender detection, and bounded stripping protect exact capture behavior.
406 extensions/migrate-hermes/model.ts READ — SDK record guards replace hand-rolled checks/casts and double coercion.
403 extensions/diagnostics-otel/src/service-recorders-usage.ts READ — consolidated repeated token and context recording while retaining order and zero handling.
397 extensions/crabbox/src/crabbox-worker-warm-image-capture.ts READ — claim, scrub, submission uncertainty and publication are distinct custody transitions.
397 extensions/migrate-hermes/config-mcp.ts READ — SDK asOptionalRecord replaces repeated ternaries; policy translations and manual follow-ups preserved.
395 extensions/file-transfer/src/node-host/file-write.ts READ — existing fs-safe integration owns rollback and rooted create; overwrite-inode bindings and missing-parent preflight retain distinct shipped behavior.
394 extensions/imap/src/watcher.ts READ: cursor/claim admission, auth retries and reconnect/sweep queues have distinct lifecycle and persisted-state contracts; no sound state-machine cutover without changing those contracts.
394 extensions/logbook/src/analyze.ts READ: use SDK record/string coercion; remove redundant JSON-segments casts and appSites branch; retain time parsing, bounds and card coverage logic.
392 extensions/migrate-hermes/secrets.ts READ — source-specific discovery, consent/conflict, and lock flow retain identical secret-import outcomes.
392 extensions/mxc/src/mxc-container-config.ts READ — shared containment/path helper already used; required/optional host grants, overlap rejection and ProcessContainer projection are MXC-specific.
390 extensions/crabbox/src/crabbox-worker-node-enrollment.ts READ — guest bootstrap runs before installed SDK; #159546 owns download recovery.
386 extensions/github/src/preview.ts READ: credential-dependent cache sharing, public-repository transfer guards, bounded avatar/coauthor fetches and decoration degradation retain distinct contracts.
377 extensions/deepgram/realtime-transcription-provider-factory.ts READ. SDK owns websocket lifecycle; local code owns Deepgram final/partial event assembly, retained-transcript byte bounds and interrupted-turn/finalize semantics. No equivalent generic replacement preserves these contracts.
375 extensions/team-reports/src/scheduler.ts READ — UTC scheduling, accepted-run reuse, shutdown settlement, and secret-safe failure reporting are service policy.
374 extensions/runway/video-generation-provider.ts READ. Already uses SDK auth, request config, polling and generated-video download. Endpoint/model validation, ratio mapping and reference encoding are vendor contracts.
370 extensions/diffs/src/config.ts READ: SDK config schema type imported at owner; compatibility aliases and enum/numeric normalization retained because they protect supplied config and shipped aliases.
365 extensions/fish-audio-speech/speech-provider.ts READ. Removed the local MAX_AUDIO_BYTES forwarding export and imported the existing SDK owner directly. Remaining directive/range handling already uses SDK helpers; output targets and talk precedence are vendor contracts.
364 extensions/acpx/src/runtime-session-store.ts READ — reset generations and physical write ordering are required.
359 extensions/diffs/src/viewer-client.ts READ: remove narrating header; retain standalone browser runtime, toolbar and hydration contracts; no appearance or rendering changes.
358 extensions/mxc/src/mxc-backend.ts READ — SDK process/path owner already adopted; payload/temporary-directory ownership, PTY modes and shell failure contracts differ.
346 extensions/team-reports/src/http.ts READ — request-local authorization/revalidation and report routing retained; no generic response helper preserves all headers and head semantics.
345 extensions/crabbox/src/crabbox-worker-provision-commands.ts READ — #159357 centralized execution; readiness/cleanup keep different failure semantics.
343 extensions/comfy/openclaw.plugin.json READ. Static capability/config/secret metadata is a hard unchanged contract; repeated per-capability descriptors cannot be generated without changing the manifest format.
340 extensions/deepgram/audio-flux.ts READ. SDK owns command, deadline and websocket transport. Remaining code implements the Flux v2 one-shot upload/CloseStream protocol and bounded retained transcript semantics.
338 extensions/migrate-claude/source.ts READ — bounded memory discovery and home/project selection retain source contracts.
333 extensions/searxng/src/searxng-client.ts READ: use SDK object coercion and remove cast-only response type; retain result filtering, retry policy and self-hosted routing distinctions.
329 extensions/file-transfer/src/workspace-bridge.ts READ — unary/binary fallback, workspace authority checks and paginated metadata validation are required boundaries, not duplicate validation.
326 extensions/diagnostics-otel/src/service-metrics.ts READ — explicit metric descriptions, units, and bucket contracts retained.
325 extensions/team-reports/src/render/people.ts READ — reused shared metric markup and UTC day formatter; ranking, missing-day charts, and calendar output unchanged.
323 extensions/file-transfer/src/shared/node-invoke-policy.ts READ — recent shared preflight extraction already owns canonical checks; final-result and archive verification must remain after node IO.
315 extensions/migrate-hermes/config-providers.ts READ — childRecord facade removed; source precedence, upserts, and config reporting remain plugin policy.
313 extensions/teams-meetings/src/transports/teams-meetings-status-prejoin-source.ts READ — shared MeetingPlatformAdapter already owns runtime scaffolding; remaining Teams-specific UI identity/device-admission state retained.
312 extensions/parallel/src/parallel-mcp-search.runtime.ts READ: bounded JSON/SSE envelope selection and negotiated MCP headers/handshake differ from generic MCP clients; existing shared guarded HTTP owner retained.
311 extensions/agentsapi/agentsapi-transcript.ts READ — SDK owns durable append/builders; native ordering/idempotency remain local.
302 extensions/memory-lancedb/memory-policy.ts READ — retained-occurrence fingerprints, prefix matching, capture triggers, and injection policy are memory-specific contracts.
301 extensions/azure-speech/speech-provider.ts READ. Already uses SDK secret resolution, API-key fallback and record/string coercion. Distinct region/endpoint precedence and telephony/voice-note formats remain provider-owned.
300 extensions/elevenlabs/realtime-transcription-provider-factory.ts READ. SDK owns realtime websocket lifecycle. Retained vendor config aliases, numeric-string parsing, ready/commit events and timestamp-echo suppression.
297 extensions/parallel/src/parallel-search-normalize.ts READ: prior shared paid/free normalization already owns request/cache/result flow; session-id limits and generated-id cache removal are required contracts.
295 extensions/mxc/src/fs-bridge.ts READ — SDK fs-safe root and rename target owner already adopted; mount/writable checks preserve protected skill overlays.
293 extensions/onnx/src/worker-client.ts READ. Process admission, cancellation, FIFO queue, retained native inference slot until close, IPC validation and narrow environment are one coherent owner; no matching SDK worker contract preserves them.
291 extensions/acpx/src/codex-trust-config.ts READ — filtered TOML inheritance preserves representation/trust limits.
290 extensions/mxc/src/sandbox-policy-loader.ts READ — strict policy parse and source-specific diagnostics protect fail-closed layering; no behavior-equivalent SDK policy owner.
289 extensions/crabbox/doctor-contract-api.ts READ — schema admission and migration output are protected historical contracts.
288 extensions/diagnostics-otel/src/service-attributes.ts READ — attribute bounds, redaction, and security-specific transformations retained.
287 extensions/file-transfer/src/node-host/file-fetch.ts READ — removed local positive-finite-number parser in favor of SDK asPositiveFiniteNumber, preserving floor, default and cap behavior.
285 extensions/memory-lancedb/doctor-contract-api.ts READ — explicit Doctor migrations, legacy row detection, batched deletion, and ownership verification cannot change in deslop.
282 extensions/file-transfer/src/node-host/dir-fetch.ts READ — removed duplicate numeric parser via SDK; retained plugin list-based enumeration required by #159654.
282 extensions/lobster/src/lobster-runner.ts READ: replace local missing-path error guard with SDK extractErrorCode; keep local timeout because it owns AbortController cancellation and non-Error rejection semantics that SDK withTimeout does not supply directly.
280 extensions/admin-http-rpc/src/handler.ts READ — shared bounded body read and authenticated dispatch already used; error body/status mapping is the Admin RPC wire contract.
278 extensions/talk-voice/index.ts READ. Retained owner/admin authority, config mutation, voice matching and exact tool descriptors. Small public api.ts barrel is used by local production/tests and was not removed without a public-surface contract review.
276 extensions/crabbox/src/crabbox-sandbox-backend.ts READ — replaced exact error-message projection with SDK helper; remote-shell SDK already owns workspace/execution.
274 extensions/onepassword/src/op-client.ts READ: preserves trusted absolute executable boundary, secret-file semantics, service-account-only environment, provider errors and field identity checks; no equivalent owner for these vendor contracts.
273 extensions/memory-lancedb/lancedb-store.ts READ — Arrow identity, native schema/checkout behavior, agent predicates, and atomic delete receipts retain dependency/storage contracts.
268 extensions/canvas/src/cli.ts READ: existing shared node CLI and numeric owners are used. parseNodeCandidates validates a deliberately narrower untrusted view than unvalidated shared parseNodeList; removing it would weaken input handling.
266 extensions/diagnostics-otel/src/service-logs.ts READ — per-transport failures and trust-gated security logging require distinct handling.
266 extensions/diffs/src/http.ts READ: remove runtime-api pass-through and import ingress owner directly; preserve authorization, proxy trust, rate limiting, CSP and GET/HEAD parity.
266 extensions/inworld/tts.ts READ. Kept bounded NDJSON/audio/error handling and restrictive hostnameAllowlist policy. The similarly named SDK allowedHostnames helper bypasses private-host checks and is not equivalent.
263 extensions/acpx/src/pi-session-catalog-runtime.ts READ — canonical session-catalog family already adopted; local continuation policy required.
260 extensions/acpx/src/harness.ts READ — descriptor-driven shared harness owns agent cases; authentication classification retained.
259 extensions/logbook/index.ts READ: explicit read/write scope split, generation fences and runtime retirement have independent security/lifecycle contracts; no sound remaining consolidation.
255 extensions/onepassword/onepassword-secret-ref-resolver.js READ: replace private worker pool with SDK concurrency owner and direct fs-safe secret import with SDK seam; keep concurrency 4, per-ID results, endpoint/argv/environment/secret limits unchanged. State/home helpers retained because SDK counterparts differ on profile/home/fallback rules.
248 extensions/acpx/register.runtime.ts READ — lazy service publication and compare-before-replace lifecycle checks required.
247 extensions/migrate-hermes/source.ts READ — platform/profile source discovery and guarded global fallback retain source contracts.
247 extensions/team-reports/src/sources/discord/index.ts READ — configured-channel/thread discovery and half-open snowflake collection are distinct Discord acquisition contracts.
246 extensions/diagnostics-otel/src/service-recorders-harness.ts READ — existing consolidated harness lifecycle preserves attribution and retained contexts.
244 extensions/migrate-claude/memory.ts READ — bounded scanning and destination overlap/symlink checks preserve import safety.
244 extensions/team-reports/src/render/report.ts READ — moved unchanged metric markup into existing shared owner; report distributions and member projections retained.
243 extensions/file-transfer/src/tools/dir-fetch-tool.ts READ — shared archive and media owners already used; byte-bounded manifest projection preserves exact paths and is not interchangeable with directory pagination.
242 extensions/acpx/src/pi-session-catalog.ts READ — replaced local ISO timestamp wrapper with SDK formatter, preserving timestamp fallback order.
242 extensions/crabbox/src/crabbox-worker-node-process.ts READ — receipt verification preserves platform-specific process ownership before SDK install.
242 extensions/onnx/src/artifacts.ts READ. Recently migrated to SDK fsRoot, readFileWindowFully and streaming sha256File. Remaining pinned artifact validation and no-overwrite publication/cleanup are integrity contracts.
241 extensions/diagnostics-otel/src/service-content-normalization.ts READ — bounded valid-JSON serialization has no equivalent SDK replacement.
241 extensions/llm-task/src/llm-task-tool.ts READ: replace private params/config redeclarations, string coercion and result projection with existing SDK contracts; removes lazy factory type laundering. Selected-provider model prefix handling remains distinct from alias resolution.
241 extensions/memory-lancedb/memory-cli.ts READ — shared numeric readers already used; query projection, filter validation, and embedding cleanup retain CLI contracts.
240 extensions/cua-computer/src/driver-artifact-verification.ts READ — reuse SDK record/string readers for manifest identity; preserve exact digest/version/platform diagnostics and native artifact checks. fs-safe hashing already replaced the old implementation in #158008.
238 extensions/team-reports/src/config.ts READ — config schema, bounded people-file read, and batched secret assignment use canonical SDK owners already.
237 extensions/acpx/doctor-contract-api.ts READ — retained migration authority, archive and lazy empty-state boundary.
237 extensions/cua-computer/src/browser-actions.ts READ — retained browser-specific argument construction, resource cleanup and opaque reference invalidation; previous #157825 already consolidated shared browser actions.
237 extensions/diagnostics-otel/src/service-genai-attributes.ts READ — removed positive/nonnegative forwarding validators in favor of SDK owners.
235 extensions/cua-computer/src/recording-actions.ts READ — native schema projection intentionally redacts paths/errors; recording cleanup differs by completion and ownership. No shared helper provides that policy unchanged.
235 extensions/diagnostics-otel/src/service-exporter.ts READ — replaced endpoint/environment validators and removed sample-rate validator.
234 extensions/acpx/openclaw.plugin.json READ: static capability, config and secret metadata are the unchanged discovery contract; generating or rewriting them would violate the lane manifest constraint.
234 extensions/diffs/openclaw.plugin.json READ: static capability, config and secret metadata are the unchanged discovery contract; generating or rewriting them would violate the lane manifest constraint.
231 extensions/team-reports/src/sources/github/client.ts READ — existing guarded fetch and retry-after parser canonical; pagination origin, rate-limit, body redaction, and empty-repo behavior are source policy.
230 extensions/logbook/src/store.ts READ: worker adapter methods retain domain API and close admission; frame I/O methods own queued file/database ordering. Removing them would expose transport encoding at every service caller without removing ownership.
228 extensions/crabbox/src/crabbox-worker-desktop-setup.ts READ — shared XFCE owner already used; launcher/renderer readiness are distinct.
226 extensions/acpx/src/config.ts READ — prior sweep centralized MCP descriptors/schema; local layout resolution remains necessary.
224 extensions/onnx/scripts/export-gliclass-instruct.py READ. Offline pinned dependency/checkpoint validation, export parity checks and reservation-preserving publication are Python/model contracts; no plugin SDK runtime seam applies.
223 extensions/cua-computer/src/execution-resources.ts READ — already uses SDK filesystem owner; per-execution resource handles and tree admission have security-specific lifecycle. Do not weaken validation or substitute generic unrestricted traversal.
222 extensions/file-transfer/src/node-host/workspace-memory.ts READ — replaced hand-rolled externally resolved promise with SDK createDeferred; stream start/abort ordering unchanged.
222 extensions/fish-audio-speech/tts.ts READ. Removed the redundant audio-byte-limit forwarding export. HTTP/stream bounds already use SDK owners; paginated own/public voice discovery and deduplication preserve vendor behavior.
222 extensions/inworld/speech-provider.ts READ. Already uses canonical SDK secret/API-key/numeric directive helpers. Provider defaults, temperature range, Talk merges and output encodings are distinct contracts.
221 extensions/canvas/scripts/bundle-a2ui.mjs READ: standalone Node build entry must run without built SDK; module resolution fallback, artifact hashing and published dual-version bundles retain concrete build contracts.
221 extensions/memory-lancedb/config.ts READ — replaced hand-rolled record checks/casts and throwing IIFE with SDK record narrowing; error text and accepted values unchanged.
220 extensions/imap/src/sender-gate.ts READ: sender case rules, constant-time tokens, DMARC/DKIM/trusted authserv strength and transient DNS outcomes protect distinct security contracts.
219 extensions/agentsapi/agentsapi-harness.ts READ — shared generations/bindings already used; wrappers enforce disposal/native restrictions.
219 extensions/azure-speech/tts.ts READ. Already uses SDK HTTP/SSRF/binary-response owners. SSML escaping, voice filtering and output-format names are provider-specific; general HTML helpers do not preserve XML bytes.
218 extensions/migrate-hermes/apply.ts READ — dependency-first order and WAL-aware snapshot/recovery are distinct responsibilities.
217 extensions/crabbox/src/crabbox-tool.ts READ — replaced exact error projection; schema/model-facing text untouched, SDK params/results retained.
217 extensions/file-transfer/src/node-host/file-create.ts READ — chunk ACK sequencing, digest validation, create-only atomic publication and authorized filesystem binding remain necessary.
216 extensions/code-mode-quickjs/src/executor.ts READ — uses SDK lazy module and WorkerTaskPool owners; engine WASM loading, transfer ownership and continuation cleanup cannot be removed without changing runtime contract.
216 extensions/migrate-hermes/plan.ts READ — canonical filterStringRecord owns environment projection; item ordering and source guidance preserved.
212 extensions/duckduckgo/src/ddg-client.ts READ: prior SDK HTML entity and bounded HTTP integration complete; provider-specific bold-tag removal, redirect decoding and challenge parsing cannot use generic helpers unchanged.
212 extensions/onepassword/src/secret-ref-cli.ts READ: reuse SDK error coercion and infer existing setup CLI type; preserve provider readiness and status text.
211 extensions/acpx/src/runtime-generations.ts READ — retirement and cleanup custody require these state transitions.
211 extensions/diagnostics-otel/src/service-exporter-health.ts READ — route failure ownership and public signal coalescing serve separate contracts.
211 extensions/logbook/src/prompts.ts READ: model-facing prompts and observation JSON schema remain byte-identical; remaining code directly builds required prompt content.
208 extensions/agentsapi/agentsapi-files.ts READ — shared staging/media owners already used; attachment identity/size/hosted-path checks retained.
205 extensions/session-share/src/node-commands.ts READ: shared paging/transcript/actor owners already handle generic flow; source group selection and post-read revocation are the plugin's authorization boundary.
204 extensions/parallel/src/parallel-web-search-provider.runtime.ts READ: guarded HTTP and JSON owners already used; endpoint normalization and two-stage credential redaction retain provider-specific semantics.
201 extensions/document-extract/document-extractor.runtime.ts READ: use SDK error-code extraction; keep renderer-specific per-page pixel budget, fallback/error reporting and native-section cancellation.
201 extensions/memory-lancedb/openclaw.plugin.json READ: static capability, config and secret metadata are the unchanged discovery contract; generating or rewriting them would violate the lane manifest constraint.

Fixes and measured scope

Final production diff before the mechanical assertion ratchet update: 661 lines added, 1,236 removed, 575 net removed across 103 production files in 29 touched plugins. Tests/support add 76 net lines; IMAP documentation adds 3 lines. The threshold was not reached after the complete source pass; the file-by-file READ log above records why remaining provider-specific, authentication, lifecycle, storage, migration and presentation code was retained.

The cleanup also fixes IMAP invalid-password classification and OC Path ordinal/positional Markdown writes. Both regressions failed on Testbox before the repairs, then passed afterward. OC Path now uses the existing read resolver and maintains source positions across rendering/insertion for subsequent writes. This adds no persisted AST fields or schema.

Reuse existing Plugin SDK coercion, queue, concurrency, result and error
owners, remove redundant forwarding APIs and unreachable fal network
policy branches, and consolidate CLI speech and Bonjour lifecycle code.
Preserve registered tool text/schemas, requests, manifests and storage.

Fix IMAP malformed passwords being treated as unresolved secret references.
Fix OC Path Markdown writes rejecting ordinal/positional item addresses and
selecting the wrong duplicate key; keep source positions for later writes.

Validation: all 29 touched-plugin batches pass on Blacksmith Testbox
(281 executed files, 3934 tests passed, 2 skipped), both regressions failed
before the fixes, and the full build passes. Required assertion-baseline
shrink and remaining API/boundary/descriptor gates are tracked for closeout.
Independent Codex review has no accepted actionable findings.
@clawsweeper

clawsweeper Bot commented Sep 28, 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.

@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. labels Sep 28, 2026
@clawsweeper clawsweeper Bot added merge-risk: 🚨 availability 🚨 May cause crashes, hangs, restart loops, stalls, or process outages. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Sep 28, 2026
@clawsweeper clawsweeper Bot added status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed merge-risk: 🚨 availability 🚨 May cause crashes, hangs, restart loops, stalls, or process outages. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Sep 29, 2026
@steipete
steipete merged commit eb212b7 into main Sep 29, 2026
177 checks passed
@steipete
steipete deleted the deslop/l144-tool-plugins branch September 29, 2026 00:31
steipete added a commit that referenced this pull request Sep 29, 2026
#160552 moved the secret-ref resolver onto openclaw/plugin-sdk/secret-file-runtime
but left @openclaw/fs-safe declared in the extension manifest, so the
extension-runtime-dependencies contract test fails on main whenever a PR's
changed-files plan includes the plugin contracts shard.
steipete added a commit that referenced this pull request Sep 29, 2026
#160552 removed extensions/diffs/runtime-api.ts and extensions/lobster/runtime-api.ts
but left both plugin ids in the unguarded runtime-api inventory, so the plugin SDK
runtime-api guardrails contract test fails on main whenever a PR's changed-files
plan includes the plugin contracts shard.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 29, 2026
…0552)

* refactor(plugins): deslop tool, search and media plugins

Reuse existing Plugin SDK coercion, queue, concurrency, result and error
owners, remove redundant forwarding APIs and unreachable fal network
policy branches, and consolidate CLI speech and Bonjour lifecycle code.
Preserve registered tool text/schemas, requests, manifests and storage.

Fix IMAP malformed passwords being treated as unresolved secret references.
Fix OC Path Markdown writes rejecting ordinal/positional item addresses and
selecting the wrong duplicate key; keep source positions for later writes.

Validation: all 29 touched-plugin batches pass on Blacksmith Testbox
(281 executed files, 3934 tests passed, 2 skipped), both regressions failed
before the fixes, and the full build passes. Required assertion-baseline
shrink and remaining API/boundary/descriptor gates are tracked for closeout.
Independent Codex review has no accepted actionable findings.

* chore(plugins): shrink assertion allowances after deslop

* refactor(oc-path): keep quoted segment guard internal

* fix(openshell): keep resolver-side managed remote path guard
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 29, 2026
openclaw#160552 moved the secret-ref resolver onto openclaw/plugin-sdk/secret-file-runtime
but left @openclaw/fs-safe declared in the extension manifest, so the
extension-runtime-dependencies contract test fails on main whenever a PR's
changed-files plan includes the plugin contracts shard.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 29, 2026
openclaw#160552 removed extensions/diffs/runtime-api.ts and extensions/lobster/runtime-api.ts
but left both plugin ids in the unguarded runtime-api inventory, so the plugin SDK
runtime-api guardrails contract test fails on main whenever a PR's changed-files
plan includes the plugin contracts shard.
steipete added a commit that referenced this pull request Sep 29, 2026
* refactor(plugins): deslop feature plugins fourth pass

Consolidate policy registration, audit context, request projections and
private helpers through their existing plugin and SDK owners. Remove dead
forwarders, exports and state without changing registered descriptors or
persisted contracts.

Retain legacy empty-automation cleanup and cover its SQLite update path.
Verified scoped plugin suites, import boundaries, byte-identical registered
descriptors, changed checks, build and independent review on Testbox.

Related: #160362, #160552

* fix(workboard): preserve session states and refresh generated assets
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 30, 2026
* refactor(plugins): deslop feature plugins fourth pass

Consolidate policy registration, audit context, request projections and
private helpers through their existing plugin and SDK owners. Remove dead
forwarders, exports and state without changing registered descriptors or
persisted contracts.

Retain legacy empty-automation cleanup and cover its SQLite update path.
Verified scoped plugin suites, import boundaries, byte-identical registered
descriptors, changed checks, build and independent review on Testbox.

Related: openclaw#160362, openclaw#160552

* fix(workboard): preserve session states and refresh generated assets
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant