-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
Feature: Source MapsPackage: nextjsIssues related to the Sentry Nextjs SDKIssues related to the Sentry Nextjs SDK
Description
Environment
SaaS (https://sentry.io/)
Steps to Reproduce
I'm using Vercel to deploy my Next.js project. When I enable sourcemaps: { deleteSourcemapsAfterUpload: true }
in next.config.js
, I get the following error from Vercel:
Error: ENOENT: no such file or directory, lstat '/vercel/path0/.next/server/chunks/195.js.map'
More detailed output:
Route (pages) Size First Load JS
┌ ○ / 8.71 kB 163 kB
├ └ css/88d021db95f13dbf.css 2.02 kB
├ /_app 0 B 154 kB
├ ○ /404 438 B 155 kB
├ ƒ /api/sentry-example-api 0 B 154 kB
├ ƒ /api/test1 0 B 154 kB
├ ƒ /api/test2 0 B 154 kB
├ ƒ /api/test3 0 B 154 kB
├ ƒ /api/test4 0 B 154 kB
├ ○ /client/test1 429 B 155 kB
├ ○ /client/test2 456 B 155 kB
├ ○ /client/test3 445 B 155 kB
├ ○ /client/test4 467 B 155 kB
├ ○ /sentry-example-page 1.86 kB 156 kB
├ ƒ /ssr/test1 431 B 155 kB
├ ƒ /ssr/test2 429 B 155 kB
├ ƒ /ssr/test3 430 B 155 kB
└ ƒ /ssr/test4 432 B 155 kB
+ First Load JS shared by all 155 kB
├ chunks/framework-8722668362422965.js 45.3 kB
├ chunks/main-4d4ce5325c2179ff.js 32.2 kB
├ chunks/pages/_app-c18a80145f513654.js 76 kB
└ other shared chunks (total) 1.66 kB
○ (Static) prerendered as static content
ƒ (Dynamic) server-rendered on demand
Error: ENOENT: no such file or directory, lstat '/vercel/path0/.next/server/chunks/195.js.map'
I've created a minimal repo to reproduce this issue: https://github.com/ocavue/nextjs-sentry-vercel-deploy-issue
You can see from the GitHub webpage that the Vercel deployment failed after I enable deleteSourcemapsAfterUpload
.
Expected Result
No error.
Actual Result
Vercel deployment fails, as shown above.
Product Area
Unknown
Link
No response
DSN
No response
Version
8.20.0
Metadata
Metadata
Assignees
Labels
Feature: Source MapsPackage: nextjsIssues related to the Sentry Nextjs SDKIssues related to the Sentry Nextjs SDK
Type
Projects
Status
No status