You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to test a websocket endpoint that uses websocket.recv() inside, but this method is throwing an exception.
Error
ERROR sanic.error:handlers.py:183 Exception occurred while handling uri: 'http:///ws'
Traceback (most recent call last):
File "/worker/.local/lib/python3.7/site-packages/sanic/app.py", line 971, in _websocket_handler
await fut
File "/app/application_tests/test_sanic_testing.py", line 18, in handler
await ws.recv()
File "/worker/.local/lib/python3.7/site-packages/sanic/server/websockets/connection.py", line 49, in recv
if message["type"] == "websocket.receive":
KeyError: 'type'
I am trying to test a websocket endpoint that uses
websocket.recv()
inside, but this method is throwing an exception.Error
How to reproduce
pytest
and see the error messageRequirements
Python 3.7
The text was updated successfully, but these errors were encountered: