-
Notifications
You must be signed in to change notification settings - Fork 86
[Bug]: ___netlify-handler fails with boilerplate NX Mono Repo #1278
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
Comments
Thanks for the report. This looks like it was a regression introduced in version 4.2.8 of the plugin. Could you try downgrading it to |
I'm having the same error after upgrading the plugin in UI. |
Hey. You shoudl install it in your package.json. Something like |
Doing the following fixes my issues. Hopefully latest version of the plugin is fixed soon! Thanks @ascorbic! |
Same here, downgrading the plugin solved the issue. |
This worked for me. For those who don't have |
Summary
After minimal NX Workspace setup with a boilerplate NextJS project generated, ___netlify-handler errors out/fails for all invokations, despite successful deployment.
TLDR: NextJS API Routes are not working, due to ___netlify-handler errors.
{"errorType":"Error","errorMessage":"ENOENT: no such file or directory, chdir '/var/task' -> '/var/task/apps/frontend'","trace":["Error: ENOENT: no such file or directory, chdir '/var/task' -> '/var/task/apps/frontend'"," at process.wrappedChdir [as chdir] (internal/bootstrap/switches/does_own_process_state.js:116:14)"," at /var/task/.netlify/functions-internal/___netlify-handler/___netlify-handler.js:19:13"," at Object.<anonymous> (/var/task/.netlify/functions-internal/___netlify-handler/___netlify-handler.js:106:3)"," at Module._compile (internal/modules/cjs/loader.js:1085:14)"," at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)"," at Module.load (internal/modules/cjs/loader.js:950:32)"," at Function.Module._load (internal/modules/cjs/loader.js:790:12)"," at Module.require (internal/modules/cjs/loader.js:974:19)"," at require (internal/modules/cjs/helpers.js:93:18)"," at Object.<anonymous> (/var/task/___netlify-handler.js:1:18)"]}
Steps to reproduce
Add a general api route
/api/index.tsx
Deployed using Netlify Web GUI
A link to a reproduction repository
https://github.com/Joroze/nx-netlify-test
Plugin version
4.2.8
More information about your build
netlify.toml
)What OS are you using?
No response
Your netlify.toml file
`netlify.toml`
# Paste content of your `netlify.toml` file here
Your public/_redirects file
`_redirects`
# Paste content of your `_redirects` file here
Your
next.config.js
file`next.config.js`
Builds logs (or link to your logs)
Build logs
Function logs
Function logs
.next JSON files
generated .next JSON files
The text was updated successfully, but these errors were encountered: