Skip to content

fix(release): repair 2026.9.6 plugin shard and FaceTime manifest validation - #155892

Merged
steipete merged 3 commits into
mainfrom
fix/release-2026-9-6-repairs-2
Sep 22, 2026
Merged

steipete merged 3 commits into
mainfrom
fix/release-2026-9-6-repairs-2

Conversation

@steipete

Copy link
Copy Markdown
Contributor

Problem

Full Release Validation run 35760444831 for 2026.9.6 fails two release-only lanes that regular PR CI never runs:

  1. checks-node-agentic-plugins (Plugin Prerelease, test/vitest/vitest.plugins.config.ts): 12 files / 40 tests in src/plugins/ fail with symptoms such as Plugin fixture-speech capabilityCatalogEntry failed: Unexpected token 'export', expected { values: [ undefined, 'javascript' ] } to match object { values: [ 'typescript', ... ] }, and expected undefined to be 'overloaded', alongside Node warnings Failed to load the ES module: .../capability-catalog.js.
  2. extensions shard 8: extensions/facetime/tests/package-manifest.test.ts fails once the release version controller bumps the package to 2026.9.6 (minHostVersion expected >=2026.9.6, received >=2026.9.4).

Root causes

Plugins shard. #153508 added a --import tsx/esm execArgv preload to every Node Vitest fork worker (test/vitest/vitest.shared.config.ts). The src/plugins suites exercise the plugin loader's own native require()/import() of .ts/.js fixtures (TS/JS peers, CJS/ESM interop, built capability catalogs, public surfaces). With the tsx hooks installed in the worker, Node's own module semantics under test change: a .ts peer in a commonjs package requires as an empty namespace, ESM .js catalogs in fixture packages fall through the CJS path, and loader ownership assertions fail. The shard is RELEASE_ONLY_PLUGIN_SHARDS, so the breakage surfaced only in Full Release Validation. A standalone probe (createRequire(...)("./native.cjs") requiring peer.ts + peer.js) returns ["typescript","javascript"] on plain Node 24 and 26 and [null,"javascript"] with --import scripts/tsx.mjs.

FaceTime manifest. #155818 derived every host-contract field from package.json#version, but scripts/sync-plugin-versions.ts deliberately leaves openclaw.install.minHostVersion alone ("a compatibility floor, not release alignment metadata") while rewriting peerDependencies.openclaw, compat.pluginApi, and build.openclawVersion. The derived expectation therefore breaks on every release bump.

