-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
feat(node): Ensure prismaIntegration
works with Prisma v5
#17595
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not really related but noticed we had these checked in for no reason.
expect(spans).toContainEqual( | ||
expect.objectContaining({ | ||
data: { | ||
'db.statement': expect.stringContaining('SELECT'), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these tests were missing and this was actually what was not working in v5 without passing in the custom instrumentation, previously. this is now fixed on this branch.
size-limit report 📦
|
node-overhead report 🧳Note: This is a synthetic benchmark with a minimal express app and does not necessarily reflect the real-world performance impact in an application.
|
prismaIntergation
works with Prisma v5prismaIntegration
works with Prisma v5
const spanId = engineSpan.span_id; | ||
const traceId = engineSpan.trace_id; | ||
|
||
const links: Link[] | undefined = engineSpan.links?.map(link => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
q: any idea what links prisma instrumentation would add to their spans? Just curious since this one of the first links usages I see in our code, no complaints :D
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no idea, I just copied this from their internal implementation of this where they allow for this :D Maybe a good link to drop here, I tried to make this work based on this:
https://github.com/prisma/prisma/blob/5.22.0/packages/instrumentation/src/ActiveTracingHelper.ts#L54
}, | ||
}; | ||
|
||
tracer._idGenerator = temporaryIdGenerator; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm wondering if this works reliably. Probably not because users can configure tools like terser to minify private fields (like we do in our CDN bundles). But then again, quite unlikely to happen in server builds. So let's roll with it :D
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah I had the same thought. this is def. not bullet proof 😬 for now I added a log about this, if this does not work then you will miss out on some spans (the db
spans themselves) which is not great but I guess it is OK for this hacky compatibility work for the old version!
} finally { | ||
// Ensure we always restore this at the end, even if something errors | ||
tracer._idGenerator = initialIdGenerator; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Prisma Span Missing Attributes, Tracer ID Conflict
Prisma v5 compatibility spans created in createEngineSpan
are missing mandatory Sentry attributes like SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN
and SEMANTIC_ATTRIBUTE_SENTRY_OP
. Additionally, the temporary global override of tracer._idGenerator
(lines 127-135) creates a race condition, potentially causing other concurrently created spans to receive incorrect IDs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is correct in theory but we add the attributes etc. in a separate place.
Once getsentry/sentry-javascript#17595 is merged support will be even better, but even today passing the `prismaInstrumentation` will actually fail, so not doing it is better even if some spans are missing. Also updating the docs to reflect that this is enabled by default now.
![snyk-io[bot]](https://badgen.net/badge/icon/snyk-io%5Bbot%5D/green?label=)  [<img width="16" alt="Powered by Pull Request Badge" src="https://user-images.githubusercontent.com/1393946/111216524-d2bb8e00-85d4-11eb-821b-ed4c00989c02.png">](https://pullrequestbadge.com/?utm_medium=github&utm_source=reisene&utm_campaign=badge_info)<!-- PR-BADGE: PLEASE DO NOT REMOVE THIS COMMENT -->  <h3>Snyk has created this PR to upgrade @sentry/node from 9.43.0 to 10.12.0.</h3> :information_source: Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project. <hr/> - The recommended version is **22 versions** ahead of your current version. - The recommended version was released **23 days ago**. ⚠️ **Warning:** This PR contains major version upgrade(s), and may be a breaking change. #### Issues fixed by the recommended upgrade: | | Issue | Score | Exploit Maturity | :-------------------------:|:-------------------------|:-------------------------|:-------------------------  | Regular Expression Denial of Service (ReDoS)<br/>[SNYK-JS-BRACEEXPANSION-9789073](https://snyk.io/vuln/SNYK-JS-BRACEEXPANSION-9789073) | **57** | Proof of Concept  | Regular Expression Denial of Service (ReDoS)<br/>[SNYK-JS-BRACEEXPANSION-9789073](https://snyk.io/vuln/SNYK-JS-BRACEEXPANSION-9789073) | **57** | Proof of Concept <details> <summary><b>Release notes</b></summary> <br/> <details> <summary>Package name: <b>@sentry/node</b></summary> <ul> <li> <b>10.12.0</b> - <a href="https://redirect.github.com/getsentry/sentry-javascript/releases/tag/10.12.0">2025-09-16</a></br><h3>Important Changes</h3> <ul> <li> <p><strong>ref: Add and Adjust error event <code>mechanism</code> values</strong></p> <p>This release includes a variety of changes aimed at setting the <code>mechanism</code> field on errors captured automatically by the Sentry SDKs. <a href="https://redirect.github.com/getsentry/sentry-javascript/issues/17212" data-hovercard-type="issue" data-hovercard-url="/getsentry/sentry-javascript/issues/17212/hovercard">The intention</a> is to clearly mark which instrumentation captured an error. In addition, some instrumentations previously did not yet annotate the error as handled or unhandled which this series of PRs corrects as well.</p> <details> <summary> Relevant PRs </summary> <br> <p>Released in <code>10.12.0</code>:</p> <ul> <li>ref(angular): Adjust ErrorHandler event mechanism (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17608" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17608/hovercard">#17608</a>)</li> <li>ref(astro): Adjust <code>mechanism</code> on error events captured by astro middleware (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17613" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17613/hovercard">#17613</a>)</li> <li>ref(aws-severless): Slightly adjust aws-serverless mechanism type (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17614" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17614/hovercard">#17614</a>)</li> <li>ref(bun): Adjust <code>mechanism</code> of errors captured in Bun.serve (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17616" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17616/hovercard">#17616</a>)</li> <li>ref(cloudflare): Adjust event <code>mechanisms</code> and durable object origin (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17618" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17618/hovercard">#17618</a>)</li> <li>ref(core): Adjust <code>mechanism</code> in <code>captureConsoleIntegration</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17633" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17633/hovercard">#17633</a>)</li> <li>ref(core): Adjust MCP server error event <code>mechanism</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17622" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17622/hovercard">#17622</a>)</li> <li>ref(core): Simplify <code>linkedErrors</code> mechanism logic (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17600" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17600/hovercard">#17600</a>)</li> <li>ref(deno): Adjust <code>mechanism</code> of errors caught by <code>globalHandlersIntegration</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17635" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17635/hovercard">#17635</a>)</li> <li>ref(nextjs): Set more specific event <code>mechanism</code>s (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17543" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17543/hovercard">#17543</a>)</li> <li>ref(node): Adjust mechanism of express, hapi and fastify error handlers (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17623" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17623/hovercard">#17623</a>)</li> <li>ref(node-core): Add <code>mechanism</code> to cron instrumentations (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17544" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17544/hovercard">#17544</a>)</li> <li>ref(node-core): Add more specific <code>mechanism.type</code> to worker thread errors from <code>childProcessIntegration</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17578" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17578/hovercard">#17578</a>)</li> <li>ref(node-core): Adjust <code>mechanism</code> of <code>onUnhandledRejection</code> and <code>onUnhandledException</code> integrations (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17636" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17636/hovercard">#17636</a>)</li> <li>ref(node): Add mechanism to errors captured via connect and koa integrations (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17579" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17579/hovercard">#17579</a>)</li> <li>ref(nuxt): Add and adjust <code>mechanism.type</code> in error events (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17599" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17599/hovercard">#17599</a>)</li> <li>ref(react): Add mechanism to <code>reactErrorHandler</code> and adjust mechanism in <code>ErrorBoundary</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17602" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17602/hovercard">#17602</a>)</li> <li>ref(remix): Adjust event mechanism of <code>captureRemixServerException</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17629" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17629/hovercard">#17629</a>)</li> <li>ref(replay-internal): Add mechanism to error caught by <code>replayIntegration</code> in debug mode (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17606" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17606/hovercard">#17606</a>)</li> <li>ref(solid): Add <code>mechanism</code> to error captured by <code>withSentryErrorBoundary</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17607" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17607/hovercard">#17607</a>)</li> <li>ref(solidstart): Adjust event mechanism in withServerActionInstrumentation (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17637" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17637/hovercard">#17637</a>)</li> <li>ref(sveltekit): Adjust <code>mechanism</code> of error events (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17646" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17646/hovercard">#17646</a>)</li> <li>ref(vue): Adjust mechanism in Vue error handler (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17647" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17647/hovercard">#17647</a>)</li> </ul> <br> <p>Released in <code>10.11.0</code>:</p> <ul> <li>ref(browser): Add more specific <code>mechanism.type</code> to errors captured by <code>httpClientIntegration</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17254" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17254/hovercard">#17254</a>)</li> <li>ref(browser): Set more descriptive <code>mechanism.type</code> in <code>browserApiErrorsIntergation</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17251" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17251/hovercard">#17251</a>)</li> <li>ref(core): Add <code>mechanism.type</code> to <code>trpcMiddleware</code> errors (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17287" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17287/hovercard">#17287</a>)</li> <li>ref(core): Add more specific event <code>mechanism</code>s and span origins to <code>openAiIntegration</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17288" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17288/hovercard">#17288</a>)</li> <li>ref(nestjs): Add <code>mechanism</code> to captured errors (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17312" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17312/hovercard">#17312</a>)</li> </ul> </details></li> </ul> <ul> <li><strong>feat(node) Ensure <code>prismaIntegration</code> works with Prisma 5 (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17595" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17595/hovercard">#17595</a>)</strong></li> </ul> <p>We used to require to pass in the v5 version of <code>@ prisma/instrumentation</code> into <code>prismaIntegration({ prismaInstrumentation: new PrismaInstrumentation() })</code>, if you wanted to get full instrumentation for Prisma v5. However, it turns out this does not work on v10 of the SDK anymore, because <code>@ prisma/instrumentation@5</code> requires OTEL v1.</p> <p>With this release, we dropped the requirement to configure anything to get v5 support of Prisma. You do not need to configure anything in the integration anymore, and can remove the dependency on <code>@ prisma/instrumentation@5</code> if you had it in your application. You only need to configure the <code>tracing</code> preview feature <a href="https://docs.sentry.io/platforms/javascript/guides/node/configuration/integrations/prisma/" rel="nofollow">according to our docs</a>.</p> <ul> <li><strong>feat(deps): Update OpenTelemetry dependencies (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17558" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17558/hovercard">#17558</a>)</strong> <ul> <li>@ opentelemetry/core bumped to ^2.1.0</li> <li>@ opentelemetry/context-async-hooks bumped to ^2.1.0</li> <li>@ opentelemetry/resources bumped to ^2.1.0</li> <li>@ opentelemetry/sdk-trace-base bumped to ^2.1.0</li> <li>@ opentelemetry/semantic-conventions bumped to ^1.37.0</li> <li>@ opentelemetry/instrumentation bumped to ^0.204.0</li> <li>@ opentelemetry/instrumentation-http bumped to ^0.204.0</li> <li>@ opentelemetry/instrumentation-amqplib bumped to ^0.51.0</li> <li>@ opentelemetry/instrumentation-aws-sdk bumped to ^0.59.0</li> <li>@ opentelemetry/instrumentation-connect bumped to ^0.48.0</li> <li>@ opentelemetry/instrumentation-dataloader bumped to ^0.22.0</li> <li>@ opentelemetry/instrumentation-express bumped to ^0.53.0</li> <li>@ opentelemetry/instrumentation-fs bumped from to ^0.24.0</li> <li>@ opentelemetry/instrumentation-generic-pool bumped to ^0.48.0</li> <li>@ opentelemetry/instrumentation-graphql bumped to ^0.52.0</li> <li>@ opentelemetry/instrumentation-hapi bumped to ^0.51.0</li> <li>@ opentelemetry/instrumentation-ioredis bumped to ^0.52.0</li> <li>@ opentelemetry/instrumentation-kafkajs bumped to ^0.14.0</li> <li>@ opentelemetry/instrumentation-knex bumped to ^0.49.0</li> <li>@ opentelemetry/instrumentation-koa bumped to ^0.52.0</li> <li>@ opentelemetry/instrumentation-lru-memoizer bumped to ^0.49.0</li> <li>@ opentelemetry/instrumentation-mongodb bumped from to ^0.57.0</li> <li>@ opentelemetry/instrumentation-mongoose bumped from to ^0.51.0</li> <li>@ opentelemetry/instrumentation-mysql bumped to ^0.50.0</li> <li>@ opentelemetry/instrumentation-mysql2 bumped to ^0.51.0</li> <li>@ opentelemetry/instrumentation-nestjs-core bumped to ^0.50.0</li> <li>@ opentelemetry/instrumentation-pg bumped to ^0.57.0</li> <li>@ opentelemetry/instrumentation-redis bumped to ^0.53.0</li> <li>@ opentelemetry/instrumentation-undici bumped to ^0.15.0</li> <li>@ prisma/instrumentation bumped to 6.15.0</li> </ul> </li> </ul> <h3>Other Changes</h3> <ul> <li>feat(browser): Add timing and status atttributes to resource spans (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17562" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17562/hovercard">#17562</a>)</li> <li>feat(cloudflare,vercel-edge): Add support for Anthropic AI instrumentation (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17571" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17571/hovercard">#17571</a>)</li> <li>feat(core): Add Consola integration (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17435" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17435/hovercard">#17435</a>)</li> <li>feat(deps): Update OpenTelemetry dependencies (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17569" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17569/hovercard">#17569</a>)</li> <li>feat(core): Export <code>TracesSamplerSamplingContext</code> type (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17523" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17523/hovercard">#17523</a>)</li> <li>feat(deno): Add OpenTelemetry support and vercelAI integration (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17445" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17445/hovercard">#17445</a>)</li> <li>feat(node-core): Remove experimental note from winston api (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17626" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17626/hovercard">#17626</a>)</li> <li>feat(node): Ensure <code>prismaIntegration</code> works with Prisma v5 (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17595" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17595/hovercard">#17595</a>)</li> <li>feat(node): Tidy existing ESM loader hook (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17566" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17566/hovercard">#17566</a>)</li> <li>feat(sveltekit): Align build time options with shared type (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17413" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17413/hovercard">#17413</a>)</li> <li>fix(core): Fix error handling when sending envelopes (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17662" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17662/hovercard">#17662</a>)</li> <li>fix(browser): Always start navigation as root span (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17648" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17648/hovercard">#17648</a>)</li> <li>fix(browser): Ensure propagated <code>parentSpanId</code> stays consistent during trace in TwP mode (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17526" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17526/hovercard">#17526</a>)</li> <li>fix(cloudflare): Initialize once per workflow run and preserve scope for <code>step.do</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17582" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17582/hovercard">#17582</a>)</li> <li>fix(nextjs): Add edge polyfills for nextjs-13 in dev mode (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17488" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17488/hovercard">#17488</a>)</li> <li>fix(nitro): Support nested <code>_platform</code> properties in Nitro 2.11.7+ (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17596" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17596/hovercard">#17596</a>)</li> <li>fix(node): Preserve synchronous return behavior for streamText and other methods for AI (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17580" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17580/hovercard">#17580</a>)</li> <li>ref(node): Inline types imported from <code>shimmer</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17597" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17597/hovercard">#17597</a>) - ref(nuxt): Add and adjust <code>mechanism.type</code> in error events (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17599" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17599/hovercard">#17599</a>)</li> <li>ref(browser): Improve <code>fetchTransport</code> error handling (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17661" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17661/hovercard">#17661</a>)</li> </ul> <details> <summary> <strong>Internal Changes</strong> </summary> <ul> <li>chore: Add changelog note about mechanism changes (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17632" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17632/hovercard">#17632</a>)</li> <li>chore(aws): Update README.md (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17601" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17601/hovercard">#17601</a>)</li> <li>chore(deps): bump hono from 4.7.10 to 4.9.7 in /dev-packages/e2e-tests/test-applications/cloudflare-hono (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17630" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17630/hovercard">#17630</a>)</li> <li>chore(deps): bump next from 14.2.25 to 14.2.32 in /dev-packages/e2e-tests/test-applications/nextjs-app-dir (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17627" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17627/hovercard">#17627</a>)</li> <li>chore(deps): bump next from 14.2.25 to 14.2.32 in /dev-packages/e2e-tests/test-applications/nextjs-pages-dir (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17620" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17620/hovercard">#17620</a>)</li> <li>chore(deps): bump next from 14.2.29 to 14.2.32 in /dev-packages/e2e-tests/test-applications/nextjs-orpc (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17494" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17494/hovercard">#17494</a>)</li> <li>chore(deps): bump next from 14.2.30 to 14.2.32 in /dev-packages/e2e-tests/test-applications/nextjs-14 (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17628" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17628/hovercard">#17628</a>)</li> <li>chore(repo): Rename <code>.claude/settings.local.json</code> to <code>.claude/settings.json</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17591" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17591/hovercard">#17591</a>)</li> <li>docs(issue-template): Add note about prioritization (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17590" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17590/hovercard">#17590</a>)</li> <li>ref(core): Streamline event processor handling (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17634" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17634/hovercard">#17634</a>)</li> <li>test(angular): Bump TS version to 5.9.0 in Angular 20 e2e test (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17605" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17605/hovercard">#17605</a>)</li> <li>test(nextjs): Remove Next 13 and pin Next 14 canary and latest tests (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17577" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17577/hovercard">#17577</a>)</li> <li>test(react-router): Unflake <code>flushIfServerless</code> test (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17610" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17610/hovercard">#17610</a>)</li> </ul> </details> <h2>Bundle size 📦</h2> <table> <thead> <tr> <th>Path</th> <th>Size</th> </tr> </thead> <tbody> <tr> <td>@ sentry/browser</td> <td>23.59 KB</td> </tr> <tr> <td>@ sentry/browser - with treeshaking flags</td> <td>22.19 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing)</td> <td>39.21 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay)</td> <td>76.69 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay) - with treeshaking flags</td> <td>66.64 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay with Canvas)</td> <td>81.24 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay, Feedback)</td> <td>93.16 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Feedback)</td> <td>39.92 KB</td> </tr> <tr> <td>@ sentry/browser (incl. sendFeedback)</td> <td>28.13 KB</td> </tr> <tr> <td>@ sentry/browser (incl. FeedbackAsync)</td> <td>32.96 KB</td> </tr> <tr> <td>@ sentry/react</td> <td>25.27 KB</td> </tr> <tr> <td>@ sentry/react (incl. Tracing)</td> <td>41.18 KB</td> </tr> <tr> <td>@ sentry/vue</td> <td>27.97 KB</td> </tr> <tr> <td>@ sentry/vue (incl. Tracing)</td> <td>40.99 KB</td> </tr> <tr> <td>@ sentry/svelte</td> <td>23.62 KB</td> </tr> <tr> <td>CDN Bundle</td> <td>25.13 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing)</td> <td>39.11 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay)</td> <td>74.48 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay, Feedback)</td> <td>79.86 KB</td> </tr> <tr> <td>CDN Bundle - uncompressed</td> <td>73.41 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing) - uncompressed</td> <td>115.73 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay) - uncompressed</td> <td>228.13 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed</td> <td>240.59 KB</td> </tr> <tr> <td>@ sentry/nextjs (client)</td> <td>43.12 KB</td> </tr> <tr> <td>@ sentry/sveltekit (client)</td> <td>39.64 KB</td> </tr> <tr> <td>@ sentry/node-core</td> <td>48.69 KB</td> </tr> <tr> <td>@ sentry/node</td> <td>147.6 KB</td> </tr> <tr> <td>@ sentry/node - without tracing</td> <td>89.6 KB</td> </tr> <tr> <td>@ sentry/aws-serverless</td> <td>102.73 KB</td> </tr> </tbody> </table> </li> <li> <b>10.11.0</b> - <a href="https://redirect.github.com/getsentry/sentry-javascript/releases/tag/10.11.0">2025-09-09</a></br><h3>Important Changes</h3> <ul> <li> <p><strong>feat(aws): Add experimental AWS Lambda extension for tunnelling events (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17525" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17525/hovercard">#17525</a>)</strong></p> <p>This release adds an experimental Sentry Lambda extension to the existing Sentry Lambda layer. Sentry events are now tunneled through the extension and then forwarded to Sentry. This has the benefit of reducing the request processing time.</p> <p>To enable it, set <code>_experiments.enableLambdaExtension</code> in your Sentry config like this:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Sentry.init({ dsn: '<YOUR_DSN>', _experiments: { enableLambdaExtension: true, }, });"><pre><span class="pl-v">Sentry</span><span class="pl-kos">.</span><span class="pl-en">init</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">dsn</span>: <span class="pl-s">'<YOUR_DSN>'</span><span class="pl-kos">,</span> <span class="pl-c1">_experiments</span>: <span class="pl-kos">{</span> <span class="pl-c1">enableLambdaExtension</span>: <span class="pl-c1">true</span><span class="pl-kos">,</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> </li> </ul> <h3>Other Changes</h3> <ul> <li>feat(core): Add replay id to logs (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17563" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17563/hovercard">#17563</a>)</li> <li>feat(core): Improve error handling for Anthropic AI instrumentation (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17535" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17535/hovercard">#17535</a>)</li> <li>feat(deps): bump @ opentelemetry/instrumentation-ioredis from 0.51.0 to 0.52.0 (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17557" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17557/hovercard">#17557</a>)</li> <li>feat(node): Add incoming request headers as OTel span attributes (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17475" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17475/hovercard">#17475</a>)</li> <li>fix(astro): Ensure traces are correctly propagated for static routes (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17536" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17536/hovercard">#17536</a>)</li> <li>fix(react): Remove <code>handleExistingNavigation</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17534" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17534/hovercard">#17534</a>)</li> <li>ref(browser): Add more specific <code>mechanism.type</code> to errors captured by <code>httpClientIntegration</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17254" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17254/hovercard">#17254</a>)</li> <li>ref(browser): Set more descriptive <code>mechanism.type</code> in <code>browserApiErrorsIntergation</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17251" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17251/hovercard">#17251</a>)</li> <li>ref(core): Add <code>mechanism.type</code> to <code>trpcMiddleware</code> errors (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17287" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17287/hovercard">#17287</a>)</li> <li>ref(core): Add more specific event <code>mechanism</code>s and span origins to <code>openAiIntegration</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17288" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17288/hovercard">#17288</a>)</li> <li>ref(nestjs): Add <code>mechanism</code> to captured errors (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17312" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17312/hovercard">#17312</a>)</li> </ul> <details> <summary> <strong>Internal Changes</strong> </summary> <ul> <li>chore: Use proper <code>test-utils</code> dependency in workspace (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17538" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17538/hovercard">#17538</a>)</li> <li>chore(test): Remove <code>geist</code> font (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17541" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17541/hovercard">#17541</a>)</li> <li>ci: Check for stable lockfile (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17552" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17552/hovercard">#17552</a>)</li> <li>ci: Fix running of only changed E2E tests (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17551" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17551/hovercard">#17551</a>)</li> <li>ci: Remove project automation workflow (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17508" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17508/hovercard">#17508</a>)</li> <li>test(node-integration-tests): pin [email protected] to fix test fails (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17542" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17542/hovercard">#17542</a>)</li> </ul> </details> <h2>Bundle size 📦</h2> <table> <thead> <tr> <th>Path</th> <th>Size</th> </tr> </thead> <tbody> <tr> <td>@ sentry/browser</td> <td>23.61 KB</td> </tr> <tr> <td>@ sentry/browser - with treeshaking flags</td> <td>22.22 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing)</td> <td>39.2 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay)</td> <td>76.66 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay) - with treeshaking flags</td> <td>66.66 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay with Canvas)</td> <td>81.23 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay, Feedback)</td> <td>93.15 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Feedback)</td> <td>39.95 KB</td> </tr> <tr> <td>@ sentry/browser (incl. sendFeedback)</td> <td>28.15 KB</td> </tr> <tr> <td>@ sentry/browser (incl. FeedbackAsync)</td> <td>32.98 KB</td> </tr> <tr> <td>@ sentry/react</td> <td>25.29 KB</td> </tr> <tr> <td>@ sentry/react (incl. Tracing)</td> <td>41.12 KB</td> </tr> <tr> <td>@ sentry/vue</td> <td>27.99 KB</td> </tr> <tr> <td>@ sentry/vue (incl. Tracing)</td> <td>40.97 KB</td> </tr> <tr> <td>@ sentry/svelte</td> <td>23.63 KB</td> </tr> <tr> <td>CDN Bundle</td> <td>25.16 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing)</td> <td>39.07 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay)</td> <td>74.5 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay, Feedback)</td> <td>79.83 KB</td> </tr> <tr> <td>CDN Bundle - uncompressed</td> <td>73.44 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing) - uncompressed</td> <td>115.53 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay) - uncompressed</td> <td>227.93 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed</td> <td>240.39 KB</td> </tr> <tr> <td>@ sentry/nextjs (client)</td> <td>43.11 KB</td> </tr> <tr> <td>@ sentry/sveltekit (client)</td> <td>39.63 KB</td> </tr> <tr> <td>@ sentry/node-core</td> <td>48.66 KB</td> </tr> <tr> <td>@ sentry/node</td> <td>148.65 KB</td> </tr> <tr> <td>@ sentry/node - without tracing</td> <td>90.07 KB</td> </tr> <tr> <td>@ sentry/aws-serverless</td> <td>103.24 KB</td> </tr> </tbody> </table> </li> <li> <b>10.10.0</b> - <a href="https://redirect.github.com/getsentry/sentry-javascript/releases/tag/10.10.0">2025-09-04</a></br><h3>Important Changes</h3> <ul> <li><strong>feat(browser): Add support for <code>propagateTraceparent</code> SDK option (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17509" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17509/hovercard">#17509</a>)</strong></li> </ul> <p>Adds support for a new browser SDK init option, <code>propagateTraceparent</code> for attaching a W3C compliant traceparent header to outgoing fetch and XHR requests, in addition to sentry-trace and baggage headers. More details can be found <a href="https://develop.sentry.dev/sdk/telemetry/traces/#propagatetraceparent" rel="nofollow">here</a>.</p> <ul> <li><strong>feat(core): Add tool calls attributes for Anthropic AI (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17478" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17478/hovercard">#17478</a>)</strong></li> </ul> <p>Adds missing tool call attributes, we add gen_ai.response.tool_calls attribute for Anthropic AI, supporting both streaming and non-streaming requests.</p> <ul> <li><strong>feat(nextjs): Use compiler hook for uploading turbopack sourcemaps (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17352" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17352/hovercard">#17352</a>)</strong></li> </ul> <p>Adds a new <em>experimental</em> flag <code>_experimental.useRunAfterProductionCompileHook</code> to <code>withSentryConfig</code> for automatic source maps uploads when building a Next.js app with <code>next build --turbopack</code>.<br> When set we:</p> <ul> <li>Automatically enable source map generation for turbopack client files (if not explicitly disabled)</li> <li>Upload generated source maps to Sentry at the end of the build by leveraging <a href="https://nextjs.org/docs/architecture/nextjs-compiler#runafterproductioncompile" rel="nofollow">a Next.js compiler hook</a>.</li> </ul> <h3>Other Changes</h3> <ul> <li>feat(feedback): Add more labels so people can configure Highlight and Hide labels (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17513" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17513/hovercard">#17513</a>)</li> <li>fix(node): Add <code>origin</code> for OpenAI spans & test auto instrumentation (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17519" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17519/hovercard">#17519</a>)</li> </ul> <h2>Bundle size 📦</h2> <table> <thead> <tr> <th>Path</th> <th>Size</th> </tr> </thead> <tbody> <tr> <td>@ sentry/browser</td> <td>23.59 KB</td> </tr> <tr> <td>@ sentry/browser - with treeshaking flags</td> <td>22.2 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing)</td> <td>39.19 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay)</td> <td>76.63 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay) - with treeshaking flags</td> <td>66.64 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay with Canvas)</td> <td>81.2 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay, Feedback)</td> <td>93.13 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Feedback)</td> <td>39.93 KB</td> </tr> <tr> <td>@ sentry/browser (incl. sendFeedback)</td> <td>28.13 KB</td> </tr> <tr> <td>@ sentry/browser (incl. FeedbackAsync)</td> <td>32.96 KB</td> </tr> <tr> <td>@ sentry/react</td> <td>25.27 KB</td> </tr> <tr> <td>@ sentry/react (incl. Tracing)</td> <td>41.11 KB</td> </tr> <tr> <td>@ sentry/vue</td> <td>27.97 KB</td> </tr> <tr> <td>@ sentry/vue (incl. Tracing)</td> <td>40.95 KB</td> </tr> <tr> <td>@ sentry/svelte</td> <td>23.62 KB</td> </tr> <tr> <td>CDN Bundle</td> <td>25.14 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing)</td> <td>39.05 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay)</td> <td>74.48 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay, Feedback)</td> <td>79.82 KB</td> </tr> <tr> <td>CDN Bundle - uncompressed</td> <td>73.4 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing) - uncompressed</td> <td>115.49 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay) - uncompressed</td> <td>227.88 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed</td> <td>240.35 KB</td> </tr> <tr> <td>@ sentry/nextjs (client)</td> <td>43.08 KB</td> </tr> <tr> <td>@ sentry/sveltekit (client)</td> <td>39.62 KB</td> </tr> <tr> <td>@ sentry/node-core</td> <td>48.49 KB</td> </tr> <tr> <td>@ sentry/node</td> <td>147.1 KB</td> </tr> <tr> <td>@ sentry/node - without tracing</td> <td>90.07 KB</td> </tr> <tr> <td>@ sentry/aws-serverless</td> <td>103.06 KB</td> </tr> </tbody> </table> </li> <li> <b>10.9.0</b> - <a href="https://redirect.github.com/getsentry/sentry-javascript/releases/tag/10.9.0">2025-09-03</a></br><h3>Important Changes</h3> <ul> <li><strong>feat(node): Update <code>httpIntegration</code> handling of incoming requests (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17371" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17371/hovercard">#17371</a>)</strong></li> </ul> <p>This version updates the handling of the Node SDK of incoming requests. Instead of relying on @ opentelemetry/instrumentation-http, we now handle incoming request instrumentation internally, ensuring that we can optimize performance as much as possible and avoid interop problems.</p> <p>This change should not affect you, unless you're relying on very in-depth implementation details. Importantly, this also drops the <code>_experimentalConfig</code> option of the integration - this will no longer do anything.<br> Finally, you can still pass <code>instrumentation.{requestHook,responseHook,applyCustomAttributesOnSpan}</code> options, but they are deprecated and will be removed in v11. Instead, you can use the new <code>incomingRequestSpanHook</code> configuration option if you want to adjust the incoming request span.</p> <h3>Other Changes</h3> <ul> <li>feat(browser): Add replay.feedback CDN bundle (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17496" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17496/hovercard">#17496</a>)</li> <li>feat(browser): Export <code>sendFeedback</code> from CDN bundles (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17495" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17495/hovercard">#17495</a>)</li> <li>fix(astro): Ensure span name from <code>beforeStartSpan</code> isn't overwritten (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17500" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17500/hovercard">#17500</a>)</li> <li>fix(browser): Ensure source is set correctly when updating span name in-place in <code>beforeStartSpan</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17501" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17501/hovercard">#17501</a>)</li> <li>fix(core): Only set template attributes on logs if parameters exist (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17480" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17480/hovercard">#17480</a>)</li> <li>fix(nextjs): Fix parameterization for root catchall routes (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17489" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17489/hovercard">#17489</a>)</li> <li>fix(node-core): Shut down OTel TraceProvider when calling <code>Sentry.close()</code> (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17499" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17499/hovercard">#17499</a>)</li> </ul> <details> <summary> <strong>Internal Changes</strong> </summary> <ul> <li>chore: Add <code>changelog</code> script back to package.json (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17517" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17517/hovercard">#17517</a>)</li> <li>chore: Ensure prettier is run on all files (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17497" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17497/hovercard">#17497</a>)</li> <li>chore: Ignore prettier commit for git blame (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17498" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17498/hovercard">#17498</a>)</li> <li>chore: Remove experimental from Nuxt SDK package description (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17483" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17483/hovercard">#17483</a>)</li> <li>ci: Capture overhead in node app (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17420" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17420/hovercard">#17420</a>)</li> <li>ci: Ensure we fail on cancelled jobs (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17506" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17506/hovercard">#17506</a>)</li> <li>ci(deps): bump actions/checkout from 4 to 5 (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17505" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17505/hovercard">#17505</a>)</li> <li>ci(deps): bump actions/create-github-app-token from 2.0.6 to 2.1.1 (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17504" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17504/hovercard">#17504</a>)</li> <li>test(aws): Improve reliability on CI (<a href="https://redirect.github.com/getsentry/sentry-javascript/pull/17502" data-hovercard-type="pull_request" data-hovercard-url="/getsentry/sentry-javascript/pull/17502/hovercard">#17502</a>)</li> </ul> </details> <h2>Bundle size 📦</h2> <table> <thead> <tr> <th>Path</th> <th>Size</th> </tr> </thead> <tbody> <tr> <td>@ sentry/browser</td> <td>23.59 KB</td> </tr> <tr> <td>@ sentry/browser - with treeshaking flags</td> <td>22.2 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing)</td> <td>38.93 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay)</td> <td>76.4 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay) - with treeshaking flags</td> <td>66.43 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay with Canvas)</td> <td>80.97 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Tracing, Replay, Feedback)</td> <td>92.81 KB</td> </tr> <tr> <td>@ sentry/browser (incl. Feedback)</td> <td>39.88 KB</td> </tr> <tr> <td>@ sentry/browser (incl. sendFeedback)</td> <td>28.13 KB</td> </tr> <tr> <td>@ sentry/browser (incl. FeedbackAsync)</td> <td>32.92 KB</td> </tr> <tr> <td>@ sentry/react</td> <td>25.27 KB</td> </tr> <tr> <td>@ sentry/react (incl. Tracing)</td> <td>40.91 KB</td> </tr> <tr> <td>@ sentry/vue</td> <td>27.97 KB</td> </tr> <tr> <td>@ sentry/vue (incl. Tracing)</td> <td>40.72 KB</td> </tr> <tr> <td>@ sentry/svelte</td> <td>23.62 KB</td> </tr> <tr> <td>CDN Bundle</td> <td>25.06 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing)</td> <td>38.82 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay)</td> <td>74.25 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay, Feedback)</td> <td>79.56 KB</td> </tr> <tr> <td>CDN Bundle - uncompressed</td> <td>73.2 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing) - uncompressed</td> <td>114.83 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay) - uncompressed</td> <td>227.23 KB</td> </tr> <tr> <td>CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed</td> <td>239.56 KB</td> </tr> <tr> <td>@ sentry/nextjs (client)</td> <td>42.86 KB</td> </tr> <tr> <td>@ sentry/sveltekit (client)</td> <td>39.38 KB</td> </tr> <tr> <td>@ sentry/node-core</td> <td>48.45 KB</td> </tr> <tr> <td>@ sentry/node</td> <td>146.74 KB</td> </tr> <tr> <td>@ sentry/node - without tracing</td> <td>90.02 KB</td> </tr> <tr> <td>@ sentry/aws-serverless</td> <td>103.01 KB</td> </tr> </tbody> </table> </li> <li> <b>10.8.0</b> - 2025-08-29 </li> <li> <b>10.7.0</b> - 2025-08-27 </li> <li> <b>10.6.0</b> - 2025-08-26 </li> <li> <b>10.5.0</b> - 2025-08-12 </li> <li> <b>10.4.0</b> - 2025-08-11 </li> <li> <b>10.3.0</b> - 2025-08-08 </li> <li> <b>10.2.0</b> - 2025-08-06 </li> <li> <b>10.1.0</b> - 2025-08-04 </li> <li> <b>10.0.0</b> - 2025-07-31 </li> <li> <b>10.0.0-beta.0</b> - 2025-07-30 </li> <li> <b>10.0.0-alpha.2</b> - 2025-07-24 </li> <li> <b>10.0.0-alpha.1</b> - 2025-07-21 </li> <li> <b>10.0.0-alpha.0</b> - 2025-07-21 </li> <li> <b>9.46.0</b> - 2025-08-13 </li> <li> <b>9.45.0</b> - 2025-08-08 </li> <li> <b>9.44.2</b> - 2025-08-04 </li> <li> <b>9.44.1</b> - 2025-08-04 </li> <li> <b>9.44.0</b> - 2025-07-31 </li> <li> <b>9.43.0</b> - 2025-07-29 </li> </ul> from <a href="https://redirect.github.com/getsentry/sentry-javascript/releases">@sentry/node GitHub release notes</a> </details> </details> --- > [!IMPORTANT] > > - **Warning:** This PR contains a major version upgrade, and may be a breaking change. > - Check the changes in this PR to ensure they won't cause issues with your project. > - This PR was automatically created by Snyk using the credentials of a real user. > - Max score is 1000. Note that the real score may have changed since the PR was raised. --- **Note:** _You are seeing this because you or someone else with access to this repository has authorized Snyk to open upgrade PRs._ **For more information:** <img src="https://api.segment.io/v1/pixel/track?data=eyJ3cml0ZUtleSI6InJyWmxZcEdHY2RyTHZsb0lYd0dUcVg4WkFRTnNCOUEwIiwiYW5vbnltb3VzSWQiOiIwYjlmNDY5NC1mMzkzLTQ0NDctOGI3NC02NWRjODdmYjI1ODkiLCJldmVudCI6IlBSIHZpZXdlZCIsInByb3BlcnRpZXMiOnsicHJJZCI6IjBiOWY0Njk0LWYzOTMtNDQ0Ny04Yjc0LTY1ZGM4N2ZiMjU4OSJ9fQ==" width="0" height="0"/> > - 🧐 [View latest project report](https://app.snyk.io/org/reisene/project/55e114f8-489e-4f14-b900-20574b041e59?utm_source=github-cloud-app&utm_medium=referral&page=upgrade-pr) > - 📜 [Customise PR templates](https://docs.snyk.io/scan-using-snyk/pull-requests/snyk-fix-pull-or-merge-requests/customize-pr-templates?utm_source=&utm_content=fix-pr-template) > - 🛠 [Adjust upgrade PR settings](https://app.snyk.io/org/reisene/project/55e114f8-489e-4f14-b900-20574b041e59/settings/integration?utm_source=github-cloud-app&utm_medium=referral&page=upgrade-pr) > - 🔕 [Ignore this dependency or unsubscribe from future upgrade PRs](https://app.snyk.io/org/reisene/project/55e114f8-489e-4f14-b900-20574b041e59/settings/integration?pkg=@sentry/node&utm_source=github-cloud-app&utm_medium=referral&page=upgrade-pr#auto-dep-upgrades) [//]: # 'snyk:metadata:{"breakingChangeRiskLevel":null,"FF_showPullRequestBreakingChanges":null,"FF_showPullRequestBreakingChangesWebSearch":null,"customTemplate":{"variablesUsed":[],"fieldsUsed":[]},"dependencies":[{"name":"@sentry/node","from":"9.43.0","to":"10.12.0"}],"env":"prod","hasFixes":true,"isBreakingChange":true,"isMajorUpgrade":true,"issuesToFix":["SNYK-JS-BRACEEXPANSION-9789073","SNYK-JS-BRACEEXPANSION-9789073"],"prId":"0b9f4694-f393-4447-8b74-65dc87fb2589","prPublicId":"0b9f4694-f393-4447-8b74-65dc87fb2589","packageManager":"npm","priorityScoreList":[57],"projectPublicId":"55e114f8-489e-4f14-b900-20574b041e59","projectUrl":"https://app.snyk.io/org/reisene/project/55e114f8-489e-4f14-b900-20574b041e59?utm_source=github-cloud-app&utm_medium=referral&page=upgrade-pr","prType":"upgrade","templateFieldSources":{"branchName":"default","commitMessage":"default","description":"default","title":"default"},"templateVariants":["priorityScore"],"type":"auto","upgrade":["SNYK-JS-BRACEEXPANSION-9789073","SNYK-JS-BRACEEXPANSION-9789073"],"upgradeInfo":{"versionsDiff":22,"publishedDate":"2025-09-16T15:02:23.181Z"},"vulns":["SNYK-JS-BRACEEXPANSION-9789073","SNYK-JS-BRACEEXPANSION-9789073"]}'
This PR fixes the usage of the SDK in v10 with Prisma v5.
We used to require/recommend that users manually installed
@prisma/instrumentation
v5 and passed this to ourprismaIntegration
like this:However, this no longer works in v10 because that version pulls in v1 of
@opentelemetry/sdk-trace-base
, which is no longer compatible in v10 of our SDK 😢So to fix this, this PR removes/deprecates the passing of
prismaInstrumentation
(this now no-ops). v5 is now supported out of the box!To make this work, some hacks and workarounds were necessary 😬 The problem is that v5 of the prisma instrumentation relies on manually creating span instances with specified ID and parent IDs. This is no longer possible in OTEL v2, as all these APIs are no longer exported 😞 (it was also weird from prisma to do this in the first place, and they no longer do this in v6 of the instrumentation).
To get this to work, we manually overwrite the
tracer._idGenerator
with a mock that returns the IDs we need, kind of making this work as expected again. Hopefully this will not break in the future, we'll see - our tests should at least show us if that ever breaks.While at this, I also re-wrote our integration tests to run in CJS and ESM properly and use the new test runner structure instead of manually calling yarn etc. in there.
Example trace before in v5 (without custom prismaInstrumentation, which broke at runtime):
https://sentry-sdks.sentry.io/explore/discover/trace/49e2095162e4bb571074e27653586643/?dataset=transactions&field=title&field=project&field=user.display&field=timestamp&name=All%20Errors&node=span-61995a9d80c6925f&project=4508330866769920&query=&queryDataset=transaction-like&sort=-timestamp&source=discover&statsPeriod=1h×tamp=1757575919&yAxis=count%28%29
Example trace with this PR:
https://sentry-sdks.sentry.io/explore/discover/trace/deaaa1990ba6204085779aa09888dc2c/?dataset=transactions&field=title&field=project&field=user.display&field=timestamp&fov=0%2C813.7861328125&name=All%20Errors&node=span-8eb41978be76824e&project=4508330866769920&query=&queryDataset=transaction-like&sort=-timestamp&source=discover&statsPeriod=1h×tamp=1757575780&yAxis=count%28%29