feat(nuxt)!: Bundle server config into Nitro build - #24094
Conversation
|
bugbot run |
size-limit report 📦
|
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
❌ 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 830a18a. Configure here.
| ); | ||
| }); | ||
| return; | ||
| } |
There was a problem hiding this comment.
Cloudflare filter misses inferred presets
Medium Severity
The Cloudflare skip only looks at nitroConfig.preset during nitro:config. Nitro often fills that in later from CF_PAGES, NITRO_PRESET, or similar, so a leftover sentry.server.config.ts can still be bundled into the worker as the Node SDK. The close-hook shim later sees the resolved preset and correctly skips, which makes the earlier filter miss more likely.
Reviewed by Cursor Bugbot for commit 830a18a. Configure here.
|
|
||
| expect(prerenderedPage).not.toContain('sentry-trace'); | ||
| expect(prerenderedPage).not.toContain('baggage'); | ||
| }); |
There was a problem hiding this comment.
Prerender test does not prove skip
Low Severity
The prerender test treats missing sentry-trace and baggage tags as proof that bundled Sentry.init is skipped at build time. Those tags are already omitted for responses with the x-nitro-prerender header, so the assertion can pass even when init still runs and send events during CI builds.
Triggered by project rule: PR Review Guidelines for Cursor Bot
Reviewed by Cursor Bugbot for commit 830a18a. Configure here.


Previously, the
sentry.server.config.tsfile was emitted in the build output so it can be added with--import. As we don't rely on early-importing anymore (thanks to orchestrion), we don't need this file anymore.Sentry.initruns at startup withoutnode --import. Works on Nitro 2 and 3, prod and dev (hurray)--importcompat: The old file path now gets a shim that just prints "remove this flag". A CI variant runs the whole suite with the shim preloaded to see if the warning is printedinitwins. The bundled init skips with a notice.listenare captured and flushed (first and last plugin slot)autoInjectServerSentrymodes, kept working until v12