Solution

  • test/vitest/vitest.scoped-config.ts: accept an execArgv override.
  • test/vitest/vitest.plugins.config.ts: split the shard into two inline projects (same pattern as vitest.gateway-server.config.ts): plugins keeps the shared preload (its suites load bundled plugins from source and need tsx's .js to .ts SDK resolution), and plugins-native-loader runs the eight loader-semantics suites (plugin-module-generation*, capability-provider-runtime.generation, bundled-plugin-metadata.public-surfaces, manifest-registry, public-surface-loader, plugin-runtime-artifact-resolution, stage-bundled-plugin-runtime) with execArgv: []. The root config keeps the complete inventory so planner discovery and --project routing are unchanged.
  • extensions/facetime/tests/package-manifest.test.ts: expect the literal >=2026.9.4 floor for install.minHostVersion; the controller-synced fields stay derived from the package version.

Impact

Release-only validation lanes match what the runtime does in production for the loader suites (no tsx hooks in a Gateway process). No product code changes. Regular CI shards are unaffected; only the eight native-loader suites drop the preload.

Evidence

  • Baseline, exact job command (pnpm test -- test/vitest/vitest.plugins.config.ts --, Node 24.21.0, OPENCLAW_VITEST_MAX_WORKERS=2): 13 failed files / 41 failed tests (CI's 12 plus plugin-graceful-init-failure), matching FRV run 35760444831 job checks-node-agentic-plugins (also red in runs 35743778013 and 35761282770).
  • Planner/routing owners with the split config: test/scripts/ci-node-test-plan.test.ts, test-projects.test.ts, test-projects-routing.test.ts, plugin-prerelease-test-plan.test.ts: 1811/1811 pass.
  • Fixed, same command and Node: 5 failed files / 10 failed tests, 375 passed files / 6101 passed tests. All eight loader-semantics files are green. Dropping the preload for the whole shard instead (probe run) fixes the same eight files but breaks 11 other files on Cannot find module '.../src/agents/defaults.js' imported from .../src/plugin-sdk/provider-model-metadata.ts, which is why the shard is split rather than de-preloaded.
  • Remaining red files are independent of the preload (identical failures with and without it, and with providers.runtime-core.ts, provider-hook-runtime-core.ts, plugin-instance*.ts, host-hook-state.ts reverted to their pre-improve(plugins): skip activation planning for retained provider owners #155711/fix(models): reduce repeated provider lookup overhead #155250/perf(plugins): reduce callback scope overhead #154625/fix: keep plugin queues bound to their selected session #155714 versions): provider-runtime.test.ts (6: resolveProviderPluginsForHooks/classifyProviderFailoverSignalWithPlugin no longer read the withPluginRuntimeRegistryScope registry), native-session-catalog-registration.test.ts (1: abort surfaces PluginInstanceUnavailableError instead of the caller's retirement error), plugin-instance-invocation.test.ts (1), provider-public-artifacts.test.ts (1: listener count after bundled policy load), plugin-graceful-init-failure.test.ts (1: Maximum call stack size exceeded, local only). These are product/test contract drift from the plugin runtime refactors and need their owners; they are called out in the landing report.
  • extensions/facetime/tests/package-manifest.test.ts: 2/2 pass at 2026.9.4 and 2/2 pass after a local pnpm release:prepare -- --version 2026.9.6 --write (bump reverted, not committed).
  • OPENCLAW_TESTBOX=1 pnpm check:changed: in progress at PR creation; result recorded in the landing report.

@openclaw-barnacle openclaw-barnacle Bot added plugin: facetime FaceTime plugin size: S maintainer Maintainer-authored PR labels Sep 22, 2026
@steipete steipete self-assigned this Sep 22, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Sep 22, 2026
@clawsweeper

clawsweeper Bot commented Sep 22, 2026

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed September 22, 2026, 2:46 PM ET / 18:46 UTC.

ClawSweeper review

What this changes

Separates native plugin-loader tests from workers using the TypeScript preload and keeps FaceTime’s minimum host-version expectation fixed across release bumps.

Regression provenance

Possible regression — suspected (reviewed change). No predecessor PR is attributed.

Merge readiness

⛔ Blocked before merge - 3 items remain

Keep open: the release-validation repair remains useful, but direct project selection silently omits the native-loader tests. The FaceTime correction matches the release controller.

Priority: P2
Reviewed head: 8e531f52d31878be2624ae286ca560d155b8608a

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The focused repair has useful comparative validation, but a source-proven test-selection regression remains.
Proof confidence 🌊 off-meta tidepool Not applicable: The maintainer test-infrastructure change is exempt from external-contributor runtime proof. The captured body reports the actual plugin-shard command and release-bump manifest checks, but direct project-filter coverage remains unproven. No stored-data contract changes.
Patch quality 🦐 gold shrimp (3/6) 1 actionable review finding remain.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The maintainer test-infrastructure change is exempt from external-contributor runtime proof. The captured body reports the actual plugin-shard command and release-bump manifest checks, but direct project-filter coverage remains unproven. No stored-data contract changes.
Evidence reviewed 8 items Pinned introduced changes: Reviewed the complete introduced delta from the pinned base to the original PR head. It changes test configuration and one manifest assertion, without changing production permissions, dependencies, package metadata, or stored data.
Direct project-selection regression: The ordinary leaf retains the name plugins but excludes all eight native-loader files; the other leaf is named plugins-native-loader. Directly loading this config with --project plugins therefore selects only the ordinary leaf. The root-matrix invocation has container ancestry and is a distinct, unaffected selection path.
Dependency-backed project filtering: Verified the upstream repository and v5.0.0 tag identity. resolveProjectEntries starts direct configurations with empty ancestors; matchesEntryFilter matches the leaf name or recorded ancestors. The patch directly imports vitest/config, making this dependency contract relevant. OpenClaw’s checked-in Vitest patch changes name-prefix propagation but preserves this filtering behavior.
Findings 1 actionable finding [P2] Preserve native-loader coverage with direct project selection
Security None None.

How this fits together

Release validation runs plugin tests through scoped Vitest configurations. These configurations select test files and worker loading behavior, while the FaceTime manifest test checks package compatibility metadata.

flowchart TD
  A[Release validation or focused test command] --> B[Plugin test configuration]
  B --> C[Ordinary plugin suites]
  B --> D[Native loader suites]
  C --> E[Workers with TypeScript preload]
  D --> F[Workers without preload]
  G[Release package metadata] --> H[FaceTime compatibility checks]
Loading

Before merge

  • Preserve native-loader coverage with direct project selection (P2) - Running node scripts/run-vitest.mjs run --config test/vitest/vitest.plugins.config.ts --project plugins now selects only the ordinary leaf, which excludes all eight native-loader files. Vitest starts a directly loaded config with no container ancestors and matches project names exactly, so plugins-native-loader is dropped; targeting one of those files can then succeed with no tests because passWithNoTests is true. Root-matrix selection still works, which explains why inventory checks do not catch this. Use the file-backed container pattern already present in vitest.gateway-server.config.ts and cover the direct selector.
  • Resolve merge risk (P1) - Direct invocation of the plugins config with --project plugins can report success without running any of the eight native-loader suites.
  • Complete next step (P2) - Restore direct --project plugins coverage for both worker groups and verify that native-loader files are selected exactly once without the preload.

Findings

  • [P2] Preserve native-loader coverage with direct project selection — test/vitest/vitest.plugins.config.ts:51-54
Agent review details

Security

None.

PR surface

Tests +49. Total +49 across 3 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 3 53 4 +49
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 3 53 4 +49

Review metrics

None.

Merge-risk options

Maintainer options:

  1. Preserve direct project selection (recommended)
    Use a file-backed plugins container and verify that direct and root project selection each retain both worker groups.
Copy recommended automerge instruction
@clawsweeper automerge

Special instructions:
Preserve --project plugins for direct use of the plugins config by following the existing Gateway file-backed container pattern; add focused resolved-project coverage proving all eight native-loader suites remain selected exactly once with execArgv empty.

Technical review

Best possible solution:

Preserve plugins as a selector for both worker groups using the existing file-backed container pattern, while retaining the corrected FaceTime compatibility-floor assertion.

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

Yes, from source: directly selecting the plugins config with --project plugins excludes the differently named native-loader leaf. This was traced through Vitest’s project resolver but not executed.

Is this the best way to solve the issue?

The split and fixed FaceTime floor are appropriate, but the split needs the file-backed container already used by Gateway tests to preserve direct project selection.

Full review comments:

  • [P2] Preserve native-loader coverage with direct project selection — test/vitest/vitest.plugins.config.ts:51-54
    Running node scripts/run-vitest.mjs run --config test/vitest/vitest.plugins.config.ts --project plugins now selects only the ordinary leaf, which excludes all eight native-loader files. Vitest starts a directly loaded config with no container ancestors and matches project names exactly, so plugins-native-loader is dropped; targeting one of those files can then succeed with no tests because passWithNoTests is true. Root-matrix selection still works, which explains why inventory checks do not catch this. Use the file-backed container pattern already present in vitest.gateway-server.config.ts and cover the direct selector.
    Confidence: 0.98

Overall correctness: patch is incorrect
Overall confidence: 0.97

AGENTS.md: found and applied where relevant.

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

Labels

Label changes:

  • add P2: This is a bounded release-test infrastructure repair with no demonstrated urgent user-facing outage.
  • add merge-risk: 🚨 automation: The introduced project split silently drops native-loader coverage under direct --project plugins selection.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🌊 off-meta tidepool and patch quality is 🦐 gold shrimp.
  • add status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action. Not applicable: The maintainer test-infrastructure change is exempt from external-contributor runtime proof. The captured body reports the actual plugin-shard command and release-bump manifest checks, but direct project-filter coverage remains unproven. No stored-data contract changes.

Label justifications:

  • P2: This is a bounded release-test infrastructure repair with no demonstrated urgent user-facing outage.
  • merge-risk: 🚨 automation: The introduced project split silently drops native-loader coverage under direct --project plugins selection.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🌊 off-meta tidepool and patch quality is 🦐 gold shrimp.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action. Not applicable: The maintainer test-infrastructure change is exempt from external-contributor runtime proof. The captured body reports the actual plugin-shard command and release-bump manifest checks, but direct project-filter coverage remains unproven. No stored-data contract changes.

Evidence

Acceptance criteria:

  • [P1] node scripts/run-vitest.mjs run --config test/vitest/vitest.plugins.config.ts --project plugins src/plugins/plugin-module-generation.test.ts --maxWorkers=1.
  • [P1] pnpm test test/vitest-projects-config.test.ts --maxWorkers=1.
  • [P1] pnpm test test/scripts/test-projects-routing.test.ts --maxWorkers=1.
  • [P1] pnpm test test/scripts/plugin-prerelease-test-plan.test.ts --maxWorkers=1.
  • [P1] git diff --check.

What I checked:

  • Pinned introduced changes: Reviewed the complete introduced delta from the pinned base to the original PR head. It changes test configuration and one manifest assertion, without changing production permissions, dependencies, package metadata, or stored data. (test/vitest/vitest.plugins.config.ts:40, 8e531f52d318)
  • Direct project-selection regression: The ordinary leaf retains the name plugins but excludes all eight native-loader files; the other leaf is named plugins-native-loader. Directly loading this config with --project plugins therefore selects only the ordinary leaf. The root-matrix invocation has container ancestry and is a distinct, unaffected selection path. (test/vitest/vitest.plugins.config.ts:51, 8e531f52d318)
  • Dependency-backed project filtering: Verified the upstream repository and v5.0.0 tag identity. resolveProjectEntries starts direct configurations with empty ancestors; matchesEntryFilter matches the leaf name or recorded ancestors. The patch directly imports vitest/config, making this dependency contract relevant. OpenClaw’s checked-in Vitest patch changes name-prefix propagation but preserves this filtering behavior. (packages/vitest/src/node/projects/resolveProjects.ts:1132, f441c6fab25e)
  • Existing selection-preserving pattern: The Gateway server configuration uses a file-backed container specifically to preserve direct --project selection across its child projects. The same bounded pattern can preserve the existing plugins selector. (test/vitest/vitest.gateway-server.config.ts:42, 8e531f52d318)
  • FaceTime compatibility-floor contract: The version controller updates package versions, peer dependency ranges, plugin API compatibility, and build version while explicitly preserving minHostVersion. The fixed >=2026.9.4 assertion agrees with the actual FaceTime manifest and does not alter the install contract. (scripts/sync-plugin-versions.ts:164, 8e531f52d318)
  • Still necessary on fetched main: Fetched main retains the single preloaded plugins project and the release-derived FaceTime minimum-version expectation. The latest-release plugin config also lacks this split. The merged earlier release repair, fix(release): repair 2026.9.6 validation failures #155818, introduced the FaceTime expectation being corrected here; it does not supersede this work. (test/vitest/vitest.plugins.config.ts:5, 065eb1f58f13)

Likely related people:

  • unknown: The claimed source-line change could not be verified from bounded local history. (role: source history unknown; confidence: low)

Rank-up moves

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

  • Preserve direct --project plugins selection and verify both worker groups through Vitest’s resolved project inventory.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@steipete
steipete merged commit c8a045b into main Sep 22, 2026
271 of 273 checks passed
@steipete
steipete deleted the fix/release-2026-9-6-repairs-2 branch September 22, 2026 19:22
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

steipete added a commit that referenced this pull request Sep 22, 2026
…dation (#155892)

## Problem

Full Release Validation run 35760444831 for 2026.9.6 fails two release-only lanes that regular PR CI never runs:

1. `checks-node-agentic-plugins` (Plugin Prerelease, `test/vitest/vitest.plugins.config.ts`): 12 files / 40 tests in `src/plugins/` fail with symptoms such as `Plugin fixture-speech capabilityCatalogEntry failed: Unexpected token 'export'`, `expected { values: [ undefined, 'javascript' ] } to match object { values: [ 'typescript', ... ] }`, and `expected undefined to be 'overloaded'`, alongside Node warnings `Failed to load the ES module: .../capability-catalog.js`.
2. `extensions shard 8`: `extensions/facetime/tests/package-manifest.test.ts` fails once the release version controller bumps the package to 2026.9.6 (`minHostVersion` expected `>=2026.9.6`, received `>=2026.9.4`).

## Root causes

**Plugins shard.** #153508 added a `--import tsx/esm` `execArgv` preload to every Node Vitest fork worker (`test/vitest/vitest.shared.config.ts`). The `src/plugins` suites exercise the plugin loader's own native `require()`/`import()` of `.ts`/`.js` fixtures (TS/JS peers, CJS/ESM interop, built capability catalogs, public surfaces). With the tsx hooks installed in the worker, Node's own module semantics under test change: a `.ts` peer in a `commonjs` package requires as an empty namespace, ESM `.js` catalogs in fixture packages fall through the CJS path, and loader ownership assertions fail. The shard is `RELEASE_ONLY_PLUGIN_SHARDS`, so the breakage surfaced only in Full Release Validation. A standalone probe (`createRequire(...)("./native.cjs")` requiring `peer.ts` + `peer.js`) returns `["typescript","javascript"]` on plain Node 24 and 26 and `[null,"javascript"]` with `--import scripts/tsx.mjs`.

**FaceTime manifest.** #155818 derived every host-contract field from `package.json#version`, but `scripts/sync-plugin-versions.ts` deliberately leaves `openclaw.install.minHostVersion` alone ("a compatibility floor, not release alignment metadata") while rewriting `peerDependencies.openclaw`, `compat.pluginApi`, and `build.openclawVersion`. The derived expectation therefore breaks on every release bump.

## Solution

- `test/vitest/vitest.scoped-config.ts`: accept an `execArgv` override.
- `test/vitest/vitest.plugins.config.ts`: split the shard into two inline projects (same pattern as `vitest.gateway-server.config.ts`): `plugins` keeps the shared preload (its suites load bundled plugins from source and need tsx's `.js` to `.ts` SDK resolution), and `plugins-native-loader` runs the eight loader-semantics suites (`plugin-module-generation*`, `capability-provider-runtime.generation`, `bundled-plugin-metadata.public-surfaces`, `manifest-registry`, `public-surface-loader`, `plugin-runtime-artifact-resolution`, `stage-bundled-plugin-runtime`) with `execArgv: []`. The root config keeps the complete inventory so planner discovery and `--project` routing are unchanged.
- `extensions/facetime/tests/package-manifest.test.ts`: expect the literal `>=2026.9.4` floor for `install.minHostVersion`; the controller-synced fields stay derived from the package version.

## Impact

Release-only validation lanes match what the runtime does in production for the loader suites (no tsx hooks in a Gateway process). No product code changes. Regular CI shards are unaffected; only the eight native-loader suites drop the preload.

## Evidence

- Baseline, exact job command (`pnpm test -- test/vitest/vitest.plugins.config.ts --`, Node 24.21.0, `OPENCLAW_VITEST_MAX_WORKERS=2`): 13 failed files / 41 failed tests (CI's 12 plus `plugin-graceful-init-failure`), matching FRV run 35760444831 job `checks-node-agentic-plugins` (also red in runs 35743778013 and 35761282770).
- Planner/routing owners with the split config: `test/scripts/ci-node-test-plan.test.ts`, `test-projects.test.ts`, `test-projects-routing.test.ts`, `plugin-prerelease-test-plan.test.ts`: 1811/1811 pass.
- Fixed, same command and Node: 5 failed files / 10 failed tests, 375 passed files / 6101 passed tests. All eight loader-semantics files are green. Dropping the preload for the whole shard instead (probe run) fixes the same eight files but breaks 11 other files on `Cannot find module '.../src/agents/defaults.js' imported from .../src/plugin-sdk/provider-model-metadata.ts`, which is why the shard is split rather than de-preloaded.
- Remaining red files are independent of the preload (identical failures with and without it, and with `providers.runtime-core.ts`, `provider-hook-runtime-core.ts`, `plugin-instance*.ts`, `host-hook-state.ts` reverted to their pre-#155711/#155250/#154625/#155714 versions): `provider-runtime.test.ts` (6: `resolveProviderPluginsForHooks`/`classifyProviderFailoverSignalWithPlugin` no longer read the `withPluginRuntimeRegistryScope` registry), `native-session-catalog-registration.test.ts` (1: abort surfaces `PluginInstanceUnavailableError` instead of the caller's retirement error), `plugin-instance-invocation.test.ts` (1), `provider-public-artifacts.test.ts` (1: listener count after bundled policy load), `plugin-graceful-init-failure.test.ts` (1: `Maximum call stack size exceeded`, local only). These are product/test contract drift from the plugin runtime refactors and need their owners; they are called out in the landing report.
- `extensions/facetime/tests/package-manifest.test.ts`: 2/2 pass at 2026.9.4 and 2/2 pass after a local `pnpm release:prepare -- --version 2026.9.6 --write` (bump reverted, not committed).
- `OPENCLAW_TESTBOX=1 pnpm check:changed`: in progress at PR creation; result recorded in the landing report.

Co-authored-by: Peter Steinberger <[email protected]>
steipete added a commit that referenced this pull request Sep 22, 2026
Re-cut on main 814a7e7 plus the pending control UI locale refresh
(#155912) and the plugin shard / FaceTime manifest repairs (#155892).
steipete added a commit that referenced this pull request Sep 22, 2026
…dule graphs (#155925)

## Summary

Repairs the four residual red files in the release-only `checks-node-agentic-plugins` lane for 2026.9.6 (after #155892 split the native-loader project).

**Product regression (7 tests in 3 files):** #153508 turned `PluginRuntimeExecutionFrame` (`src/plugins/runtime/execution-frame.ts`) into a plain class while the plugin execution frame store stayed a process-wide `resolveGlobalSingleton`. Any second module instance of that file (a reloaded test graph, a duplicated chunk) fails the `instanceof` narrowing in `getPluginRuntimeExecutionFrame` and silently drops the Gateway request scope: `withPluginRuntimeRegistryScope` registries stopped reaching `resolveProviderPluginsForHooks` / `classifyProviderFailoverSignalWithPlugin`, and the reload-identity contract in `plugin-instance-invocation.test.ts` (added with the singleton in #146219) broke. This restores the shared constructor next to the shared store.

**Test fixture (1 test):** the `provider-public-artifacts` bundled scenario loads an ESM `provider-policy-api.js` from a fixture package with no module type through the bundled owners' native `require()` path. Under the tsx/esm worker preload the ambiguous file is compiled as CommonJS (`Unexpected token 'export'`), which the test's `finally` assertion masked as a listener-count mismatch. Shipped bundled artifacts (`dist/extensions/*`) are ESM under a `"type": "module"` package, so the fixture now declares that.

Files: `src/plugins/provider-runtime.test.ts` (6), `src/plugins/plugin-instance-invocation.test.ts` (1), `src/plugins/native-session-catalog-registration.test.ts` (green in the fixed run), `src/plugins/provider-public-artifacts.test.ts` (1).

`plugin-graceful-init-failure.test.ts` ("Maximum call stack size exceeded") reproduces locally with and without the preload and is a host stack-size artifact, not part of the CI residual; unchanged here.

## Validation

- Baseline on main tip (Node 24, `scripts/run-vitest.mjs run --config test/vitest/vitest.plugins.config.ts <files>`): 8 failed across the 4 files (plus the local-only stack-limit case).
- After the fix: the 4 files pass (`provider-runtime` 6/6, invocation 1/1, catalog 1/1, artifacts 33/33; 148/148 tests).
- Full `pnpm test -- test/vitest/vitest.plugins.config.ts --` shard on Node 24, run as four file chunks under the local 10-minute command cap: 105 + 88 + 94 + 91 test files green, 6109 tests passed; the only failure is the host-local `plugin-graceful-init-failure` stack-limit case (fails with and without the preload, not in the CI residual).
- `OPENCLAW_TESTBOX=1 pnpm check:changed`: all lanes pass except the dead-export scan, which flags `scripts/lib/tsgo-core-test-shards.mts: TSGO_CORE_TEST_MAX_ROOTS`; that export is untouched by this PR and was already made internal on main by `1619aff4781` after this branch's base.
- Hosted CI on the exact head `cea3da31abcb`: 143 checks passed, 0 pending.

Co-authored-by: Peter Steinberger <[email protected]>
steipete added a commit that referenced this pull request Sep 22, 2026
)

## Summary

Full Release Validation 35775979903 (CI child 35776854264, candidate `release/2026.9.6` = main `814a7e752afc` + locale refresh + #155892) failed `subagent-registry.persistence.test.ts`, `subagent-spawn.authority.test.ts`, `chat.abort-errors.test.ts` and `chat.abort-incarnation.test.ts` in `settleSubagentRegistryPersistenceWork` with `residual registry roots: tasks:delivery (2|4|6): expected N to be +0`. All were green in the two previous validation runs.

Bisected to #151917 (`68b724b355e`, move terminal notification writes off the Gateway thread): `subagent-registry.persistence.test.ts` passes 30/30 at `68b724b355e^` and fails at `68b724b355e` with the exact CI signature; on current main it fails 5/5 locally. The `tasks:delivery` roots are not leaked: with a 20 s fence the same test passes (3.3 s), i.e. uncaptured deliveries settle 1–2 s after the test body, while the shared helper used `vi.waitFor`'s 1 s default. #155910 and #155888 already fixed individual fixtures by capturing deliveries; this widens the shared fence so the remaining callers (persistence, timing, resume, task-replacement, chat.abort-*) stop racing it. Test contract change only; no product change.

The related `build-artifacts` failure (`sqlite-sessions-transcripts-flip-proof` rejecting the delete-drain `stopReason`) was fixed on main in parallel by `8ba18cf19ad`; this branch merged that and carries no change of its own for it.

## Change

- `src/agents/subagents/registry/subagent-registry.persistence.test-support.ts`: `vi.waitFor(..., { timeout: 10_000 })` in `settleSubagentRegistryPersistenceWork`.

## Proof

- The four affected files green in one local vitest run with the change (`Tests 26 passed`, `Tests 36 passed`).
- `oxfmt --check` / `oxlint` clean on the changed file; exact-head hosted gates via `scripts/pr`.
steipete added a commit that referenced this pull request Sep 23, 2026
…dule graphs (#155925)

## Summary

Repairs the four residual red files in the release-only `checks-node-agentic-plugins` lane for 2026.9.6 (after #155892 split the native-loader project).

**Product regression (7 tests in 3 files):** #153508 turned `PluginRuntimeExecutionFrame` (`src/plugins/runtime/execution-frame.ts`) into a plain class while the plugin execution frame store stayed a process-wide `resolveGlobalSingleton`. Any second module instance of that file (a reloaded test graph, a duplicated chunk) fails the `instanceof` narrowing in `getPluginRuntimeExecutionFrame` and silently drops the Gateway request scope: `withPluginRuntimeRegistryScope` registries stopped reaching `resolveProviderPluginsForHooks` / `classifyProviderFailoverSignalWithPlugin`, and the reload-identity contract in `plugin-instance-invocation.test.ts` (added with the singleton in #146219) broke. This restores the shared constructor next to the shared store.

**Test fixture (1 test):** the `provider-public-artifacts` bundled scenario loads an ESM `provider-policy-api.js` from a fixture package with no module type through the bundled owners' native `require()` path. Under the tsx/esm worker preload the ambiguous file is compiled as CommonJS (`Unexpected token 'export'`), which the test's `finally` assertion masked as a listener-count mismatch. Shipped bundled artifacts (`dist/extensions/*`) are ESM under a `"type": "module"` package, so the fixture now declares that.

Files: `src/plugins/provider-runtime.test.ts` (6), `src/plugins/plugin-instance-invocation.test.ts` (1), `src/plugins/native-session-catalog-registration.test.ts` (green in the fixed run), `src/plugins/provider-public-artifacts.test.ts` (1).

`plugin-graceful-init-failure.test.ts` ("Maximum call stack size exceeded") reproduces locally with and without the preload and is a host stack-size artifact, not part of the CI residual; unchanged here.

## Validation

- Baseline on main tip (Node 24, `scripts/run-vitest.mjs run --config test/vitest/vitest.plugins.config.ts <files>`): 8 failed across the 4 files (plus the local-only stack-limit case).
- After the fix: the 4 files pass (`provider-runtime` 6/6, invocation 1/1, catalog 1/1, artifacts 33/33; 148/148 tests).
- Full `pnpm test -- test/vitest/vitest.plugins.config.ts --` shard on Node 24, run as four file chunks under the local 10-minute command cap: 105 + 88 + 94 + 91 test files green, 6109 tests passed; the only failure is the host-local `plugin-graceful-init-failure` stack-limit case (fails with and without the preload, not in the CI residual).
- `OPENCLAW_TESTBOX=1 pnpm check:changed`: all lanes pass except the dead-export scan, which flags `scripts/lib/tsgo-core-test-shards.mts: TSGO_CORE_TEST_MAX_ROOTS`; that export is untouched by this PR and was already made internal on main by `1619aff4781` after this branch's base.
- Hosted CI on the exact head `cea3da31abcb`: 143 checks passed, 0 pending.

Co-authored-by: Peter Steinberger <[email protected]>
steipete added a commit that referenced this pull request Sep 23, 2026
)

## Summary

Full Release Validation 35775979903 (CI child 35776854264, candidate `release/2026.9.6` = main `814a7e752afc` + locale refresh + #155892) failed `subagent-registry.persistence.test.ts`, `subagent-spawn.authority.test.ts`, `chat.abort-errors.test.ts` and `chat.abort-incarnation.test.ts` in `settleSubagentRegistryPersistenceWork` with `residual registry roots: tasks:delivery (2|4|6): expected N to be +0`. All were green in the two previous validation runs.

Bisected to #151917 (`68b724b355e`, move terminal notification writes off the Gateway thread): `subagent-registry.persistence.test.ts` passes 30/30 at `68b724b355e^` and fails at `68b724b355e` with the exact CI signature; on current main it fails 5/5 locally. The `tasks:delivery` roots are not leaked: with a 20 s fence the same test passes (3.3 s), i.e. uncaptured deliveries settle 1–2 s after the test body, while the shared helper used `vi.waitFor`'s 1 s default. #155910 and #155888 already fixed individual fixtures by capturing deliveries; this widens the shared fence so the remaining callers (persistence, timing, resume, task-replacement, chat.abort-*) stop racing it. Test contract change only; no product change.

The related `build-artifacts` failure (`sqlite-sessions-transcripts-flip-proof` rejecting the delete-drain `stopReason`) was fixed on main in parallel by `8ba18cf19ad`; this branch merged that and carries no change of its own for it.

## Change

- `src/agents/subagents/registry/subagent-registry.persistence.test-support.ts`: `vi.waitFor(..., { timeout: 10_000 })` in `settleSubagentRegistryPersistenceWork`.

## Proof

- The four affected files green in one local vitest run with the change (`Tests 26 passed`, `Tests 36 passed`).
- `oxfmt --check` / `oxlint` clean on the changed file; exact-head hosted gates via `scripts/pr`.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 23, 2026
…dation (openclaw#155892)

## Problem

Full Release Validation run 35760444831 for 2026.9.6 fails two release-only lanes that regular PR CI never runs:

1. `checks-node-agentic-plugins` (Plugin Prerelease, `test/vitest/vitest.plugins.config.ts`): 12 files / 40 tests in `src/plugins/` fail with symptoms such as `Plugin fixture-speech capabilityCatalogEntry failed: Unexpected token 'export'`, `expected { values: [ undefined, 'javascript' ] } to match object { values: [ 'typescript', ... ] }`, and `expected undefined to be 'overloaded'`, alongside Node warnings `Failed to load the ES module: .../capability-catalog.js`.
2. `extensions shard 8`: `extensions/facetime/tests/package-manifest.test.ts` fails once the release version controller bumps the package to 2026.9.6 (`minHostVersion` expected `>=2026.9.6`, received `>=2026.9.4`).

## Root causes

**Plugins shard.** openclaw#153508 added a `--import tsx/esm` `execArgv` preload to every Node Vitest fork worker (`test/vitest/vitest.shared.config.ts`). The `src/plugins` suites exercise the plugin loader's own native `require()`/`import()` of `.ts`/`.js` fixtures (TS/JS peers, CJS/ESM interop, built capability catalogs, public surfaces). With the tsx hooks installed in the worker, Node's own module semantics under test change: a `.ts` peer in a `commonjs` package requires as an empty namespace, ESM `.js` catalogs in fixture packages fall through the CJS path, and loader ownership assertions fail. The shard is `RELEASE_ONLY_PLUGIN_SHARDS`, so the breakage surfaced only in Full Release Validation. A standalone probe (`createRequire(...)("./native.cjs")` requiring `peer.ts` + `peer.js`) returns `["typescript","javascript"]` on plain Node 24 and 26 and `[null,"javascript"]` with `--import scripts/tsx.mjs`.

**FaceTime manifest.** openclaw#155818 derived every host-contract field from `package.json#version`, but `scripts/sync-plugin-versions.ts` deliberately leaves `openclaw.install.minHostVersion` alone ("a compatibility floor, not release alignment metadata") while rewriting `peerDependencies.openclaw`, `compat.pluginApi`, and `build.openclawVersion`. The derived expectation therefore breaks on every release bump.

## Solution

- `test/vitest/vitest.scoped-config.ts`: accept an `execArgv` override.
- `test/vitest/vitest.plugins.config.ts`: split the shard into two inline projects (same pattern as `vitest.gateway-server.config.ts`): `plugins` keeps the shared preload (its suites load bundled plugins from source and need tsx's `.js` to `.ts` SDK resolution), and `plugins-native-loader` runs the eight loader-semantics suites (`plugin-module-generation*`, `capability-provider-runtime.generation`, `bundled-plugin-metadata.public-surfaces`, `manifest-registry`, `public-surface-loader`, `plugin-runtime-artifact-resolution`, `stage-bundled-plugin-runtime`) with `execArgv: []`. The root config keeps the complete inventory so planner discovery and `--project` routing are unchanged.
- `extensions/facetime/tests/package-manifest.test.ts`: expect the literal `>=2026.9.4` floor for `install.minHostVersion`; the controller-synced fields stay derived from the package version.

## Impact

Release-only validation lanes match what the runtime does in production for the loader suites (no tsx hooks in a Gateway process). No product code changes. Regular CI shards are unaffected; only the eight native-loader suites drop the preload.

## Evidence

- Baseline, exact job command (`pnpm test -- test/vitest/vitest.plugins.config.ts --`, Node 24.21.0, `OPENCLAW_VITEST_MAX_WORKERS=2`): 13 failed files / 41 failed tests (CI's 12 plus `plugin-graceful-init-failure`), matching FRV run 35760444831 job `checks-node-agentic-plugins` (also red in runs 35743778013 and 35761282770).
- Planner/routing owners with the split config: `test/scripts/ci-node-test-plan.test.ts`, `test-projects.test.ts`, `test-projects-routing.test.ts`, `plugin-prerelease-test-plan.test.ts`: 1811/1811 pass.
- Fixed, same command and Node: 5 failed files / 10 failed tests, 375 passed files / 6101 passed tests. All eight loader-semantics files are green. Dropping the preload for the whole shard instead (probe run) fixes the same eight files but breaks 11 other files on `Cannot find module '.../src/agents/defaults.js' imported from .../src/plugin-sdk/provider-model-metadata.ts`, which is why the shard is split rather than de-preloaded.
- Remaining red files are independent of the preload (identical failures with and without it, and with `providers.runtime-core.ts`, `provider-hook-runtime-core.ts`, `plugin-instance*.ts`, `host-hook-state.ts` reverted to their pre-openclaw#155711/openclaw#155250/openclaw#154625/openclaw#155714 versions): `provider-runtime.test.ts` (6: `resolveProviderPluginsForHooks`/`classifyProviderFailoverSignalWithPlugin` no longer read the `withPluginRuntimeRegistryScope` registry), `native-session-catalog-registration.test.ts` (1: abort surfaces `PluginInstanceUnavailableError` instead of the caller's retirement error), `plugin-instance-invocation.test.ts` (1), `provider-public-artifacts.test.ts` (1: listener count after bundled policy load), `plugin-graceful-init-failure.test.ts` (1: `Maximum call stack size exceeded`, local only). These are product/test contract drift from the plugin runtime refactors and need their owners; they are called out in the landing report.
- `extensions/facetime/tests/package-manifest.test.ts`: 2/2 pass at 2026.9.4 and 2/2 pass after a local `pnpm release:prepare -- --version 2026.9.6 --write` (bump reverted, not committed).
- `OPENCLAW_TESTBOX=1 pnpm check:changed`: in progress at PR creation; result recorded in the landing report.

Co-authored-by: Peter Steinberger <[email protected]>
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 23, 2026
…dule graphs (openclaw#155925)

## Summary

Repairs the four residual red files in the release-only `checks-node-agentic-plugins` lane for 2026.9.6 (after openclaw#155892 split the native-loader project).

**Product regression (7 tests in 3 files):** openclaw#153508 turned `PluginRuntimeExecutionFrame` (`src/plugins/runtime/execution-frame.ts`) into a plain class while the plugin execution frame store stayed a process-wide `resolveGlobalSingleton`. Any second module instance of that file (a reloaded test graph, a duplicated chunk) fails the `instanceof` narrowing in `getPluginRuntimeExecutionFrame` and silently drops the Gateway request scope: `withPluginRuntimeRegistryScope` registries stopped reaching `resolveProviderPluginsForHooks` / `classifyProviderFailoverSignalWithPlugin`, and the reload-identity contract in `plugin-instance-invocation.test.ts` (added with the singleton in openclaw#146219) broke. This restores the shared constructor next to the shared store.

**Test fixture (1 test):** the `provider-public-artifacts` bundled scenario loads an ESM `provider-policy-api.js` from a fixture package with no module type through the bundled owners' native `require()` path. Under the tsx/esm worker preload the ambiguous file is compiled as CommonJS (`Unexpected token 'export'`), which the test's `finally` assertion masked as a listener-count mismatch. Shipped bundled artifacts (`dist/extensions/*`) are ESM under a `"type": "module"` package, so the fixture now declares that.

Files: `src/plugins/provider-runtime.test.ts` (6), `src/plugins/plugin-instance-invocation.test.ts` (1), `src/plugins/native-session-catalog-registration.test.ts` (green in the fixed run), `src/plugins/provider-public-artifacts.test.ts` (1).

`plugin-graceful-init-failure.test.ts` ("Maximum call stack size exceeded") reproduces locally with and without the preload and is a host stack-size artifact, not part of the CI residual; unchanged here.

## Validation

- Baseline on main tip (Node 24, `scripts/run-vitest.mjs run --config test/vitest/vitest.plugins.config.ts <files>`): 8 failed across the 4 files (plus the local-only stack-limit case).
- After the fix: the 4 files pass (`provider-runtime` 6/6, invocation 1/1, catalog 1/1, artifacts 33/33; 148/148 tests).
- Full `pnpm test -- test/vitest/vitest.plugins.config.ts --` shard on Node 24, run as four file chunks under the local 10-minute command cap: 105 + 88 + 94 + 91 test files green, 6109 tests passed; the only failure is the host-local `plugin-graceful-init-failure` stack-limit case (fails with and without the preload, not in the CI residual).
- `OPENCLAW_TESTBOX=1 pnpm check:changed`: all lanes pass except the dead-export scan, which flags `scripts/lib/tsgo-core-test-shards.mts: TSGO_CORE_TEST_MAX_ROOTS`; that export is untouched by this PR and was already made internal on main by `802e5125157` after this branch's base.
- Hosted CI on the exact head `cea3da31abcb`: 143 checks passed, 0 pending.

Co-authored-by: Peter Steinberger <[email protected]>
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 23, 2026
…claw#155960)

## Summary

Full Release Validation 35775979903 (CI child 35776854264, candidate `release/2026.9.6` = main `4064209d089c` + locale refresh + openclaw#155892) failed `subagent-registry.persistence.test.ts`, `subagent-spawn.authority.test.ts`, `chat.abort-errors.test.ts` and `chat.abort-incarnation.test.ts` in `settleSubagentRegistryPersistenceWork` with `residual registry roots: tasks:delivery (2|4|6): expected N to be +0`. All were green in the two previous validation runs.

Bisected to openclaw#151917 (`63729428338`, move terminal notification writes off the Gateway thread): `subagent-registry.persistence.test.ts` passes 30/30 at `63729428338^` and fails at `63729428338` with the exact CI signature; on current main it fails 5/5 locally. The `tasks:delivery` roots are not leaked: with a 20 s fence the same test passes (3.3 s), i.e. uncaptured deliveries settle 1–2 s after the test body, while the shared helper used `vi.waitFor`'s 1 s default. openclaw#155910 and openclaw#155888 already fixed individual fixtures by capturing deliveries; this widens the shared fence so the remaining callers (persistence, timing, resume, task-replacement, chat.abort-*) stop racing it. Test contract change only; no product change.

The related `build-artifacts` failure (`sqlite-sessions-transcripts-flip-proof` rejecting the delete-drain `stopReason`) was fixed on main in parallel by `9b877337ffb`; this branch merged that and carries no change of its own for it.

## Change

- `src/agents/subagents/registry/subagent-registry.persistence.test-support.ts`: `vi.waitFor(..., { timeout: 10_000 })` in `settleSubagentRegistryPersistenceWork`.

## Proof

- The four affected files green in one local vitest run with the change (`Tests 26 passed`, `Tests 36 passed`).
- `oxfmt --check` / `oxlint` clean on the changed file; exact-head hosted gates via `scripts/pr`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintainer Maintainer-authored PR merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. P2 Normal backlog priority with limited blast radius. plugin: facetime FaceTime plugin rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: S status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant