Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove the experimental serverActions flag #57086

Closed
wants to merge 2 commits into from
Closed

Remove the experimental serverActions flag #57086

wants to merge 2 commits into from

Conversation

shuding
Copy link
Member

@shuding shuding commented Oct 19, 2023

No description provided.

@ijjk
Copy link
Member

ijjk commented Oct 19, 2023

Failing test suites

Commit: 4363767

pnpm test-start test/e2e/app-dir/actions/app-action-export.test.ts

  • app-dir action handling - next export > should error when use export output for server actions
Expand output

● app-dir action handling - next export › should error when use export output for server actions

expect(received).toContain(expected) // indexOf

Expected substring: "Server Actions are not supported with static export."
Received string:    "yarn run v1.22.19
$ /tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.bin/next build
   Creating an optimized production build ...
 ✓ Compiled successfully
   Linting and checking validity of types ...·
   We detected TypeScript in your project and created a tsconfig.json file for you.
   Collecting page data ...
true
true
 ⚠ Using edge runtime on a page currently disables static generation for that page
true
true
   Generating static pages (0/20) ...·
Error occurred prerendering page \"/handler\". Read more: https://nextjs.org/docs/messages/prerender-error
Error: Page with `dynamic = \"error\"` couldn't be rendered statically because it used `cookies`. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering

  at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
  at cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
  at GET (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/handler/route.js:1:735)
  at ../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-route.runtime.prod.js:14:39222
  at ../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/server/lib/trace/tracer.js:121:36
  at NoopContextManager.with (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/@opentelemetry/api/index.js:1:7057)
  at ContextAPI.with (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/@opentelemetry/api/index.js:1:516)
  at NoopTracer.startActiveSpan (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/@opentelemetry/api/index.js:1:18086)
  at ProxyTracer.startActiveSpan (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/@opentelemetry/api/index.js:1:18847)
  at ../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/server/lib/trace/tracer.js:110:107
  true
  true
  StaticGenBailoutError: Page with `dynamic = \"error\"` couldn't be rendered statically because it used `cookies`. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
  at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
  at Object.cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
  at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/mutate-cookie/page.js:1:2738)
  at ew (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:11361)
  at ../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:22191
  at Array.toJSON (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:25749)
      at stringify (<anonymous>)
  at eO (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:13990)
  at ej (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:14516)
  at Timeout._onTimeout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:12336) {
    code: 'NEXT_STATIC_GEN_BAILOUT'
  }
  StaticGenBailoutError: Page with `dynamic = \"error\"` couldn't be rendered statically because it used `cookies`. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
  at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
  at Object.cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
  at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/mutate-cookie/page-2/page.js:1:2165)
  at ew (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:11361)
  at ../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:22191
  at Array.toJSON (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:25749)
      at stringify (<anonymous>)
  at eO (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:13990)
  at ej (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:14516)
  at Timeout._onTimeout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:12336) {
    code: 'NEXT_STATIC_GEN_BAILOUT'
  }
  StaticGenBailoutError: Page with `dynamic = \"error\"` couldn't be rendered statically because it used `cookies`. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
  at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
  at cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
  at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/redirect-target/page.js:1:1986)
  at ew (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:11361)
  at ../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:22191
  at Array.toJSON (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:25749)
      at stringify (<anonymous>)
  at eO (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:13990)
  at ej (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:14516)
  at Timeout._onTimeout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:12336) {
    code: 'NEXT_STATIC_GEN_BAILOUT'
  }·

