Repository navigation
fix: restore workspace workers in npm installs - #177130
Conversation
Keep local memory and skills subprocess outputs outside the sealed portable worker directory. Runtime launchers and build entries continue to share the manifest, while npm preserves the portable archive-only contract. Co-authored-by: vincentkoc <[email protected]>
Worked on by: - @vincentkoc Co-authored-by: vincentkoc <[email protected]> OpenClaw-Publication: 837639f8-021c-49ac-8d2a-8636b8aeec13
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. What this changesThis PR moves the packaged Memory and Skills worker outputs outside the npm-excluded portable worker directory. Example: An npm-installed OpenClaw launches its local Memory worker.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this maintainer-authored PR fixes a concrete packaging omission still present on main, with no introduced code defects found; the required CI gate is currently failing. Priority: P1 Before mergeNone. FindingsNone. Tests
Agent review detailsHow this fits togetherThe runtime-process manifest supplies source locations and compiled paths to build tooling and subprocess launchers; npm file selection determines which compiled workers reach installed users. flowchart TD
A[Runtime process manifest] --> B[Build entries]
A --> C[Workspace launcher]
B --> D[Compiled worker files]
D --> E[Npm package selection]
E --> F[Installed package]
C --> F
F --> G[Memory and Skills subprocesses]
Technical reviewBest possible solution: Keep the shared manifest as the single build-and-launch owner and ship the two local workers outside the sealed portable directory. Do we have a high-confidence way to reproduce the issue? Source establishes the failure directly: main builds and launches both workers beneath the directory excluded from npm packages; no target code was executed during this review. Is this the best way to solve the issue? This is the smallest complete repair: separate source and compiled paths in the existing manifest, retain source loading, and test the independent npm selection boundary. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 7c2eb6c3728c. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +8, Tests +40. Total +48 across 2 files. Added test files: 1. View PR surface stats
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 19, 2026, 4:35 AM ET / 08:35 UTC. |
After #177082 made the initial generation read provisional, the old fault corrupted the source before private snapshot acquisition. Wait for the private image to close, then perform a real SQLite commit between the final generation reads. Preserve all diagnostic assertions and verify the committed version. Co-authored-by: vincentkoc <[email protected]>
Worked on by: - @vincentkoc Co-authored-by: vincentkoc <[email protected]> OpenClaw-Publication: 1a214a82-7a55-4e45-a884-c50f2d10bbe3
|
Merged via squash auto-merge.
|
The valid version-4 write introduced by #177130 happens after private snapshot acquisition. Its final generation check correctly refuses the changed family, not a snapshot-size mismatch from the earlier corruption fixture in #177158. Serial exact CI merge and base replays reproduce the stale expectation. Keep the exact cause, both source paths, best-effort advice, and committed version assertion. All nine schema cases pass; targeted native types, lint and format pass. The suppression audit reports an unrelated main-owned UI helper allowlist mismatch (13 pass, 1 fail); this test-only change adds no suppression.
* fix: restore workspace workers in npm installs Keep local memory and skills subprocess outputs outside the sealed portable worker directory. Runtime launchers and build entries continue to share the manifest, while npm preserves the portable archive-only contract. Co-authored-by: vincentkoc <[email protected]> * fix: restore workspace workers in npm installs Worked on by: - @vincentkoc Co-authored-by: vincentkoc <[email protected]> OpenClaw-Publication: 837639f8-021c-49ac-8d2a-8636b8aeec13 * test(update): inject writes during final generation verification After openclaw#177082 made the initial generation read provisional, the old fault corrupted the source before private snapshot acquisition. Wait for the private image to close, then perform a real SQLite commit between the final generation reads. Preserve all diagnostic assertions and verify the committed version. Co-authored-by: vincentkoc <[email protected]> * Publish openclaw/release-packaged-workspace-workers-20261019 Worked on by: - @vincentkoc Co-authored-by: vincentkoc <[email protected]> OpenClaw-Publication: 1a214a82-7a55-4e45-a884-c50f2d10bbe3 --------- Co-authored-by: vincentkoc <[email protected]>
The valid version-4 write introduced by openclaw#177130 happens after private snapshot acquisition. Its final generation check correctly refuses the changed family, not a snapshot-size mismatch from the earlier corruption fixture in openclaw#177158. Serial exact CI merge and base replays reproduce the stale expectation. Keep the exact cause, both source paths, best-effort advice, and committed version assertion. All nine schema cases pass; targeted native types, lint and format pass. The suppression audit reports an unrelated main-owned UI helper allowlist mismatch (13 pass, 1 fail); this test-only change adds no suppression.
What Problem This Solves
Fixes packaged onboarding and agent turns exiting when the local memory worker cannot be found; the sibling skills worker was also omitted from npm installs.
User Impact
User impact: npm installations retain the local memory and skills subprocesses needed for workspace operations. No configuration change or migration is required. Portable deployment assets remain archive-only.
Why This Change Was Made
The runtime manifest emitted these local subprocesses inside
dist/worker, which npm intentionally excludes in favor of a sealed portable-deployment archive. Re-including files there would also break the directory-absence check used to select that archive.Emit the two local workers under
dist/agentsinstead. Source locations stay unchanged, and build entries and launchers continue to use the same runtime manifest. A regression checks the real npm pack inventory against all core runtime-process descriptors and preserves portable-graph exclusion.Evidence
pnpm test test/scripts/runtime-process-package.test.ts --maxWorkers=1: passed; 296 ms test time and 3.79 s command wall time. CI seconds are not yet available.pnpm build: passed (260.66 s wall time). The build reported an unrelated advisory UI boot-size overage; no budget or guard was changed.dist/workerdirectory.CI failure and fixture correction
The initial CI run 39222038899 failed in
checks-node-changed-6: the generation-verification fixture received a snapshot-size mismatch before reaching its expected final-generation diagnostic. The planner initially classified this as unknown. The same signature reproduced on the actual tested merge592617eeand its main parentb6e0872. Main change #177082 made the initial observation provisional; the old fixture corrupted the source before snapshot acquisition.The test-only correction waits for the private snapshot to close, then performs a valid SQLite commit between the final generation reads. Every original diagnostic assertion remains intact, with an added native version readback. No production code, integrity guard, redaction policy, skip, retry, timeout, or budget changed.
pnpm test:ci-failed 177130 --runselected replay and the native Node compatibility case passed. Targeted types, typed lint, formatting, and fresh independent P0–P2 review passed.The original build, package-integrity, and extracted-worker proof above remain valid for unchanged production code; the full build was not repeated for this fixture repair. The original CI failure is retained as failed history, not relabeled green. Fresh remote-head CI is a separate pending gate.
Proof limits: the complete channel-agent, typed-onboarding, and upgrade release lanes were not rerun. The local tarball is verification material, not a release-qualified artifact. Broader exact-head proof remains with PR CI and release qualification.
Contributor credit: @vincentkoc directed this release repair.
Work sessions
Worked on by
View the OpenClaw team session