Important Changes
-
feat(hono): Add support for the Deno runtime (#21450)
@sentry/hononow supports the Deno runtime via a new@sentry/hono/denoentry point.
Install@sentry/denoas a peer dependency and initialize Sentry through thesentry()middleware:import { Hono } from 'hono'; import { sentry } from '@sentry/hono/deno'; const app = new Hono(); app.use( sentry(app, { dsn: '__DSN__', // or Deno.env.get('SENTRY_DSN') tracesSampleRate: 1.0, }), ); Deno.serve(app.fetch);
-
feat(core): Extract objects as structured logs in
consoleLoggingIntegration(#21385)The
consoleLoggingIntegrationnow extracts structured log attributes when the first argument is a plain object.// Object keys become log attributes console.log({ userId: 123, action: 'login' }, 'User logged in'); // → attributes: { userId: 123, action: "login" } // Non-object first args use template + parameters (unchanged) console.log('Hello', 'world', 123); // → sentry.message.template: "Hello {} {}"
-
feat(react-router): Stabilize the instrumentation API (#21470)
React Router's instrumentation API is now stable — the
@experimentalmarkers have been removed fromcreateSentryServerInstrumentation,createSentryClientInstrumentation, and the related helpers and types.
The manual server wrapperswrapServerLoaderandwrapServerActionare now deprecated in favor of it. Exportinstrumentations = [Sentry.createSentryServerInstrumentation()]from yourentry.server.tsxto instrument all loaders and actions without wrapping them individually.
Other Changes
- feat(hono): Add HTTP connection info to server spans (#21408)
- feat(node-core): Attach log message and fields to pino error events (#21422)
- feat(react-router): Always build client instrumentation and deprecate
useInstrumentationAPI(#21432) - feat(react-router): Rename client navigation roots from the route pattern (#21463)
- fix(astro): Resolve middleware export types (#21414)
- fix(browser): Ignore
__sentry_wrapped__inherited fromFunction.prototype(#21506) - fix(core): Avoid double counting cached input tokens for Vercel AI SDK v6 (#21488)
- fix(core): Keep
safeJoinside-effect-free for DOM elements (#21356) - fix(deno): Use correct paths for
moduleandtypesfields inpackage.json(#21449) - fix(nextjs): Mark redirect server actions as
okinstead ofinternal_error(#21521) - fix(react-router): Mark instrumentation API active on invocation (#21420)
- fix(redis): Bring span attributes into alignment with conventions
- fix(sveltekit): Add
defaultexports condition (#21472) - fix(tanstackstart-react): Preserve middleware context types (#21441)
- perf(core): Reuse unchanged Vercel AI messages JSON
Work in this release was contributed by @archievi, @AyaanFaisal21, @itosa-kazu, and @bkchr. Thank you for your contributions!
Internal Changes
22.7.5 (#21527)
SENTRY_BUILD_PRESERVE_MODULES env check from rollup configs (#21487)
Bundle size 📦
| Path | Size |
|---|---|
| @sentry/browser | 26.76 KB |
| @sentry/browser - with treeshaking flags | 25.23 KB |
| @sentry/browser (incl. Tracing) | 44.63 KB |
| @sentry/browser (incl. Tracing + Span Streaming) | 46.82 KB |
| @sentry/browser (incl. Tracing, Profiling) | 49.32 KB |
| @sentry/browser (incl. Tracing, Replay) | 82.93 KB |
| @sentry/browser (incl. Tracing, Replay) - with treeshaking flags | 72.78 KB |
| @sentry/browser (incl. Tracing, Replay with Canvas) | 87.51 KB |
| @sentry/browser (incl. Tracing, Replay, Feedback) | 99.9 KB |
| @sentry/browser (incl. Feedback) | 43.52 KB |
| @sentry/browser (incl. sendFeedback) | 31.45 KB |
| @sentry/browser (incl. FeedbackAsync) | 36.44 KB |
| @sentry/browser (incl. Metrics) | 27.8 KB |
| @sentry/browser (incl. Logs) | 28.03 KB |
| @sentry/browser (incl. Metrics & Logs) | 28.71 KB |
| @sentry/react | 28.51 KB |
| @sentry/react (incl. Tracing) | 46.88 KB |
| @sentry/vue | 31.66 KB |
| @sentry/vue (incl. Tracing) | 46.48 KB |
| @sentry/svelte | 26.78 KB |
| CDN Bundle | 29.09 KB |
| CDN Bundle (incl. Tracing) | 47.07 KB |
| CDN Bundle (incl. Logs, Metrics) | 30.6 KB |
| CDN Bundle (incl. Tracing, Logs, Metrics) | 48.33 KB |
| CDN Bundle (incl. Replay, Logs, Metrics) | 68.97 KB |
| CDN Bundle (incl. Tracing, Replay) | 83.52 KB |
| CDN Bundle (incl. Tracing, Replay, Logs, Metrics) | 84.74 KB |
| CDN Bundle (incl. Tracing, Replay, Feedback) | 89.23 KB |
| CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) | 90.45 KB |
| CDN Bundle - uncompressed | 86.51 KB |
| CDN Bundle (incl. Tracing) - uncompressed | 142.38 KB |
| CDN Bundle (incl. Logs, Metrics) - uncompressed | 91.11 KB |
| CDN Bundle (incl. Tracing, Logs, Metrics) - uncompressed | 146.26 KB |
| CDN Bundle (incl. Replay, Logs, Metrics) - uncompressed | 213 KB |
| CDN Bundle (incl. Tracing, Replay) - uncompressed | 258.46 KB |
| CDN Bundle (incl. Tracing, Replay, Logs, Metrics) - uncompressed | 262.33 KB |
| CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed | 271.84 KB |
| CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) - uncompressed | 275.7 KB |
| @sentry/nextjs (client) | 49.27 KB |
| @sentry/sveltekit (client) | 45.04 KB |
| @sentry/core/server | 74.29 KB |
| @sentry/core/browser | 61.74 KB |
| @sentry/node-core | 60.28 KB |
| @sentry/node | 127.39 KB |
| @sentry/node - without tracing | 72.37 KB |
| @sentry/aws-serverless | 84.26 KB |
| @sentry/cloudflare (withSentry) - minified | 169.62 KB |
| @sentry/cloudflare (withSentry) | 423.68 KB |