Build failure with remote caching in Vercel #1065
-
Hi, I am deploying to Vercel and have remote caching issue. This is probably noob question. Although it works fine without remote caching, I found that the remote caching enabled build showed my local directory path which I think it is related to this issue. Do you have any clue why this is happening?
Remote caching disabled - working fine
Remote caching enabled
|
Beta Was this translation helpful? Give feedback.
Replies: 6 comments 1 reply
-
Any feedback on this? 👀 🙏 |
Beta Was this translation helpful? Give feedback.
-
@youminkim could you share your |
Beta Was this translation helpful? Give feedback.
-
@tknickman Also experiencing this issue, especially when merging branches. My {
"pipeline": {
"build": {
"dependsOn": ["^build"],
"outputs": ["dist/**", ".next/**"]
},
"lint": {
"outputs": []
},
"test": { "outputs": [] },
"clean": { "outputs": [] },
"dev": {
"cache": false
}
}
} Failed deployment logs: [12:23:02.544] Cloning github.com/xxxx/ui (Branch: staging, Commit: f8fab96)
[12:23:03.184] Cloning completed: 639.544ms
[12:23:03.516] Installing build runtime...
[12:23:05.389] Build runtime installed: 1.873s
[12:23:06.122] Looking up build cache...
[12:23:11.581] Build cache downloaded [108.84 MB]: 5138.860ms
[12:23:11.782] Running "install" command: `yarn install`...
[12:23:12.121] yarn install v1.22.17
[12:23:12.202] [1/5] Validating package.json...
[12:23:12.208] [2/5] Resolving packages...
[12:23:12.260] warning Resolution field "@types/react@17.0.2" is incompatible with requested version "@types/react@17.0.37"
[12:23:12.263] warning Resolution field "@types/react@17.0.2" is incompatible with requested version "@types/react@^17.0.37"
[12:23:12.263] warning Resolution field "@types/react-dom@17.0.2" is incompatible with requested version "@types/react-dom@^17.0.11"
[12:23:12.277] warning Resolution field "@types/react-dom@17.0.2" is incompatible with requested version "@types/react-dom@^18.0.0"
[12:23:12.521] success Already up-to-date.
[12:23:12.526] Done in 0.41s.
[12:23:12.541] Detected Next.js version: 12.1.6
[12:23:12.737] Running "cd ../.. && yarn build"
[12:23:13.000] yarn run v1.22.17
[12:23:13.030] $ turbo run build
[12:23:13.139] • Packages in scope: eslint-config-custom, tsconfig, ui, web
[12:23:13.140] • Running build in 4 packages
[12:23:13.140] • Remote computation caching enabled (experimental)
[12:23:14.052] web:build: cache hit, replaying output 2d573325425b46fd
[12:23:14.053] web:build: $ next build
[12:23:14.053] web:build: warn - No build cache found. Please configure build caching for faster rebuilds. Read more: https://nextjs.org/docs/messages/no-cache
[12:23:14.053] web:build: Attention: Next.js now collects completely anonymous telemetry regarding usage.
[12:23:14.053] web:build: This information is used to shape Next.js' roadmap and prioritize features.
[12:23:14.053] web:build: You can learn more, including how to opt-out if you'd not like to participate in this anonymous program, by visiting the following URL:
[12:23:14.054] web:build: https://nextjs.org/telemetry
[12:23:14.054] web:build:
[12:23:14.055] web:build: info - Checking validity of types...
[12:23:14.055] web:build: info - Creating an optimized production build...
[12:23:14.055] web:build: info - Compiled successfully
[12:23:14.055] web:build: info - Collecting page data...
[12:23:14.056] web:build: Page Size First Load JS
[12:23:14.056] web:build: ┌ λ / 2.5 kB 148 kB
[12:23:14.056] web:build: ├ /_app 0 B 127 kB
[12:23:14.056] web:build: ├ λ /404 784 B 128 kB
[12:23:14.056] web:build: ├ λ /api/auth/[...nextauth] 0 B 127 kB
[12:23:14.056] web:build: ├ λ /api/auth/passwordless/start 0 B 127 kB
[12:23:14.056] web:build: ├ λ /login 20.9 kB 167 kB
[12:23:14.056] web:build: └ λ /settings/profile 526 B 136 kB
[12:23:14.056] web:build: + First Load JS shared by all 127 kB
[12:23:14.057] web:build: ├ chunks/framework-426a77a37f430192.js 45.1 kB
[12:23:14.057] web:build: ├ chunks/main-8a5945c8d340c521.js 28.7 kB
[12:23:14.057] web:build: ├ chunks/pages/_app-af0ab2b7d87391a9.js 51.8 kB
[12:23:14.057] web:build: ├ chunks/webpack-6fae696859cf3c39.js 1.2 kB
[12:23:14.057] web:build: └ css/22b365d68752b389.css 334 B
[12:23:14.057] web:build:
[12:23:14.057] web:build: λ (Server) server-side renders at runtime (uses getInitialProps or getServerSideProps)
[12:23:14.057] web:build:
[12:23:14.057]
[12:23:14.058] Tasks: 1 successful, 1 total
[12:23:14.058] Cached: 1 cached, 1 total
[12:23:14.058] Time: 963ms >>> FULL TURBO
[12:23:14.058]
[12:23:14.107] Done in 1.11s.
[12:23:14.141] Error: Cannot find module 'next/dist/server/next-server.js'
[12:23:14.141] Require stack:
[12:23:14.142] - /home/runner/work/ui/ui/apps/web/noop.js
[12:23:14.142] at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
[12:23:14.142] at resolveFileName (/vercel/d30e0a43e7911237/.build-utils/.builder/node_modules/@vercel/next/dist/index.js:42653:39)
[12:23:14.142] at resolveFrom (/vercel/d30e0a43e7911237/.build-utils/.builder/node_modules/@vercel/next/dist/index.js:42667:9)
[12:23:14.142] at module.exports (/vercel/d30e0a43e7911237/.build-utils/.builder/node_modules/@vercel/next/dist/index.js:42670:47)
[12:23:14.142] at serverBuild (/vercel/d30e0a43e7911237/.build-utils/.builder/node_modules/@vercel/next/dist/index.js:47095:59) {
[12:23:14.142] code: 'MODULE_NOT_FOUND',
[12:23:14.142] requireStack: [ '/home/runner/work/ui/ui/apps/web/noop.js' ]
[12:23:14.142] } |
Beta Was this translation helpful? Give feedback.
-
Also experiencing a very similar issue here. Where Only temporary workaround so far is passing in
Failed deployment logs:
|
Beta Was this translation helpful? Give feedback.
-
Thanks for the extra details @Etzeo / @farid-ouachrar. The config looks good. I just spent some time trying to reproduce this with both If any of you have time, could you create a small repo with a minimal repro case so I could better investigate? I would love to get to the bottom of this and get it fixed up. For reference, my example project can be found here: And I used these settings for my project configuration on Vercel: |
Beta Was this translation helpful? Give feedback.
-
Closing due to age and inactivity. If you've stumbled on this discussion because you're seeing this problem, please report it an issue. |
Beta Was this translation helpful? Give feedback.
Closing due to age and inactivity. If you've stumbled on this discussion because you're seeing this problem, please report it an issue.