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

null is not an object (evaluating 't.parallelRoutes.get') #67730

Open
JClackett opened this issue Jul 13, 2024 · 3 comments
Open

null is not an object (evaluating 't.parallelRoutes.get') #67730

JClackett opened this issue Jul 13, 2024 · 3 comments
Labels
bug Issue was opened via the bug report template. Navigation Related to Next.js linking (e.g., <Link>) and navigation. Runtime Related to Node.js or Edge Runtime with Next.js.

Comments

@JClackett
Copy link
Contributor

Link to the code that reproduces this issue

https://github.com/JClackett/next-reproduction-app

To Reproduce

So, I literally have no idea how to reproduce this consistently yet, but will keep trying.

I'm getting this error semi-often in production only and only sometimes for certain users, most of the time it's working.

Looking at the stack trace (which is limited), it's due to some call to a <cache>.parallelRoutes.get. Searching the next code base with https://github.com/search?q=repo%3Avercel%2Fnext.js%20parallelRoutes.get&type=code
shows all the times this method is called.

It seems that one of the cache objects is null for me? How would I go about creating a repro for that. Or does anyone have any idea why this cache object would be null in the first place. The page this is erroring on is nothing special, it's just a async server component that fetches data and renders few components, one being a client component, so I dont see (yet) how this is something strange with my setup. Only thing of note is that im using react suspense to handle the fallback because the loading.tsx pages dont work as id like (they dont trigger on search param changes).

Current vs. Expected behavior

Doesn't crash

Provide environment information

Like I said, only in production and on vercel.
Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 23.1.0: Mon Oct  9 21:27:24 PDT 2023; root:xnu-10002.41.9~6/RELEASE_ARM64_T6000
  Available memory (MB): 32768
  Available CPU cores: 8
Binaries:
  Node: 18.18.2
  npm: 9.8.1
  Yarn: 1.22.19
  pnpm: 8.15.7
Relevant Packages:
  next: 14.2.5 // Latest available version is detected (14.2.5).
  eslint-config-next: N/A
  react: 18.3.1
  react-dom: 18.3.1
  typescript: 5.5.3
Next.js Config:
  output: N/A

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

Navigation, Runtime

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

Vercel (Deployed)

Additional context

Only in production on vercel

@JClackett JClackett added the bug Issue was opened via the bug report template. label Jul 13, 2024
@github-actions github-actions bot added Navigation Related to Next.js linking (e.g., <Link>) and navigation. Runtime Related to Node.js or Edge Runtime with Next.js. labels Jul 13, 2024
@JClackett
Copy link
Contributor Author

JClackett commented Jul 13, 2024

At the same time as this error I get the:
"async/await is not yet supported in Client Components, only Server Components." error from React (https://react.dev/errors/482).

But im not using async client components, im using async in a server component as shown in the repro. But is there some caveats to that that im not aware of? I am calling a server action from the client component that renders.

But the next.js error is always coupled with this react error, so maybe theres a connection?

@JClackett
Copy link
Contributor Author

Looking into the breadcrumbs of what the user did, its not on navigating to the page, its when they submit the server action, but they did it 3 times successfully and then on the 4th time it caused these errors.

@JClackett
Copy link
Contributor Author

Screenshot 2024-08-26 at 15 24 36

Still getting this when certain users call a server action

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. Navigation Related to Next.js linking (e.g., <Link>) and navigation. Runtime Related to Node.js or Edge Runtime with Next.js.
Projects
None yet
Development

No branches or pull requests

1 participant