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

Nextra and MDX generation doesn't work with Turbopack #74354

Open
frogermcs opened this issue Dec 28, 2024 · 0 comments
Open

Nextra and MDX generation doesn't work with Turbopack #74354

frogermcs opened this issue Dec 28, 2024 · 0 comments
Labels
bug Issue was opened via the bug report template. Markdown (MDX) Related to Markdown with Next.js. Pages Router Related to Pages Router. Turbopack Related to Turbopack with Next.js.

Comments

@frogermcs
Copy link

Link to the code that reproduces this issue

https://github.com/frogermcs/next-issue-reproduce

To Reproduce

In the App Router config, I want to add Nextra, which lands in /pages directory.
Renderring the page without turbopack works as expected, while using turbopack results with error, as described below.

Steps to reproduce:

  • npm run dev with --turbopack results with the issue
  • Running the same without --turbopack results with page rendered as expected.

To reproduce, visit: http://localhost:3001/docs

Console output:

---------------------------
content is not available as task execution failed

Caused by:
- content is not available as task execution failed
- Expected process result to be a module, but it could not be processed

Debug info:
- Execution of *Project::client_changed failed
- Execution of *PageEndpointOutput::client_assets failed
- Execution of PageEndpoint::output failed
- Execution of PageEndpoint::client_chunks failed
- content is not available as task execution failed
- Execution of PageEndpoint::client_module failed
- content is not available as task execution failed
- Execution of create_page_loader_entry_module failed
- Execution of ProcessResult::module failed
- Expected process result to be a module, but it could not be processed

Current vs. Expected behavior

When visiting page while turbopack is enabled, I get server error (console log pasted above)

Server Error

Error: An unexpected Turbopack error occurred. Please see the output of next dev for more details.

This error happened while generating the page. Any console logs will be displayed in the terminal window.
getServerError
node_modules/next/src/client/components/react-dev-overlay/internal/helpers/node-stack-frames.ts (31:36)
getServerError
node_modules/next/src/client/index.tsx (940:17)

Provide environment information

Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 24.1.0: Thu Oct 10 21:03:11 PDT 2024; root:xnu-11215.41.3~2/RELEASE_ARM64_T6020
  Available memory (MB): 16384
  Available CPU cores: 10
Binaries:
  Node: 22.12.0
  npm: 10.9.0
  Yarn: N/A
  pnpm: N/A
Relevant Packages:
  next: 15.1.3 // Latest available version is detected (15.1.3).
  eslint-config-next: N/A
  react: 19.0.0
  react-dom: 19.0.0
  typescript: 5.3.3
Next.js Config:
  output: N/A

Which area(s) are affected? (Select all that apply)

Markdown (MDX), Pages Router, Turbopack

Which stage(s) are affected? (Select all that apply)

next dev (local)

Additional context

I tried it on:

  • nextjs 5.0.2 and 5.1.3
  • node 19 and 22
@frogermcs frogermcs added the bug Issue was opened via the bug report template. label Dec 28, 2024
@github-actions github-actions bot added Markdown (MDX) Related to Markdown with Next.js. Pages Router Related to Pages Router. Turbopack Related to Turbopack with Next.js. labels Dec 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue was opened via the bug report template. Markdown (MDX) Related to Markdown with Next.js. Pages Router Related to Pages Router. Turbopack Related to Turbopack with Next.js.
Projects
None yet
Development

No branches or pull requests

1 participant