You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to run npm run build and getting this error:
Could not resolve './{}.js' from node_modules/@sentry/utils/esm/index.js
error during build:
Error: Could not resolve './{}.js' from node_modules/@sentry/utils/esm/index.js
Hey, thanks for writing in! Could you supply a minimal reproduction of what you were trying to run npm run build on? This would help us debug why this error is occuring.
Are you using webpack/rollup or another bundler? Do you do any transpiling of code? Are you using SvelteKit alongside Svelte?
do you still encounter this problem? If yes, can you show us how you're initializing the SDK? What are you importing from the SDK? Are you using component tracking?
I'm guessing you've selected @sentry/node as the package you're using because at the time of writing this issue, the Svelte SDK was not in the issue template list, right? Or in other words, are you using other/additional Sentry SDKs in your projects? Are you using @sentry/tracing?
That's unfortunate as I'd love to get to the bottom of this (our Svelte SDK is still quite new so there might be some cases we haven't discovered yet that may cause this). Let me know in case you install the SDK again or if you have time to provide a minimal reproduction.
Just to confirm: Were you using component tracking? More specifically, did you use our Sentry.componentTrackingPreprocessor?
Activity
AbhiPrasad commentedon Sep 19, 2022
Hey, thanks for writing in! Could you supply a minimal reproduction of what you were trying to run
npm run buildon? This would help us debug why this error is occuring.Are you using webpack/rollup or another bundler? Do you do any transpiling of code? Are you using SvelteKit alongside Svelte?
tarasowski commentedon Sep 19, 2022
@AbhiPrasad sure, just added answers to your question:
I'm using vite 2.8.6
Svelte (not Sveltekit)
No code transpiling
Lms24 commentedon Sep 29, 2022
Hi @tarasowski
do you still encounter this problem? If yes, can you show us how you're initializing the SDK? What are you importing from the SDK? Are you using component tracking?
I'm guessing you've selected
@sentry/nodeas the package you're using because at the time of writing this issue, the Svelte SDK was not in the issue template list, right? Or in other words, are you using other/additional Sentry SDKs in your projects? Are you using@sentry/tracing?tarasowski commentedon Sep 29, 2022
I still have this error. I have removed it from my app right now.
I was following this instruction here: https://docs.sentry.io/platforms/javascript/guides/svelte/
Lms24 commentedon Sep 29, 2022
That's unfortunate as I'd love to get to the bottom of this (our Svelte SDK is still quite new so there might be some cases we haven't discovered yet that may cause this). Let me know in case you install the SDK again or if you have time to provide a minimal reproduction.
Just to confirm: Were you using component tracking? More specifically, did you use our
Sentry.componentTrackingPreprocessor?AbhiPrasad commentedon Oct 6, 2022
Maybe this applies here? #4473 (comment)