Generating static pages (5/20)···
Error occurred prerendering page "/mutate-cookie". Read more: https://nextjs.org/docs/messages/prerender-error
Error: Page with dynamic = \"error\" couldn't be rendered statically because it used cookies. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
at Object.cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/mutate-cookie/page.js:1:2738)
at ew (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:11361)
at ../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:22191
at Array.toJSON (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:25749)
at stringify ()
at eO (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:13990)
at ej (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:14516)
at Timeout._onTimeout (/tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:12336)·
Generating static pages (10/20)···
Error occurred prerendering page "/mutate-cookie/page-2". Read more: https://nextjs.org/docs/messages/prerender-error
Error: Page with dynamic = \"error\" couldn't be rendered statically because it used cookies. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
at Object.cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/mutate-cookie/page-2/page.js:1:2165)
at ew (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:11361)
at ../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:22191
at Array.toJSON (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:25749)
at stringify ()
at eO (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:13990)
at ej (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:14516)
at Timeout._onTimeout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:12336)·
Error occurred prerendering page "/redirect-target". Read more: https://nextjs.org/docs/messages/prerender-error
Error: Page with dynamic = \"error\" couldn't be rendered statically because it used cookies. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
at cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/redirect-target/page.js:1:1986)
at ew (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:11361)
at ../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:22191
at Array.toJSON (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:25749)
at stringify ()
at eO (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:13990)
at ej (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:14516)
at Timeout._onTimeout (/tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/node_modules/.pnpm/file+..+next-repo-33e4adfbf8a3614c4ffe2b65e825d90d922a9bca7e4e8d4c955486126a5190a1+packages+n_kidct73nen625ph377h6kmghp4/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:75:12336)·
Generating static pages (15/20)··
StaticGenBailoutError: Page with dynamic = \"error\" couldn't be rendered statically because it used cookies. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
at cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/revalidate-2/page.js:1:3204)
at process.processTicksAndRejections (../node:internal/process/task_queues:95:5) {
code: 'NEXT_STATIC_GEN_BAILOUT'

Error occurred prerendering page "/revalidate-2". Read more: https://nextjs.org/docs/messages/prerender-error
Error: Page with dynamic = \"error\" couldn't be rendered statically because it used cookies. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
at cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/revalidate-2/page.js:1:3204)
StaticGenBailoutError: Page with dynamic = \"error\" couldn't be rendered statically because it used cookies. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
at cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/revalidate/page.js:1:4556)
at process.processTicksAndRejections (../node:internal/process/task_queues:95:5) {
code: 'NEXT_STATIC_GEN_BAILOUT'

Error occurred prerendering page "/revalidate". Read more: https://nextjs.org/docs/messages/prerender-error
Error: Page with dynamic = \"error\" couldn't be rendered statically because it used cookies. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering
at staticGenerationBailout (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/411.js:1:1397)
at cookies (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/chunks/444.js:1:1510)
at Page (../../../../../../tmp/next-install-702a5a708802a12ecde5e3e9d4dcc6a42184411ebc7aa196aca305e9067ee187/.next/server/app/revalidate/page.js:1:4556)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)·
✓ Generating static pages (20/20)··
> Export encountered errors on following paths:
/handler/route: /handler
/mutate-cookie/page-2/page: /mutate-cookie/page-2
/mutate-cookie/page: /mutate-cookie
/redirect-target/page: /redirect-target
/revalidate-2/page: /revalidate-2
/revalidate/page: /revalidate
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
"
at Object.toContain (e2e/app-dir/actions/app-action-export.test.ts:37:30)

Read more about building and testing Next.js in contributing.md.

pnpm test test/integration/create-next-app/index.test.ts

  • create next app > empty directory
  • create next app > should fall back to default template
  • create next app > should allow an example named default
  • create next app > should create a project in the current directory
  • create next app > should ask the user for a name for the project if none supplied
Expand output

● create next app › empty directory

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at projectFilesShouldExist (integration/create-next-app/lib/utils.ts:133:3)
  at shouldBeTemplateProject (integration/create-next-app/lib/utils.ts:172:3)
  at integration/create-next-app/index.test.ts:82:34
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/index.test.ts:66:7)

● create next app › should fall back to default template

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at projectFilesShouldExist (integration/create-next-app/lib/utils.ts:133:3)
  at shouldBeTemplateProject (integration/create-next-app/lib/utils.ts:172:3)
  at integration/create-next-app/index.test.ts:322:34
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/index.test.ts:302:7)

● create next app › should allow an example named default

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at projectFilesShouldExist (integration/create-next-app/lib/utils.ts:133:3)
  at shouldBeTemplateProject (integration/create-next-app/lib/utils.ts:172:3)
  at integration/create-next-app/index.test.ts:346:32
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/index.test.ts:328:5)

● create next app › should create a project in the current directory

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at projectFilesShouldExist (integration/create-next-app/lib/utils.ts:133:3)
  at shouldBeTemplateProject (integration/create-next-app/lib/utils.ts:172:3)
  at integration/create-next-app/index.test.ts:452:32
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/index.test.ts:415:5)

● create next app › should ask the user for a name for the project if none supplied

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at projectFilesShouldExist (integration/create-next-app/lib/utils.ts:133:3)
  at shouldBeTemplateProject (integration/create-next-app/lib/utils.ts:172:3)
  at integration/create-next-app/index.test.ts:475:32
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/index.test.ts:457:5)

Read more about building and testing Next.js in contributing.md.

pnpm test test/integration/create-next-app/package-manager.test.ts

  • should use npm as the package manager on supplying --use-npm

  • should use Yarn as the package manager on supplying --use-yarn

  • should use pnpm as the package manager on supplying --use-pnpm

  • should use Bun as the package manager on supplying --use-bun

  • should infer npm as the package manager

  • should infer yarn as the package manager

  • should infer pnpm as the package manager

  • should infer Bun as the package manager

Expand output

● should use npm as the package manager on supplying --use-npm

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at projectFilesShouldExist (integration/create-next-app/lib/utils.ts:133:3)
  at shouldBeTemplateProject (integration/create-next-app/lib/utils.ts:172:3)
  at integration/create-next-app/package-manager.test.ts:56:30
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager.test.ts:36:3)

● should use Yarn as the package manager on supplying --use-yarn

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at integration/create-next-app/package-manager.test.ts:112:28
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager.test.ts:92:3)

● should use pnpm as the package manager on supplying --use-pnpm

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at integration/create-next-app/package-manager.test.ts:190:28
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager.test.ts:170:3)

● should use Bun as the package manager on supplying --use-bun

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at integration/create-next-app/package-manager.test.ts:268:28
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager.test.ts:248:3)

● should infer npm as the package manager

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at integration/create-next-app/package-manager.test.ts:350:28
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager.test.ts:322:3)

● should infer yarn as the package manager

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at integration/create-next-app/package-manager.test.ts:422:28
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager.test.ts:394:3)

● should infer pnpm as the package manager

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at integration/create-next-app/package-manager.test.ts:505:28
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager.test.ts:477:3)

● should infer Bun as the package manager

expect(received).toBe(expected) // Object.is equality

Expected: true
Received: false

  81 |   for (const file of files) {
  82 |     try {
> 83 |       expect(existsSync(resolve(projectRoot, file))).toBe(true)
     |                                                      ^
  84 |     } catch (err) {
  85 |       require('console').error(
  86 |         `missing expected file ${file}`,

  at toBe (integration/create-next-app/lib/utils.ts:83:54)
  at integration/create-next-app/package-manager.test.ts:584:28
  at useTempDir (lib/use-temp-dir.ts:24:5)
  at Object.<anonymous> (integration/create-next-app/package-manager.test.ts:556:3)

Read more about building and testing Next.js in contributing.md.

pnpm test test/integration/build-output/test/index.test.js

  • Build Output > production mode > Custom Static Error Output > should not specify /404 as lambda when static
Expand output

● Build Output › production mode › Custom Static Error Output › should not specify /404 as lambda when static

expect(received).toContain(expected) // indexOf

Expected substring: "○ /404"
Received string:    "   Linting and checking validity of types ...
   Creating an optimized production build ...
 ✓ Compiled successfully
   Collecting page data ...
   Generating static pages (0/3) ...·
 ✓ Generating static pages (3/3)·
"

  289 |           stdout: true,
  290 |         })
> 291 |         expect(stdout).toContain('○ /404')
      |                        ^
  292 |         expect(stdout).not.toContain('λ /_error')
  293 |         expect(stdout).not.toContain('<buildId>')
  294 |       })

  at Object.toContain (integration/build-output/test/index.test.js:291:24)

Read more about building and testing Next.js in contributing.md.

@ijjk
Copy link
Member

ijjk commented Oct 19, 2023

Stats from current PR

Default Build
General
vercel/next.js canary vercel/next.js shu/f5c8 Change
buildDuration 10.4s 10.5s ⚠️ +111ms
buildDurationCached 6.1s 6.1s N/A
nodeModulesSize 174 MB 174 MB N/A
nextStartRea..uration (ms) 519ms 521ms N/A
Client Bundles (main, webpack)
vercel/next.js canary vercel/next.js shu/f5c8 Change
199-HASH.js gzip 27.5 kB 27.5 kB
3f784ff6-HASH.js gzip 53.3 kB 53.3 kB
99.HASH.js gzip 182 B 182 B
framework-HASH.js gzip 45.3 kB 45.3 kB
main-app-HASH.js gzip 254 B 251 B N/A
main-HASH.js gzip 32.9 kB 32.9 kB N/A
webpack-HASH.js gzip 1.75 kB 1.75 kB N/A
Overall change 126 kB 126 kB
Legacy Client Bundles (polyfills)
vercel/next.js canary vercel/next.js shu/f5c8 Change
polyfills-HASH.js gzip 31 kB 31 kB
Overall change 31 kB 31 kB
Client Pages
vercel/next.js canary vercel/next.js shu/f5c8 Change
_app-HASH.js gzip 206 B 205 B N/A
_error-HASH.js gzip 182 B 180 B N/A
amp-HASH.js gzip 506 B 505 B N/A
css-HASH.js gzip 322 B 323 B N/A
dynamic-HASH.js gzip 2.57 kB 2.57 kB N/A
edge-ssr-HASH.js gzip 260 B 259 B N/A
head-HASH.js gzip 350 B 350 B
hooks-HASH.js gzip 369 B 369 B
image-HASH.js gzip 4.36 kB 4.36 kB N/A
index-HASH.js gzip 256 B 256 B
link-HASH.js gzip 2.64 kB 2.63 kB N/A
routerDirect..HASH.js gzip 312 B 311 B N/A
script-HASH.js gzip 385 B 384 B N/A
withRouter-HASH.js gzip 307 B 308 B N/A
1afbb74e6ecf..834.css gzip 106 B 106 B
Overall change 1.08 kB 1.08 kB
Client Build Manifests
vercel/next.js canary vercel/next.js shu/f5c8 Change
_buildManifest.js gzip 484 B 482 B N/A
Overall change 0 B 0 B
Rendered Page Sizes
vercel/next.js canary vercel/next.js shu/f5c8 Change
index.html gzip 528 B 529 B N/A
link.html gzip 541 B 541 B
withRouter.html gzip 523 B 524 B N/A
Overall change 541 B 541 B
Edge SSR bundle Size
vercel/next.js canary vercel/next.js shu/f5c8 Change
edge-ssr.js gzip 93.7 kB 93.7 kB N/A
page.js gzip 155 kB 155 kB N/A
Overall change 0 B 0 B
Middleware size
vercel/next.js canary vercel/next.js shu/f5c8 Change
middleware-b..fest.js gzip 622 B 625 B N/A
middleware-r..fest.js gzip 150 B 151 B N/A
middleware.js gzip 22.5 kB 22.5 kB N/A
edge-runtime..pack.js gzip 1.92 kB 1.92 kB
Overall change 1.92 kB 1.92 kB
Commit: 4363767

@gnoff
Copy link
Contributor

gnoff commented Oct 20, 2023

completing in: #57145

@gnoff gnoff closed this Oct 20, 2023
@shuding shuding deleted the shu/f5c8 branch October 20, 2023 20:16
@github-actions github-actions bot added the locked label Nov 4, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 4, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants