Closed klaa97 closed 2 months ago
hey @klaa97, thanks for reaching out!
Are you using yarn with the pnp
node-linker?
I am not configuring it explicitly, so I think I am using hoisted
. (I am using pnpm)
Looks like it might still be related to https://github.com/getsentry/sentry-javascript/issues/13641
We'll have a look!
It also failed with Next.js v14.2.8.
@chargome Any workaround or suggestion?
@ibufu if you're using pnpm you can try setting node-linker to hoisted
explicitly, I did not try this myself yet though
@ibufu if you're using pnpm you can try setting node-linker to
hoisted
explicitly, I did not try this myself yet though
Thanks! I downgraded from 8.30.0 to 7.*. It works now.
I spent a whole day figuring out why the sourcemap not uploaded on v7.x.
// @sentry/nextjs/cjs/config/webpack.js
const SentryWebpackPlugin = utils.loadModule('@sentry/webpack-plugin');
Finally I found SentryWebpackPlugin
was undefined. Maybe utils.loadModule
doesn't work with pnpm.
So I added the following line into .npmrc then everything works well.
// .npmrc
hoist-pattern[]=*sentry*
I hope this can help people using pnpm monorepo. 🙏
@ibufu yes this was already clarified in https://github.com/getsentry/sentry-javascript/issues/13641 since we access node_modules there directly, sorry you burned so much time on this – but thanks for the pnpm workaround you provided!
closing this in favour of https://github.com/getsentry/sentry-javascript/issues/13641
duplicate of https://github.com/getsentry/sentry-javascript/issues/13641
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/nextjs
SDK Version
8.30.0
Framework Version
Next 13.4.7
Link to Sentry event
No response
Reproduction Example/SDK Setup
I have the following versions:
If I add the
withSentryConfig
to NextJS, such as this:I get an error when building:
Steps to Reproduce
Expected Result
It succeeds the build
Actual Result
It fails the build with the error above