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

Error: Failed to find Server Action "84c...c2". This request might be from an older or newer deployment. Original error: Cannot read properties of undefined (reading 'workers') #70229

Open
72L opened this issue Sep 18, 2024 · 0 comments
Labels
bug Issue was opened via the bug report template.

Comments

@72L
Copy link

72L commented Sep 18, 2024

Link to the code that reproduces this issue

https://github.com/72L/failed-to-find-server-action

To Reproduce

  1. Deploy repro repo to Heroku app: heroku git:remote -a [your-app] and git push heroku main
  2. Test that it works and keep this tab open (do not refresh)
  3. Make an insignificant change (i.e. modify the readme or add a space)
  4. deploy to heroku again git push heroku main
  5. Do not refresh tab from step 2!
  6. After successful deploy, test the app. The server action is now unresponsive.
  7. Look into logs and see something like this:
2024-09-18T19:54:44.246958+00:00 app[web.1]: Error: Failed to find Server Action "84c3beb04922e6ef5f718f755f306f3e442d01c2". This request might be from an older or newer deployment. Original error: Cannot read properties of undefined (reading 'workers')
2024-09-18T19:54:44.246972+00:00 app[web.1]: at r$ (/app/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:16:1766)
2024-09-18T19:54:44.246972+00:00 app[web.1]: at /app/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:15:8948
2024-09-18T19:54:44.246972+00:00 app[web.1]: at AsyncLocalStorage.run (node:async_hooks:346:14)
2024-09-18T19:54:44.246973+00:00 app[web.1]: at rT (/app/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:15:8156)
2024-09-18T19:54:44.246973+00:00 app[web.1]: at ne (/app/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:18:1150)
2024-09-18T19:54:44.246973+00:00 app[web.1]: at /app/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:19:726
2024-09-18T19:54:44.246973+00:00 app[web.1]: at AsyncLocalStorage.run (node:async_hooks:346:14)
2024-09-18T19:54:44.246974+00:00 app[web.1]: at Object.wrap (/app/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:13:17831)
2024-09-18T19:54:44.246975+00:00 app[web.1]: at /app/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:19:616
2024-09-18T19:54:44.246975+00:00 app[web.1]: at AsyncLocalStorage.run (node:async_hooks:346:14)

Current vs. Expected behavior

I would expect the outcome of step 2 to be the same as the outcome of step 6.

Provide environment information

Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 23.4.0: Fri Mar 15 00:12:41 PDT 2024; root:xnu-10063.101.17~1/RELEASE_ARM64_T8103
  Available memory (MB): 16384
  Available CPU cores: 8
Binaries:
  Node: 18.20.2
  npm: 10.5.0
  Yarn: 1.22.19
  pnpm: 6.29.0
Relevant Packages:
  next: 14.2.12 // Latest available version is detected (14.2.12).
  eslint-config-next: 14.2.12
  react: 18.3.1
  react-dom: 18.3.1
  typescript: 5.6.2
Next.js Config:
  output: N/A

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

Not sure

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

Other (Deployed)

Additional context

It does work on Vercel, but not Heroku. I've tried some ideas from #58431 but none of them solved this issue.

@72L 72L added the bug Issue was opened via the bug report template. label Sep 18, 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.
Projects
None yet
Development

No branches or pull requests

1 participant