getsentry / sentry-javascript

Official Sentry SDKs for JavaScript
https://sentry.io
MIT License
7.97k stars 1.57k forks source link

Nuxt: Compatibility with different Deployment Platforms #14029

Open s1gr1d opened 1 week ago

s1gr1d commented 1 week ago

Description

The Sentry Nuxt SDK should work on different deployment platforms. This issue tracks the progress of what we already tested and implemented.

The state shows what is supported from v8.35.0 (beta) onwards.

If you experience issues or a specific deployment platform is not listed, feel free to comment here or file a new GitHub issue.

### Local Production Build (`nuxi build` -> `node .output/server/index.mjs`)
- [x] Client-side error monitoring works
- [x] Client-side tracing works
- [x] Server-side error monitoring works
- [x] Server-side tracing works
### Netlify
- [x] Client-side error monitoring works
- [x] Client-side tracing works
- [x] Server-side error monitoring works
- [ ] Server-side tracing works
- [ ] Server-side logs work
### Vercel
- [x] Client-side error monitoring works
- [x] Client-side tracing works
- [x] Server-side error monitoring works
- [x] Server-side tracing works
### Cloudflare (not tested yet)
- [ ] Client-side error monitoring works
- [ ] Client-side tracing works
- [ ] Server-side error monitoring works
- [ ] Server-side tracing works
rocketiscool commented 1 week ago

Any idea why I get

[nuxt] [request error] [unhandled] [500] ENOENT: no such file or directory, open 'path/web/apps/web/.output/public/_nuxt/yrDNp5yz.js.map'

on original page load with local production build

Edit:

Seems that unless

    sourcemap: {
        server: true,
        client: true
    },

both server and client are explicitly enabled, it will cause that error if its just client: true alone.

s1gr1d commented 1 week ago

Are you using version 8.35.0? Nuxt automatically sets sourcemap.server: true, so this shouldn't make a difference 🤔 Do you have a small reproduction example?