-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Raise a error if web-handler returned non-response in debug mode. #3311
Comments
GitMate.io thinks possibly related issues are #255 (Handling WebSocket disconnects), #1661 (Client exceptions refactoring), #3223 (Should not throw exception for EofStream Exception in WebSocket.), #2368 (Can't detect disconnection on wifi websocket client ), and #3291 (Websocket client hanging/blocking?). |
I have same issue with streaming response. |
Guys, looks like you both don't return a response object from failed web-handler. |
Thanks @asvetlov I was missing the return statement at the end of the handler https://aiohttp.readthedocs.io/en/stable/web_quickstart.html#websockets |
That's exactly what I was suspected. The patch is trivial, a champion is needed. |
@asvetlov please review above patch, I saw no use of |
The idea is dropping custom debug checks everywhere in the server and rely on |
Fixed by #3321 |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a [new issue] for related bugs. |
Long story short
Opening this as mentioned here: #3223 (comment)
Expected behaviour
It should't trow
Actual behaviour
There's an unhandled exception thrown
Steps to reproduce
This happens in a websocket route handler when a client disconnects
Your environment
aiohttp 3.4.4
OS centos
no proxy
The text was updated successfully, but these errors were encountered: