Skip to content

feat(bun): Add orchestrion bun build plugin#21410

Merged
isaacs merged 1 commit into
developfrom
isaacs/bun-orchestrion
Jun 18, 2026
Merged

feat(bun): Add orchestrion bun build plugin#21410
isaacs merged 1 commit into
developfrom
isaacs/bun-orchestrion

Conversation

@isaacs

@isaacs isaacs commented Jun 9, 2026

Copy link
Copy Markdown
Member

Use the orchestrion plugin defined in server-utils, and create a plugin that Bun can use in bun build mode.

Note: this does not provide a plugin for use with bun run, because that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun runtime, likely with a version guard to avoid the footgun of removing CommonJS exports in some cases.

@isaacs isaacs requested a review from a team as a code owner June 9, 2026 19:23
@isaacs isaacs requested review from JPeer264 and mydea and removed request for a team June 9, 2026 19:24
@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch from 48fa3e3 to 0157d09 Compare June 9, 2026 19:27
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 362c870 to 39be3da Compare June 9, 2026 19:28
@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

size-limit report 📦

Path Size % Change Change
@sentry/browser 27.45 kB - -
@sentry/browser - with treeshaking flags 25.88 kB - -
@sentry/browser (incl. Tracing) 45.89 kB - -
@sentry/browser (incl. Tracing + Span Streaming) 48.12 kB -0.02% -5 B 🔽
@sentry/browser (incl. Tracing, Profiling) 50.67 kB - -
@sentry/browser (incl. Tracing, Replay) 85.08 kB - -
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 74.69 kB - -
@sentry/browser (incl. Tracing, Replay with Canvas) 89.78 kB - -
@sentry/browser (incl. Tracing, Replay, Feedback) 102.45 kB - -
@sentry/browser (incl. Feedback) 44.62 kB - -
@sentry/browser (incl. sendFeedback) 32.25 kB - -
@sentry/browser (incl. FeedbackAsync) 37.38 kB - -
@sentry/browser (incl. Metrics) 28.52 kB - -
@sentry/browser (incl. Logs) 28.76 kB - -
@sentry/browser (incl. Metrics & Logs) 29.45 kB - -
@sentry/react 29.25 kB - -
@sentry/react (incl. Tracing) 48.18 kB - -
@sentry/vue 32.56 kB - -
@sentry/vue (incl. Tracing) 47.76 kB - -
@sentry/svelte 27.48 kB - -
CDN Bundle 29.86 kB - -
CDN Bundle (incl. Tracing) 48.29 kB -0.02% -5 B 🔽
CDN Bundle (incl. Logs, Metrics) 31.4 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) 49.59 kB -0.01% -3 B 🔽
CDN Bundle (incl. Replay, Logs, Metrics) 70.71 kB - -
CDN Bundle (incl. Tracing, Replay) 85.62 kB -0.01% -4 B 🔽
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) 86.88 kB -0.01% -3 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback) 91.46 kB -0.01% -3 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) 92.71 kB -0.01% -1 B 🔽
CDN Bundle - uncompressed 88.8 kB - -
CDN Bundle (incl. Tracing) - uncompressed 146.08 kB -0.01% -4 B 🔽
CDN Bundle (incl. Logs, Metrics) - uncompressed 93.5 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) - uncompressed 150.06 kB -0.01% -4 B 🔽
CDN Bundle (incl. Replay, Logs, Metrics) - uncompressed 218.33 kB - -
CDN Bundle (incl. Tracing, Replay) - uncompressed 264.95 kB -0.01% -4 B 🔽
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) - uncompressed 268.91 kB -0.01% -4 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 278.65 kB -0.01% -4 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) - uncompressed 282.6 kB -0.01% -4 B 🔽
@sentry/nextjs (client) 50.58 kB - -
@sentry/sveltekit (client) 46.27 kB - -
@sentry/core/server 76.16 kB -0.01% -2 B 🔽
@sentry/core/browser 63.31 kB -0.01% -2 B 🔽
@sentry/node-core 61.87 kB -0.01% -2 B 🔽
@sentry/node 126.78 kB +1.71% +2.13 kB 🔺
@sentry/node/import (ESM hook with diagnostics-channel injection) 70.05 kB - -
@sentry/node/light 50.92 kB -0.01% -2 B 🔽
@sentry/node - without tracing 74.23 kB -0.01% -2 B 🔽
@sentry/aws-serverless 85.34 kB -0.01% -3 B 🔽
@sentry/cloudflare (withSentry) - minified 174.48 kB -0.01% -4 B 🔽
@sentry/cloudflare (withSentry) 436.52 kB -0.01% -23 B 🔽

View base workflow run

@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch from 0157d09 to 25bfdaa Compare June 10, 2026 19:33
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 39be3da to b34aa87 Compare June 10, 2026 19:34
@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch from 25bfdaa to 7a8b730 Compare June 10, 2026 19:37
Comment thread packages/bun/package.json Outdated
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from b34aa87 to 653fc0e Compare June 10, 2026 20:06
@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch from 7a8b730 to 7b69e3b Compare June 10, 2026 20:07
@github-actions

Copy link
Copy Markdown
Contributor

👋 @mydea, @JPeer264 — Please review this PR when you get a chance!

@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch 3 times, most recently from c26138a to a16cf66 Compare June 15, 2026 18:46
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 653fc0e to 8743326 Compare June 15, 2026 18:48
Comment thread packages/bun/src/plugin.ts Outdated
Comment thread packages/bun/src/plugin.ts Outdated
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from b5a794a to ac38662 Compare June 15, 2026 19:00
@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch from a16cf66 to 5c34ba0 Compare June 15, 2026 19:24
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from ac38662 to 0cfd982 Compare June 15, 2026 19:46
@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch from 5c34ba0 to c433056 Compare June 15, 2026 22:44
isaacs added a commit that referenced this pull request Jun 15, 2026
Use the orchestrion plugin defined in server-utils, and create a plugin
that Bun can use in `bun build` mode.

Note: this does *not* provide a plugin for use with `bun run`, because
that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun
runtime, likely with a version guard to avoid the footgun of removing
CommonJS exports in some cases.
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 0cfd982 to ccbd1b2 Compare June 15, 2026 22:45
Comment thread packages/bun/src/plugin.ts Outdated
@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch from c433056 to 1551113 Compare June 16, 2026 17:53
isaacs added a commit that referenced this pull request Jun 16, 2026
Use the orchestrion plugin defined in server-utils, and create a plugin
that Bun can use in `bun build` mode.

Note: this does *not* provide a plugin for use with `bun run`, because
that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun
runtime, likely with a version guard to avoid the footgun of removing
CommonJS exports in some cases.
@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch from 3300ba7 to c9f3507 Compare June 18, 2026 04:20
@semgrep-code-getsentry

Copy link
Copy Markdown

Semgrep found 1 ssc-d17d3487-883b-46a9-bec9-dee3375f7532 finding:

Risk: Affected versions of esbuild are vulnerable to Download of Code Without Integrity Check / Untrusted Search Path. esbuild's Deno distribution module (lib/deno/mod.ts) contains an import.meta.main CLI entrypoint that calls install() directly when the module is run as a script (deno run https://deno.land/x/esbuild@vX/mod.js). This download path has no SHA-256 integrity verification: if NPM_CONFIG_REGISTRY resolves to an attacker-controlled registry, the fetched binary is executed immediately, yielding arbitrary code execution without any API call in user code.

