Skip to content

fix(cli): bundle @e2b/dockerfile-utils from source to avoid release build race - #2002

Merged
mishushakov merged 2 commits into
mainfrom
devin/1792506743-cli-bundle-dockerfile-utils-src
Oct 20, 2026
Merged

mishushakov merged 2 commits into
mainfrom
devin/1792506743-cli-bundle-dockerfile-utils-src

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

Summary

The Release run 39438173686 published e2b@2.57.0 but failed to publish @e2b/cli@2.22.1:

🦋  info Publishing "@e2b/cli" at "2.22.1"
🦋  info Publishing "e2b" at "2.57.0"
🦋  error an error occurred while publishing @e2b/cli: ELIFECYCLE undefined
🦋  error  ERROR  Error: Build failed with 1 error:
🦋  error [UNLOADABLE_DEPENDENCY] Could not load ../dockerfile-utils-js/dist/index.js
🦋  error     ╭─[ ../js-sdk/src/template/dockerfileParser.ts:13:8 ]
🦋  error  13 │ } from '@e2b/dockerfile-utils'
🦋  error     │                   ╰───── No such file or directory (os error 2)
🦋  error packages failed to publish:
🦋  @e2b/cli@2.22.1

Root cause: a race. changeset publish runs each package's prepublishOnly concurrently. e2b's prepublishOnly → prebuild rebuilds @e2b/dockerfile-utils (tsdown clean: true wipes its dist/), while @e2b/cli's build bundles e2b from source (paths: { e2b: ../js-sdk/src }) and so reads @e2b/dockerfile-utils from that dist/ at the same time. The same window opens whenever @e2b/dockerfile-utils itself is published alongside the CLI. This started with #1936, which added the dependency.

Fix: the CLI resolves @e2b/dockerfile-utils from source too, the same way it already resolves e2b, so its build no longer reads another package's dist/:

  • packages/cli/tsconfig.json: paths["@e2b/dockerfile-utils"] = ["../dockerfile-utils-js/src"] (for tsc --noEmit)
  • packages/cli/tsdown.config.ts: alias["@e2b/dockerfile-utils"] = ../dockerfile-utils-js/src/index.ts (for bundling)

Verified locally: with packages/dockerfile-utils-js/dist deleted, pnpm --dir packages/cli build failed on main (TS2307: Cannot find module '@e2b/dockerfile-utils'). On this branch it succeeds, and node dist/index.js --version prints 2.22.1. Lint, prettier, typecheck and CLI unit tests pass.

A @e2b/cli patch changeset is included. 2.22.1 was never published to npm, and the release workflow refuses to run unless there is a version bump, so merging this PR lets the next Release publish the CLI.

Link to Devin session: https://app.devin.ai/sessions/0574c52ea5ce4a78bcd1b2b0dd801241
Open in Devin Desktop: https://app.devin.ai/desktop/session/0574c52ea5ce4a78bcd1b2b0dd801241?variant=devin


Devin Review

…uild race

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".

  • Disable automatic comment, CI, and merge conflict monitoring

@cla-bot cla-bot Bot added the cla-signed label Oct 20, 2026
@changeset-bot

changeset-bot Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 3cedd11

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@e2b/cli Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-20T14:34:36.078588Z d854293 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TASTE.md review: compliant. 0 violations. This PR only changes CLI build resolution (the tsconfig.json path and tsdown alias for @e2b/dockerfile-utils) plus a changeset. It doesn't touch the public SDK surface, so none of T-1 to T-74 apply; T-54 (single entry point) and T-56 (version read from package.json) stay intact.

Written by Devin

@github-actions

github-actions Bot commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

Package Artifacts

Built from 5acdbc7. Download artifacts from this workflow run.

JS SDK (e2b@2.57.1-devin-1792506743-cli-bundle-dockerfile-utils-src.0, with @e2b/dockerfile-utils@0.1.2-devin-1792506743-cli-bundle-dockerfile-utils-src.0):

npm install ./e2b-dockerfile-utils-0.1.2-devin-1792506743-cli-bundle-dockerfile-utils-src.0.tgz ./e2b-2.57.1-devin-1792506743-cli-bundle-dockerfile-utils-src.0.tgz

CLI (@e2b/cli@2.22.2-devin-1792506743-cli-bundle-dockerfile-utils-src.0):

npm install ./e2b-cli-2.22.2-devin-1792506743-cli-bundle-dockerfile-utils-src.0.tgz

Code Interpreter JS SDK (@e2b/code-interpreter@2.9.1-devin-1792506743-cli-bundle-dockerfile-utils-src.0):

npm install ./e2b-code-interpreter-2.9.1-devin-1792506743-cli-bundle-dockerfile-utils-src.0.tgz

Desktop JS SDK (@e2b/desktop@2.5.1-devin-1792506743-cli-bundle-dockerfile-utils-src.0):

npm install ./e2b-desktop-2.5.1-devin-1792506743-cli-bundle-dockerfile-utils-src.0.tgz

Python SDK (e2b==2.57.0+devin.1792506743.cli.bundle.dockerfile.utils.src, with e2b-dockerfile-utils==0.1.1+devin.1792506743.cli.bundle.dockerfile.utils.src):

pip install ./e2b_dockerfile_utils-0.1.1+devin.1792506743.cli.bundle.dockerfile.utils.src-py3-none-any.whl ./e2b-2.57.0+devin.1792506743.cli.bundle.dockerfile.utils.src-py3-none-any.whl

Code Interpreter Python SDK (e2b-code-interpreter==2.11.1+devin.1792506743.cli.bundle.dockerfile.utils.src):

pip install ./e2b_code_interpreter-2.11.1+devin.1792506743.cli.bundle.dockerfile.utils.src-py3-none-any.whl

Desktop Python SDK (e2b-desktop==2.7.0+devin.1792506743.cli.bundle.dockerfile.utils.src):

pip install ./e2b_desktop-2.7.0+devin.1792506743.cli.bundle.dockerfile.utils.src-py3-none-any.whl

devin-ai-integration[bot]

This comment was marked as resolved.

claude[bot]

This comment was marked as resolved.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@mishushakov
mishushakov enabled auto-merge (squash) October 20, 2026 14:50
@mishushakov
mishushakov merged commit b8afc34 into main Oct 20, 2026
33 checks passed
@mishushakov
mishushakov deleted the devin/1792506743-cli-bundle-dockerfile-utils-src branch October 20, 2026 14:53
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