I have a NextJS site running in an Azure Web App. It spams this error message to the terminal every 3 seconds or so:
TypeError: result.pipeToNodeResponse is not a function
at Object.sendRenderResult (/home/site/wwwroot/node_modules/next/dist/server/send-payload.js:118:18)
at NextNodeServer.sendRenderResult (/home/site/wwwroot/node_modules/next/dist/server/next-server.js:368:34)
at NextNodeServer.pipe (/home/site/wwwroot/node_modules/next/dist/server/base-server.js:380:25)
at async Object.fn (/home/site/wwwroot/node_modules/next/dist/server/next-server.js:727:21)
at async Router.execute (/home/site/wwwroot/node_modules/next/dist/server/router.js:247:36)
at async NextNodeServer.run (/home/site/wwwroot/node_modules/next/dist/server/base-server.js:346:29)
at async NextNodeServer.handleRequest (/home/site/wwwroot/node_modules/next/dist/server/base-server.js:284:20)
I tried looking through the NextJS source code but wasn’t able to track down a cause for this issue. The site itself returns a 500 if you try to visit it.
Info:
Node: 18 LTS
Next: 12.3.0
What might cause such an error?