twilio / media-streams

Quick start guides for configuring and consuming Twilio Media Streams
100 stars 81 forks source link

Python streaming implementation not working #137

Closed Abner-01 closed 2 years ago

Abner-01 commented 2 years ago

Hi, I'm currently testing the python's media streaming implementation, but I can't make them work. I've followed all the instructions, but when the wss protocol is called, an error occurred:

Server listening on: http://localhost:5000
POST TwiML
Traceback (most recent call last):
  File "C:\ProgramData\Anaconda3\lib\site-packages\gevent\pywsgi.py", line 999, in handle_one_response
    self.run_application()
  File "C:\ProgramData\Anaconda3\lib\site-packages\geventwebsocket\handler.py", line 75, in run_application
    self.run_websocket()
  File "C:\ProgramData\Anaconda3\lib\site-packages\geventwebsocket\handler.py", line 52, in run_websocket
    list(self.application(self.environ, lambda s, h, e=None: []))
  File "C:\ProgramData\Anaconda3\lib\site-packages\flask\app.py", line 2309, in __call__
    return self.wsgi_app(environ, start_response)
  File "C:\ProgramData\Anaconda3\lib\site-packages\flask_sockets.py", line 40, in __call__
    handler, values = adapter.match()
  File "C:\ProgramData\Anaconda3\lib\site-packages\werkzeug\routing.py", line 2039, in match
    raise WebsocketMismatch()
werkzeug.routing.WebsocketMismatch: 400 Bad Request: The browser (or proxy) sent a request that this server could not understand.
2022-01-27T17:52:07Z {'REMOTE_ADDR': '::1', 'REMOTE_PORT': '62875', 'HTTP_HOST': '3349-2806-106e-25-b83-b4b5-be2e-b5fd-9e42.ngrok.io', (hidden keys: 28)} failed with WebsocketMismatch

Has anything been changed?, am I doing something wrong?