Nope, I followed your Flask repo and did that same. But I really want to run that in just Python and not on Flask. I do have limited knowledge on asyncio. Will be learning that soon. I've shared the error and the complete code I'm using the same thread.
Sorry to misled you!
Actually I wanted to directly send the audio feed using PyAudio to the Deepgram websocket (that's when the above error is occurring).
But I found your Flask tutorial and used that instead which worked in the first go.
Oh nice! Good to hear you found a solution with the tutorial 😄.
About asyncio, yea, I totally understand it can be very confusing. It took me awhile to wrap my head around it. How do you plan on learning asyncio? Tutorials? Blog posts? Videos? Something else?
Gonna read through this for a while and try some hands-on stuff. docs.python.org/3/library/asyncio....
I'll try to make a tutorial here once I get a good grasp.
Nope, I followed your Flask repo and did that same. But I really want to run that in just Python and not on Flask. I do have limited knowledge on asyncio. Will be learning that soon. I've shared the error and the complete code I'm using the same thread.
Ok, so if I understand correctly you follwed the Flask example in the tutorial but still having some issues? Is the issue still with PyAudio?
Also, is this the error message you received? (I want to make sure this is the correct error):
input_audio = stream_in.read(3200)
await ws.send(input_audio)
DEBUG:websockets.client:< CLOSE 1008 (policy violation) DATA-0000 [11 bytes]
Sorry to misled you!
Actually I wanted to directly send the audio feed using PyAudio to the Deepgram websocket (that's when the above error is occurring).
But I found your Flask tutorial and used that instead which worked in the first go.
The complete code I used can be found here.
Oh nice! Good to hear you found a solution with the tutorial 😄.
About asyncio, yea, I totally understand it can be very confusing. It took me awhile to wrap my head around it. How do you plan on learning asyncio? Tutorials? Blog posts? Videos? Something else?
Gonna read through this for a while and try some hands-on stuff.
docs.python.org/3/library/asyncio....
I'll try to make a tutorial here once I get a good grasp.
Wonderful! Make sure to let me know when it's published so I can read it :)
You got it!