-
Notifications
You must be signed in to change notification settings - Fork 64
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
Deepgram SDK Fails with WebSocket Version 14.0 - Unexpected Keyword Argument extra_headers #483
Comments
Yeah have the same problem, fixing to version 13.1 solves the problem for me pushing back deepgram version does not. |
Having the same problem, staying on major version 13 resolved the issue |
The issue seems to be that the Python websockets library seems to accept |
Maybe it should look through the args for "extra headers, additional headers, more headers, suplementary headers" |
What is the current behavior?
When using the Deepgram SDK with WebSocket version 14.0, the connection fails, and the following error is raised:TypeError: got an unexpected keyword argument 'extra_headers'.
However, Deepgram works fine with WebSocket version 13.1.
Steps to reproduce
Install WebSocket version 14.0
pip install websockets==14.0
Set up a Deepgram connection using the SDK.
pip install deepgram-sdk==3.7.6
Attempt to create a connection to Deepgram's API using
deepgram: DeepgramClient = DeepgramClient(DeepgramClientOptions(options={"keepalive": "true"} ))
dg_connection = deepgram.listen.asyncwebsocket.v("1")
options: LiveOptions = LiveOptions( model="nova-2-general", smart_format=True, punctuate=True, encoding="linear16", channels=1, sample_rate=8000, vad_events=True, )
dg_connection.start(options=options)
Observe the error: TypeError: got an unexpected keyword argument 'extra_headers'.
Expected behavior
The connection should be established successfully without any errors when using WebSocket version 14.0, similar to the behavior with version 13.1.
Please tell us about your environment
MacOS 14.6.1
python version v3.12.6
Other information
The text was updated successfully, but these errors were encountered: