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

Next.js Font Manifest Error with Cloudflare Workers #20194

Open
Richmond-Eribo opened this issue Feb 22, 2025 · 1 comment
Open

Next.js Font Manifest Error with Cloudflare Workers #20194

Richmond-Eribo opened this issue Feb 22, 2025 · 1 comment
Assignees
Labels
DevRel Tasks that need support from developer relations. product:workers Related to Workers product

Comments

@Richmond-Eribo
Copy link

Description

When trying to build Next.js locally with Cloudflare Worker using the @openNextjs/cloudflare package, encountering an error related to font manifest loading:

X [ERROR] service core:user:email-template-previewer: Uncaught Error: Unexpected loadManifest(/.next/server/next-font-manifest.json) call!

Environment

  • Next.js version: [your version]
  • @openNextjs/cloudflare version: 0.5.3
  • Node.js version: v22.13.1

Steps to Reproduce

  1. Set up a Next.js project
  2. Install @openNextjs/cloudflare
  3. Run build command
  4. Error occurs during build process
X [ERROR] service core:user:email-template-previewer: Uncaught Error: Unexpected loadManifest(/.next/server/next-font-manifest.json) call!

    at null.<anonymous> (worker.js:130722:13) in loadManifest
    at null.<anonymous> (worker.js:265861:47) in getNextFontManifest
    at null.<anonymous> (worker.js:128732:38) in Server
    at null.<anonymous> (worker.js:265261:9) in NextNodeServer
    at null.<anonymous> (worker.js:267866:22)
@haleycode haleycode added product:workers Related to Workers product DevRel Tasks that need support from developer relations. labels Feb 24, 2025
@BobbySmurf
Copy link

Also currently having this issue, want to point out too that when building with github it gives me this error:
A wrangler.toml file was found but it does not appear to be valid. Did you mean to use wrangler.toml to configure Pages? If so, then make sure the file is valid and contains the pages_build_output_dir property. Skipping file and continuing.

and

`
03:00:01.146 | ⚡️ ERROR: Failed to produce a Cloudflare Pages build from the project.

03:00:01.146 | ⚡️
03:00:01.146 | ⚡️ The following routes were not configured to run with the Edge Runtime:
03:00:01.147 | ⚡️ - /_not-found
03:00:01.147 | ⚡️ - /api/products
03:00:01.147 | ⚡️ - /faq
03:00:01.147 | ⚡️ - /index
03:00:01.147 | ⚡️
03:00:01.147 | ⚡️ Please make sure that all your non-static routes export the following edge runtime route segment config:
03:00:01.147 | ⚡️ export const runtime = 'edge';
03:00:01.147 | ⚡️
03:00:01.147 | ⚡️ You can read more about the Edge Runtime on the Next.js documentation:
03:00:01.148 | ⚡️ https://nextjs.org/docs/app/building-your-application/rendering/edge-and-nodejs-runtimes

`

it errors out because it thinks its @cloudflare/next-on-pages when im using @openNextjs/cloudflare package. When I build locally like Richmond, this error disappears but instead I get the exact one he gets.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DevRel Tasks that need support from developer relations. product:workers Related to Workers product
Projects
None yet
Development

No branches or pull requests

7 participants