#8140 网络连接失败:{'text': '你好啊,我亲爱的朋友,希望你的每一天都是美好愉快的!', 'rate': '+0%', 'role': 'Yunyang(Male/CN)', 'filename': 'C:\\Users\\Adminis

103.151**4 Posted at: 1 hour ago

网络连接失败:
{'text': '你好啊,我亲爱的朋友,希望你的每一天都是美好愉快的!', 'rate': '+0%', 'role': 'Yunyang(Male/CN)', 'filename': 'C:\Users\Administrator\AppData\Local\Temp/pyvideotrans/0-1792026533.2028365.wav', 'tts_type': 0, 'language': 'zh-cn', 'volume': '+0%', 'pitch': '+0Hz'}
Traceback (most recent call last):
File "edge_tts\communicate.py", line 566, in stream
File "edge_tts\communicate.py", line 431, in __stream
File "aiohttp\client.py", line 1482, in aenter
File "aiohttp\client.py", line 1078, in _ws_connect
aiohttp.client_exceptions.WSServerHandshakeError: 403, message='Invalid response status', url='wss://speech.platform.bing.com/consumer/speech/synthesize/readaloud/edge/v1?TrustedClientToken=6A5AA1D4EAFF4E9FB37E23D68491D6F4&ConnectionId=61917e7847ba4664b01450fd43bab4e3&Sec-MS-GEC=F2FC3F4D20490C216C7EA4882FC4A727B0C25A3FF0D454BD3047145F1014D239&Sec-MS-GEC-Version=1-143.0.3650.75'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "videotrans\util\ListenVoice.py", line 21, in run
File "videotrans\tts\__init__.py", line 233, in run
File "videotrans\tts\_base.py", line 100, in run
File "asyncio\runners.py", line 44, in run
File "asyncio\base_events.py", line 649, in run_until_complete
File "videotrans\tts\_edgetts.py", line 154, in _exec
File "edge_tts\communicate.py", line 590, in save
File "edge_tts\communicate.py", line 573, in stream
File "edge_tts\communicate.py", line 431, in __stream
File "aiohttp\client.py", line 1482, in aenter
File "aiohttp\client.py", line 1078, in _ws_connect
aiohttp.client_exceptions.WSServerHandshakeError: 403, message='Invalid response status', url='wss://speech.platform.bing.com/consumer/speech/synthesize/readaloud/edge/v1?TrustedClientToken=6A5AA1D4EAFF4E9FB37E23D68491D6F4&ConnectionId=fad9900c8a44455f86cbeec11a4cad5c&Sec-MS-GEC=F2FC3F4D20490C216C7EA4882FC4A727B0C25A3FF0D454BD3047145F1014D239&Sec-MS-GEC-Version=1-143.0.3650.75'


=
system:Windows-10-10.0.19045-SP0
version:v4.11
frozen:True
language:zh
root_dir:D:/SYS/Downloads/win-pyvideotrans-v4.11

1 Replies

#1 DeepSeek reply at 1 hour ago

这是由于 Edge-TTS 免费接口的验证逻辑已变更,您当前 v4.11 版本无法适配,导致微软服务器返回 403 错误。请升级到 v4.16 版本修复。

解决方法:

  1. 前往 https://pyvideotrans.com/downpackage 下载 v4.16 最新完整包或补丁包覆盖。
  2. 下载后完整释放到原目录并覆盖全部文件,重新启动 sp.exe 后再试。
  3. 如果不想升级,可改用其他配音渠道,如 gTTS(需科学上网)或本地配音渠道 Qwen3-TTS/F5-TTS 等。

注意:源码部署用户可执行 uv add git+https://github.com/rany2/edge-tts.git 更新;若报错,先执行 uv remove edge-tts 再重新更新。

请查阅相关文档:

Thinking...
Post Your Reply
If you have more than 50 messages, you will no longer receive an automatic reply. Please ask a new question!
Open source and free maintenance is not easy. If this project is helpful to you, please consider making a small donation to help the project continue to maintain and update.

Dondate via ko-fi.com

Related resource