My Next.js dev server starts hanging and I'm not sure how to debug it or get more verbose logging out of it.
I've been blindly logging network requests, changing node versions, Next.js versions, dropping timers in my next.js functions, enabling node debug mode, trying to uncover a common thread, but I'm not getting anywhere.
How do I debug this properly? Is there a way to detect open connections, any kind of stats that would be useful here with Next.js or generally speaking?
I have tried CPU profiles, memory snapshots, but am not able to interpret anything useful.
All requests to the dev server start hanging (pending) in network state. The only solution is to kill the process and restart it.
Higher level recommendations are welcome too.
The fact that I do not know how to profile the dev server itself, is currently a huge risk to any Next.js project.