diff --git a/.size-limit.js b/.size-limit.js index 4f86a9f8a2ea..f4bf45b47b40 100644 --- a/.size-limit.js +++ b/.size-limit.js @@ -15,7 +15,7 @@ module.exports = [ path: 'packages/browser/build/npm/esm/prod/index.js', import: createImport('init'), gzip: true, - limit: '24.1 KB', + limit: '24.5 KB', modifyWebpackConfig: function (config) { const webpack = require('webpack'); @@ -190,7 +190,7 @@ module.exports = [ name: 'CDN Bundle (incl. Logs, Metrics)', path: createCDNPath('bundle.logs.metrics.min.js'), gzip: true, - limit: '29 KB', + limit: '30 KB', }, { name: 'CDN Bundle (incl. Tracing, Logs, Metrics)', @@ -214,7 +214,7 @@ module.exports = [ name: 'CDN Bundle (incl. Tracing, Replay, Logs, Metrics)', path: createCDNPath('bundle.tracing.replay.logs.metrics.min.js'), gzip: true, - limit: '81 KB', + limit: '82 KB', }, { name: 'CDN Bundle (incl. Tracing, Replay, Feedback)', @@ -241,7 +241,7 @@ module.exports = [ path: createCDNPath('bundle.tracing.min.js'), gzip: false, brotli: false, - limit: '128 KB', + limit: '129 KB', }, { name: 'CDN Bundle (incl. Logs, Metrics) - uncompressed', diff --git a/CHANGELOG.md b/CHANGELOG.md index 23d01dd3117e..599f5ff26c12 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,8 @@ - "You miss 100 percent of the chances you don't take. — Wayne Gretzky" — Michael Scott +### Important Changes + - **feat(tanstackstart-react): Add global sentry exception middlewares ([#19330](https://github.com/getsentry/sentry-javascript/pull/19330))** The `sentryGlobalRequestMiddleware` and `sentryGlobalFunctionMiddleware` global middlewares capture unhandled exceptions thrown in TanStack Start API routes and server functions. Add them as the first entries in the `requestMiddleware` and `functionMiddleware` arrays of `createStart()`: @@ -18,11 +20,21 @@ }); ``` -### Important Changes +- **fix(node-core): Reduce bundle size by removing apm-js-collab and requiring pino >= 9.10 ([#18631](https://github.com/getsentry/sentry-javascript/pull/18631))** + + In order to keep receiving pino logs, you need to update your pino version to >= 9.10, the reason for the support bump is to reduce the bundle size of the node-core SDK in frameworks that cannot tree-shake the apm-js-collab dependency. + +- **fix(browser): Ensure user id is consistently added to sessions ([#19341](https://github.com/getsentry/sentry-javascript/pull/19341))** -- fix(node-core): Reduce bundle size by removing apm-js-collab and requiring pino >= 9.10 ([#18631](https://github.com/getsentry/sentry-javascript/pull/18631)) + Previously, the SDK inconsistently set the user id on sessions, meaning sessions were often lacking proper coupling to the user set for example via `Sentry.setUser()`. + Additionally, the SDK incorrectly skipped starting a new session for the first soft navigation after the pageload. + This patch fixes these issues. As a result, metrics around sessions, like "Crash Free Sessions" or "Crash Free Users" might change. + This could also trigger alerts, depending on your set thresholds and conditions. + We apologize for any inconvenience caused! -In order to keep receiving pino logs, you need to update your pino version to >= 9.10, the reason for the support bump is to reduce the bundle size of the node-core SDK in frameworks that cannot tree-shake the apm-js-collab dependency. + While we're at it, if you're using Sentry in a Single Page App or meta framework, you might want to give the new `'page'` session lifecycle a try! + This new mode no longer creates a session per soft navigation but continues the initial session until the next hard page refresh. + Check out the [docs](https://docs.sentry.io/platforms/javascript/guides/nextjs/configuration/integrations/browsersession/) to learn more! ## 10.39.0 diff --git a/dev-packages/browser-integration-tests/suites/sessions/initial-scope/template.html b/dev-packages/browser-integration-tests/suites/sessions/initial-scope/template.html index 291d2f23499b..e7c463998c02 100644 --- a/dev-packages/browser-integration-tests/suites/sessions/initial-scope/template.html +++ b/dev-packages/browser-integration-tests/suites/sessions/initial-scope/template.html @@ -4,6 +4,6 @@
- Navigate + Navigate