rany2 / edge-tts

Use Microsoft Edge's online text-to-speech service from Python WITHOUT needing Microsoft Edge or Windows or an API key
https://pypi.org/project/edge-tts/
GNU General Public License v3.0
4.24k stars 447 forks source link

edge_tts.exceptions.NoAudioReceived #140

Closed Codehimn closed 8 months ago

Codehimn commented 9 months ago

since the last days all this list of voices are not working, and just returning:

"edge_tts.exceptions.NoAudioReceived: No audio was received. Please verify that your parameters are correct."

ar-IQ-BasselNeural ar-JO-TaimNeural ar-LY-OmarNeural ar-OM-AbdullahNeural ar-OM-AyshaNeural ar-QA-MoazNeural ar-SY-AmanyNeural ar-SY-LaithNeural ar-TN-HediNeural ar-TN-ReemNeural ar-YE-SalehNeural en-KE-AsiliaNeural en-KE-ChilembaNeural en-NG-AbeoNeural en-NG-EzinneNeural en-PH-JamesNeural en-PH-RosaNeural en-SG-LunaNeural en-SG-WayneNeural en-TZ-ElimuNeural en-TZ-ImaniNeural en-ZA-LeahNeural en-ZA-LukeNeural es-AR-ElenaNeural es-AR-TomasNeural es-CL-LorenzoNeural es-CO-GonzaloNeural es-CO-SalomeNeural es-CU-ManuelNeural es-GQ-JavierNeural zh-CN-liaoning-XiaobeiNeural zh-CN-shaanxi-XiaoniNeural

Codehimn commented 9 months ago

Additionally, the 'Read aloud' option is also not functioning in the Edge browser. (for any voice from the previous list)

rany2 commented 9 months ago

I'm not entirely sure why this happens but it does appear like a retry gets it to work. Most likely they are having server issues.

rany2 commented 9 months ago

I'm reopening this because I believe the retry should be handled by edge-tts. So I think it's a valid issue/something to document as well.

Codehimn commented 9 months ago

ok, so a little more of info:

I've confirmed that the error originated directly from Microsoft, (as the same issue was also present in Edge). I opened an issue to report this, and it appears to have been resolved after a few days (but the ticket still open, so maybe not fully solved). (it seems to have random errors when you use multi-threading requests, but works fine most of the time just with one in parallel).

Microsoft Ticket: https://answers.microsoft.com/en-us/microsoftedge/forum/msedge_other-msedge_win11/error-with-read-aloud-on-edge-is-it-a-global-issue/8a4c7eb7-18fc-4fa9-bfbe-f9941a616fd7?messageId=d3682b67-1aad-4887-9214-dc4ecc10a161

rany2 commented 9 months ago

it seems to have random errors when you use multi-threading requests, but works fine most of the time just with one in parallel

Hmm, the strange thing is sending the requests in parallel 50 requests at a time for https://github.com/rany2/edge-srt-to-speech appears to work just fine for me. So it doesn't appear to be the case for my region.

Anyway the fact that official Edge doesn't seem to handle this properly makes me less inclined to want to try to workaround this. I'll wait a bit more to see if it gets fixed on their end before trying out workarounds.

rany2 commented 8 months ago

Reopen this if this issue is still relevant.