I have a project with CloudFlare Workers and I use their Wrangler CLI tool to test them locally. I'm working in a WSL2 environment; Ubuntu 22.04 with Windows 11 as the host.
I had an error in my code that caused Wrangler to crash and exit immediately; no graceful shutdown. When I restarted it, I got the following error and my workers would no longer run.
MiniflareCoreError [ERR_RUNTIME_FAILURE]: The Workers runtime failed to start
How can I fix this error so that Wrangler will start properly again?
Since I'm in a Linux environment in WSL2, I was able to run the following command to kill the worker daemon.
killall workerd
According to this post on the CloudFlare forums, this should also work in MacOS.