Skip to content

fix(cli): support flat standalone dependencies - #605

Merged
Aymericr merged 1 commit into
mainfrom
fix/cli-runtime-staging
Aug 7, 2026
Merged

fix(cli): support flat standalone dependencies#605
Aymericr merged 1 commit into
mainfrom
fix/cli-runtime-staging

Conversation

@Aymericr

@Aymericr Aymericr commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Summary

  • allow runtime staging when a clean standalone build already has flat dependencies and no Bun linkage directory
  • preserve real filesystem errors instead of silently treating them as optional directories

Verification

  • bunx biome check packages/cli/scripts/stage-runtime.ts
  • bun run --cwd packages/cli check-types
  • bun test packages/cli/src (20 passed)
  • bun run --cwd packages/cli prepublishOnly
  • packed-tarball smoke from a synthetic flat standalone runtime with no .bun/node_modules

Note

Low Risk
Small change to optional-directory handling in the CLI packaging script; no auth, data, or runtime behavior changes beyond avoiding false failures on flat layouts.

Overview
Runtime staging now tolerates standalone builds that already ship flat node_modules and lack Bun’s .bun / .bun/node_modules layout.

removeUnusedSharp and flattenBunNodeModules no longer treat every readdir failure as “optional”: only ENOENT is ignored; other filesystem errors propagate so real staging problems aren’t swallowed.

Reviewed by Cursor Bugbot for commit fc82aee. Bugbot is set up for automated code reviews on this repo. Configure here.

@Aymericr
Aymericr merged commit 4e305bd into main Aug 7, 2026
3 checks passed
@Aymericr
Aymericr deleted the fix/cli-runtime-staging branch August 7, 2026 03:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant