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
I ran npx @sentry/wizard@latest -i sveltekit to automatically add Sentry to my SvelteKit Application
I manually put build: { sourcemaps: true } in my vite.config.js, because I want sourcemaps for the server
I built my app (vite build), started it (node ./build) and triggered an error locally
I noticed that Sentry stopped showing any code at all in the traces:
I dug as deep as I could and noticed that the relative paths in the sourcemaps are slightly wrong. They go one level too far up. For example, it would show ../../../../src/routes/+page.svelte, but relative to build/server/chunks, this is outside of my project folder. So I checked where these paths get set, and ended up creating this bug report in the SvelteKit repo: adapter-node breaks paths to sourcemap sources by copying files during build sveltejs/kit#10040
I worked around the bug locally, but I also noticed that the directories of the files are now omitted (instead it prepends app://), showing only the filename. In a typical SvelteKit app, many many files are called +page or +layout, so this is less than ideal. :D
Expected Result
The full path to the file should be shown.
Actual Result
Previously, when I didn't use sourcemaps, it showed the whole filepath:
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/sveltekit
SDK Version
7.53.1
Framework Version
1.18.0
Link to Sentry event
https://eintrittskartenio.sentry.io/issues/4208536907/?environment=development&project=1422627&query=is%3Aunresolved&referrer=issue-stream&stream_index=0
SDK Setup
Steps to Reproduce
npx @sentry/wizard@latest -i sveltekitto automatically add Sentry to my SvelteKit Applicationbuild: { sourcemaps: true }in my vite.config.js, because I want sourcemaps for the servervite build), started it (node ./build) and triggered an error locally../../../../src/routes/+page.svelte, but relative tobuild/server/chunks, this is outside of my project folder. So I checked where these paths get set, and ended up creating this bug report in the SvelteKit repo:adapter-nodebreaks paths to sourcemap sources by copying files during build sveltejs/kit#10040app://), showing only the filename. In a typical SvelteKit app, many many files are called+pageor+layout, so this is less than ideal. :DExpected Result
The full path to the file should be shown.
Actual Result
Previously, when I didn't use sourcemaps, it showed the whole filepath: