Skip to content

Commit ca3702e

Browse files
author
Luca Forstner
committed
one more warning
1 parent 0086d69 commit ca3702e

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

packages/nextjs/src/config/withSentryConfig.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,18 @@ function getFinalConfigObject(
179179
clientInstrumentationHook: true,
180180
...incomingUserNextConfigObject.experimental,
181181
};
182+
} else if (process.env.TURBOPACK) {
183+
if (process.env.NODE_ENV === 'development') {
184+
// eslint-disable-next-line no-console
185+
console.warn(
186+
`[@sentry/nextjs] WARNING: You are using the Sentry SDK with Turbopack (\`next dev --turbo\`). The Sentry SDK is compatible with Turbopack on Next.js version 15.3.0 or later. You are currently on ${nextJsVersion}. Please upgrade to a newer Next.js version to use the Sentry SDK with Turbopack. Note that the SDK will continue to work for non-Turbopack production builds. This warning is only about dev-mode.`,
187+
);
188+
} else if (process.env.NODE_ENV === 'production') {
189+
// eslint-disable-next-line no-console
190+
console.warn(
191+
`[@sentry/nextjs] WARNING: You are using the Sentry SDK with Turbopack (\`next build --turbo\`). The Sentry SDK is compatible with Turbopack on Next.js version 15.3.0 or later. You are currently on ${nextJsVersion}. Please upgrade to a newer Next.js version to use the Sentry SDK with Turbopack. Note that as Turbopack is still experimental for production builds, some of the Sentry SDK features like source maps will not work. Follow this issue for progress on Sentry + Turbopack: https://github.com/getsentry/sentry-javascript/issues/8105.`,
192+
);
193+
}
182194
}
183195
} else {
184196
if (

0 commit comments

Comments
 (0)