Manual Review Advice: A vulnerability from this advisory is reachable if you invoke the esbuild Deno module directly as a CLI tool (e.g. deno run https://deno.land/x/esbuild@vX/mod.js) and the NPM_CONFIG_REGISTRY environment variable resolves the binary download to an untrusted registry

Fix: Upgrade this library to at least version 0.28.1 at sentry-javascript/yarn.lock:15987.

Reference(s): GHSA-gv7w-rqvm-qjhr

@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch 3 times, most recently from 7d1f62e to 7323f1a Compare June 18, 2026 04:50
isaacs added a commit that referenced this pull request Jun 18, 2026
Use the orchestrion plugin defined in server-utils, and create a plugin
that Bun can use in `bun build` mode.

Note: this does *not* provide a plugin for use with `bun run`, because
that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun
runtime, likely with a version guard to avoid the footgun of removing
CommonJS exports in some cases.
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 568911f to 69a65aa Compare June 18, 2026 04:51
Comment thread packages/bun/src/plugin.ts
@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch from 7323f1a to 92b508d Compare June 18, 2026 14:20
isaacs added a commit that referenced this pull request Jun 18, 2026
Use the orchestrion plugin defined in server-utils, and create a plugin
that Bun can use in `bun build` mode.

Note: this does *not* provide a plugin for use with `bun run`, because
that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun
runtime, likely with a version guard to avoid the footgun of removing
CommonJS exports in some cases.
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 69a65aa to ea45a82 Compare June 18, 2026 14:20
isaacs added a commit that referenced this pull request Jun 18, 2026
Use the orchestrion plugin defined in server-utils, and create a plugin
that Bun can use in `bun build` mode.

Note: this does *not* provide a plugin for use with `bun run`, because
that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun
runtime, likely with a version guard to avoid the footgun of removing
CommonJS exports in some cases.
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from ea45a82 to 623d0c5 Compare June 18, 2026 14:27
Comment thread packages/bun/src/plugin.ts Outdated
isaacs added a commit that referenced this pull request Jun 18, 2026
Use the orchestrion plugin defined in server-utils, and create a plugin
that Bun can use in `bun build` mode.

Note: this does *not* provide a plugin for use with `bun run`, because
that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun
runtime, likely with a version guard to avoid the footgun of removing
CommonJS exports in some cases.
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 623d0c5 to 2c1a850 Compare June 18, 2026 15:38
@isaacs isaacs force-pushed the experiment/orchestrionjs-auto-instrumentation branch 2 times, most recently from a1fba56 to ce95b7a Compare June 18, 2026 16:25
isaacs added a commit that referenced this pull request Jun 18, 2026
Use the orchestrion plugin defined in server-utils, and create a plugin
that Bun can use in `bun build` mode.

Note: this does *not* provide a plugin for use with `bun run`, because
that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun
runtime, likely with a version guard to avoid the footgun of removing
CommonJS exports in some cases.
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 2c1a850 to 54e9bb3 Compare June 18, 2026 17:25

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 54e9bb3. Configure here.

Comment thread packages/bun/package.json Outdated
Comment thread packages/bun/package.json Outdated
isaacs added a commit that referenced this pull request Jun 18, 2026
Use the orchestrion plugin defined in server-utils, and create a plugin
that Bun can use in `bun build` mode.

Note: this does *not* provide a plugin for use with `bun run`, because
that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun
runtime, likely with a version guard to avoid the footgun of removing
CommonJS exports in some cases.
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 54e9bb3 to 90c3233 Compare June 18, 2026 17:34
Base automatically changed from experiment/orchestrionjs-auto-instrumentation to develop June 18, 2026 17:38
Use the orchestrion plugin defined in server-utils, and create a plugin
that Bun can use in `bun build` mode.

Note: this does *not* provide a plugin for use with `bun run`, because
that feature is blocked by oven-sh/bun#31770

When that issue resolves, we can look into providing this for the bun
runtime, likely with a version guard to avoid the footgun of removing
CommonJS exports in some cases.
@isaacs isaacs force-pushed the isaacs/bun-orchestrion branch from 90c3233 to a8f426c Compare June 18, 2026 17:39
@isaacs isaacs merged commit 974771b into develop Jun 18, 2026
516 of 528 checks passed
@isaacs isaacs deleted the isaacs/bun-orchestrion branch June 18, 2026 21:20
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.

3 participants