Closed Krognol closed 6 years ago
Possibly a bad client. You may wish to try putting your service behind a reverse proxy like nginx.
Seems strange to me that I'd have to go through those hoops just to have it stay running without problems.
Could it be something else?
Looking at the stack trace, I'm not immediately seeing any websockets-related frames in it. Could this be a issue in the asyncnet module?
That said, this library will raise exceptions when something is wrong with the data that the client sent you. You need to handle them properly if you want your server to stay up; i.e. try/except around recvFrame and friends. You can then do whatever you wish with their connection. No need to put a reverse proxy in front (though it may be a good idea regardless).
If this doesn't solve your issue, please post the relevant code snippet to have a look at.
I'll re-post the issue in Nim's repo and close it here.
This error can appear anywhere between a few hours to a few days, but it's always the same and I can't find the cause for it.