chore(deps): update JavaScript SDK to v10.17.0 #3280
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Bumps packages/flutter/scripts/update-js.sh from 10.6.0 to 10.17.0.
Auto-generated by a dependency updater.
Changelog
10.17.0
Important Changes
feat(nuxt): Implement server middleware instrumentation (#17796)
This release introduces instrumentation for Nuxt middleware, ensuring that all middleware handlers are automatically wrapped with tracing and error reporting functionality.
fix(aws-serverless): Take
http_proxyinto account when choosinguseLayerExtensiondefault (#17817)The default setting for
useLayerExtensionnow considers thehttp_proxyenvironment variable.When
http_proxyis set,useLayerExtensionwill be off by default.If you use a
http_proxybut would still like to make use of the Sentry Lambda extension, exemptlocalhostin ano_proxyenvironment variable.Other Changes
beforeSendSpan(#17815)Internal Changes
10.16.0
replay_is_bufferingflag (#17752)instrumentAnthropicAiClientbreaking MessageStream api (#17754)Internal Changes
publish_releasecommand (#17797)import-in-the-middlewhen building the Lambda layer (#17780)import-in-the-middle1.14.2due tovercel/nftincompatibility (#17777)" (#17784)import-in-the-middle1.14.2due tovercel/nftincompatibility (#17777)10.15.0
Important Changes
feat(cloudflare): Add honoIntegration with error-filtering function (#17743)
This release adds a
honoIntegrationtosentry/cloudflare, which exposes ashouldHandleErrorfunction that lets you define which errors inonErrorshould be captured.By default, Sentry captures exceptions with
error.status >= 500 || error.status <= 299.The integration is added by default, and it's possible to modify this behavior like this:
feat(node): Add instrumentation for hono handler (#17428)
This PR enhances the Hono integration by adding comprehensive handler instrumentation, error handling capabilities.
feat(aws): Enable Lambda extension by default when using the Lamba layer (#17684)
feat(browser): Add
setActiveSpanInBrowserto set an active span in the browser (#17714)This PR adds a feature to the browser SDKs only: Making an inactive span active. We do this to enable use cases where having a span only being active in the callback is not practical.
Other Changes
0andundefinedresource timing values (#17751)Internal Changes
typescript-eslint/no-unnecessary-type-assertionrule (#17728)es2020everywhere (#17709)Work in this release was contributed by Karibash. Thank you for your contribution!
10.14.0
Important Changes
feat(cloudflare,vercel-edge): Add support for Google Gen AI instrumentation (#17723)
The SDK now supports manually instrumenting Google's Gen AI operations in Cloudflare Workers and Vercel Edge Runtime environments, providing insights into your AI operations. You can use
const wrappedClient = Sentry.instrumentGoogleGenAIClient(genAiClient)to get an instrumented client.Other Changes
WeakRefwhen storing it on spans (#17712)Internal Changes
10.13.0
Important Changes
feat(browser): Add option to explicitly end pageload span via
reportPageLoaded()(#17697)With this release you can take manual control of ending the pageload span. Usually this span is ended automatically by the SDK, based on a period of inactivity after the initial page was loaded in the browser. If you want full control over the pageload duration, you can tell Sentry, when your page was fully loaded:
Note that if
Sentry.reportPageLoaded()is not called within 30 seconds of the initial pageload (or whatever value thefinalTimeoutoption is set to), the pageload span will be ended automatically.feat(core,node): Add instrumentation for
GoogleGenAI(#17625)The SDK now automatically instruments the
google/genaipackage to provide insights into your AI operations.feat(nextjs): Promote
useRunAfterProductionCompileHookto non-experimental build option (#17721)The
useRunAfterProductionCompileHookoption is no longer experimental and is now a stable build option for Next.js projects.feat(nextjs): Use
afterProductionCompilehook for webpack builds (#17655)Next.js projects using webpack can opt-in to use the
useRunAfterProductionCompileHookhook for source map uploads.feat(nextjs): Flip default value for
useRunAfterProductionCompileHookfor Turbopack builds (#17722)The
useRunAfterProductionCompileHookoption is now enabled by default for Turbopack builds, enabling automated source map uploads.feat(node): Do not drop 300 and 304 status codes by default (#17686)
HTTP transactions with 300 and 304 status codes are now captured by default, providing better visibility into redirect and caching behavior.
Other Changes
onSuccesstohandleCallbackErrors(#17679)consoleLoggingIntegration(#17703)oscontext (#17720)thirdPartyErrorFilterIntegration(#17693)thiscontext for vercel AI instrumentation (#17681)Internal Changes
reportPageLoaded(#17724)getTestMatrix(#17673)SyncPromisewhere not needed (#17641)ignoreSpans(#17692)module_metadataassignment and cleanup functions (#17696)HandleDocumentRequestFunction(#17680)Work in this release was contributed by Olexandr88. Thank you for your contribution!
10.12.0
Important Changes
ref: Add and Adjust error event
mechanismvaluesThis release includes a variety of changes aimed at setting the
mechanismfield on errors captured automatically by the Sentry SDKs. The intention 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.Relevant PRs
Released in
10.12.0:mechanismon error events captured by astro middleware (#17613)mechanismof errors captured in Bun.serve (#17616)mechanismsand durable object origin (#17618)mechanismincaptureConsoleIntegration(#17633)mechanism(#17622)linkedErrorsmechanism logic (#17600)mechanismof errors caught byglobalHandlersIntegration(#17635)mechanisms (#17543)mechanismto cron instrumentations (#17544)mechanism.typeto worker thread errors fromchildProcessIntegration(#17578)mechanismofonUnhandledRejectionandonUnhandledExceptionintegrations (#17636)mechanism.typein error events (#17599)reactErrorHandlerand adjust mechanism inErrorBoundary(#17602)captureRemixServerException(#17629)replayIntegrationin debug mode (#17606)mechanismto error captured bywithSentryErrorBoundary(#17607)mechanismof error events (#17646)Released in
10.11.0:mechanism.typeto errors captured byhttpClientIntegration(#17254)mechanism.typeinbrowserApiErrorsIntergation(#17251)mechanism.typetotrpcMiddlewareerrors (#17287)mechanisms and span origins toopenAiIntegration(#17288)mechanismto captured errors (#17312)prismaIntegrationworks with Prisma 5 (#17595)We used to require to pass in the v5 version of
prisma/instrumentationintoprismaIntegration({ prismaInstrumentation: new PrismaInstrumentation() }), if you wanted to get full instrumentation for Prisma v5. However, it turns out this does not work on v10 of the SDK anymore, becauseprisma/instrumentation5requires OTEL v1.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
prisma/instrumentation5if you had it in your application. You only need to configure thetracingpreview feature according to our docs.Other Changes
TracesSamplerSamplingContexttype (#17523)prismaIntegrationworks with Prisma v5 (#17595)parentSpanIdstays consistent during trace in TwP mode (#17526)step.do(#17582)_platformproperties in Nitro 2.11.7+ (#17596)shimmer(#17597) - ref(nuxt): Add and adjustmechanism.typein error events (#17599)fetchTransporterror handling (#17661)Internal Changes
.claude/settings.local.jsonto.claude/settings.json(#17591)flushIfServerlesstest (#17610)10.11.0
Important Changes
feat(aws): Add experimental AWS Lambda extension for tunnelling events (#17525)
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.
To enable it, set
_experiments.enableLambdaExtensionin your Sentry config like this:Other Changes
handleExistingNavigation(#17534)mechanism.typeto errors captured byhttpClientIntegration(#17254)mechanism.typeinbrowserApiErrorsIntergation(#17251)mechanism.typetotrpcMiddlewareerrors (#17287)mechanisms and span origins toopenAiIntegration(#17288)mechanismto captured errors (#17312)Internal Changes
test-utilsdependency in workspace (#17538)geistfont (#17541)10.10.0
Important Changes
propagateTraceparentSDK option (#17509)Adds support for a new browser SDK init option,
propagateTraceparentfor 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 here.Adds missing tool call attributes, we add gen_ai.response.tool_calls attribute for Anthropic AI, supporting both streaming and non-streaming requests.
Adds a new experimental flag
_experimental.useRunAfterProductionCompileHooktowithSentryConfigfor automatic source maps uploads when building a Next.js app withnext build --turbopack.When set we:
Other Changes
originfor OpenAI spans & test auto instrumentation (#17519)10.9.0
Important Changes
httpIntegrationhandling of incoming requests (#17371)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.
This change should not affect you, unless you're relying on very in-depth implementation details. Importantly, this also drops the
_experimentalConfigoption of the integration - this will no longer do anything.Finally, you can still pass
instrumentation.{requestHook,responseHook,applyCustomAttributesOnSpan}options, but they are deprecated and will be removed in v11. Instead, you can use the newincomingRequestSpanHookconfiguration option if you want to adjust the incoming request span.Other Changes
sendFeedbackfrom CDN bundles (#17495)beforeStartSpanisn't overwritten (#17500)beforeStartSpan(#17501)Sentry.close()(#17499)Internal Changes
changelogscript back to package.json (#17517)10.8.0
Important Changes
feat(sveltekit): Add Compatibility for builtin SvelteKit Tracing (#17423)
This release makes the
sentry/sveltekitSDK compatible with SvelteKit's native observability support introduced in SvelteKit version2.31.0.If you enable both, instrumentation and tracing, the SDK will now initialize early enough to set up additional instrumentation like database queries and it will pick up spans emitted from SvelteKit.
We will follow up with docs how to set up the SDK soon.
For now, If you're on SvelteKit version
2.31.0or newer, you can easily opt into the new feature:Enable experimental tracing and instrumentation support in
svelte.config.js:Move your
Sentry.init()call fromsrc/hooks.server.(js|ts)to the newinstrumentation.server.(js|ts)file:The rest of your Sentry config in
hooks.server.ts(sentryHandleandhandleErrorWithSentry) should stay the same.If you prefer to stay on the hooks-file based config for now, the SDK will continue to work as previously.
Thanks to the Svelte team and elliott-with-the-longest-name-on-github for implementing observability support and for reviewing our PR!
Other Changes
Internal Changes
10.7.0
Important Changes
instrumentPrototypeMethodsoption to instrument RPC methods for DurableObjects (#17424)By default,
Sentry.instrumentDurableObjectWithSentrywill not wrap any RPC methods on the prototype. To enable wrapping for RPC methods, setinstrumentPrototypeMethodstotrueor, if performance is a concern, a list of only the methods you want to instrument:Other Changes
requestAnimationFramefor canvas snapshots (#17380)Internal Changes