Repository navigation
Conversation
size-limit report 📦Compared: 3f38e54 (PR test merge using develop at f74a45d) Against: f74a45d (develop) · base run #64531 ✅ Baseline matches: this diff contains only this PR's changes.
|
|
One or more gzipped bundles increased by more than 500 bytes. If this increase is intentional, add the Accept Bundlesize Increase label to this PR to rerun and accept the check. |
Optional E2E testsSome optional checks were not successful. They do not block the merge. 4 not successful, 50 successful. See the run.
Successful checks
|
03ae48a to
b61e94d
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Want reviews to match your repository better? Bugbot Learning can learn team-specific rules from PR activity. A team admin can enable Learning in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit b61e94d. Configure here.
|
Hmm, flattening ESM breaks tree-shaking. Trying with just flattening CJS only, see if that's a bit nicer. |
`require('@sentry/node')` loaded 606 CommonJS files and took about
95 ms. Most of that time went to resolving, reading and evaluating many
small files, because each source file was a published file.
The CJS builds of `@sentry/core`, `@sentry/node`, `@sentry/server-utils`
and `@sentry/server-runtime-injection` now publish one file per entry,
plus shared chunks with fixed names. `require('@sentry/node')` now loads
69 files in about 47 ms.
The ESM builds keep one file per module. Bundlers use them, and drop
unused files by the package's `sideEffects` setting. Flat ESM files
made the Next.js edge build fail on `node:` imports in code it never
used, and grew the server bundles in the size check by up to 140%.
Each package keeps its `@sentry/*` dependencies external, so no package
carries a second copy of another. Rollup puts a module in a chunk by
the set of entries that reach it, so build-time code stays out of the
runtime entries, and runtime injection stays out of the build-time
ones.
The Lambda layer build now finds the `getSDKSource` marker by searching
the core build, because the flat CJS build has no `utils/env.js`. Two
cloudflare tests lose their mocks of that old CJS path.
A new test caps the files each Sentry package loads when Node requires
`@sentry/node`. The runtime-entries test now also checks that
build-time entries do not reach runtime injection. Three config entries
already do, through the `@sentry/node` and `@sentry/nitro` roots, and
are known violations.
Closes #25680
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
bdf1180 to
29a8cd2
Compare
@sentry/node startup time@sentry/node startup time
|
Updated PR description to match CJS-only approach. |

require('@sentry/node')loaded 606 CommonJS files and took about95 ms. Most of that time went to resolving, reading and evaluating many
small files, because each source file was a published file.
The CJS builds of
@sentry/core,@sentry/node,@sentry/server-utilsand
@sentry/server-runtime-injectionnow publish one file per entry,plus shared chunks with fixed names.
require('@sentry/node')now loads69 files in about 47 ms.
The ESM builds keep one file per module. Bundlers use them, and drop
unused files by the package's
sideEffectssetting. Flat ESM filesmade the Next.js edge build fail on
node:imports in code it neverused, and grew the server bundles in the size check by up to 140%.
Each package keeps its
@sentry/*dependencies external, so no packagecarries a second copy of another. Rollup puts a module in a chunk by
the set of entries that reach it, so build-time code stays out of the
runtime entries, and runtime injection stays out of the build-time
ones.
The Lambda layer build now finds the
getSDKSourcemarker by searchingthe core build, because the flat CJS build has no
utils/env.js. Twocloudflare tests lose their mocks of that old CJS path.
A new test caps the files each Sentry package loads when Node requires
@sentry/node. The runtime-entries test now also checks thatbuild-time entries do not reach runtime injection. Three config entries
already do, through the
@sentry/nodeand@sentry/nitroroots, andare known violations.
Closes #25680