#2390 requests.exceptions.ConnectionError: HTTPConnectionPool(host='127.0.0.1', port=9880): Max retries exceeded with url: /tt

104.28* Posted at: 2 hours ago 👁6

连接被拒绝,请确保本地服务已启动并正在运行:
Traceback (most recent call last):
File "urllib3\connection.py", line 198, in _new_conn
File "urllib3\util\connection.py", line 85, in create_connection
File "urllib3\util\connection.py", line 73, in create_connection
ConnectionRefusedError: [WinError 10061] 由于目标计算机积极拒绝,无法连接。

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "urllib3\connectionpool.py", line 787, in urlopen
File "urllib3\connectionpool.py", line 493, in _make_request
File "urllib3\connection.py", line 494, in request
File "http\client.py", line 1277, in endheaders
File "http\client.py", line 1037, in _send_output
File "http\client.py", line 975, in send
File "urllib3\connection.py", line 325, in connect
File "urllib3\connection.py", line 213, in _new_conn
urllib3.exceptions.NewConnectionError: : Failed to establish a new connection: [WinError 10061] 由于目标计算机积极拒绝,无法连接。

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "requests\adapters.py", line 644, in send
File "urllib3\connectionpool.py", line 841, in urlopen
File "urllib3\util\retry.py", line 519, in increment
urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='127.0.0.1', port=9880): Max retries exceeded with url: /tts?text=%E4%BD%A0%E5%A5%BD%E5%95%8A%E6%88%91%E7%9A%84%E6%9C%8B%E5%8F%8B.+&text_lang=zh&ref_audio_path=yingyufanben.wav&prompt_text=Before+we+begin%2C+you+will+need+a+few+things.+First%2C+of+course%2C+is+your+ThinkPad+X220%2C+a+USB+drive+at+least+8GB+to+create+our+bootable+installer.+&prompt_lang=en&speed_factor=1.0 (Caused by NewConnectionError(': Failed to establish a new connection: [WinError 10061] 由于目标计算机积极拒绝,无法连接。'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "videotrans\util\ListenVoice.py", line 18, in run
File "videotrans\tts\__init__.py", line 284, in run
File "videotrans\tts\_base.py", line 179, in run
File "videotrans\tts\_base.py", line 208, in _local_mul_thread
File "videotrans\tts\_gptsovits.py", line 97, in _item_task
File "requests\api.py", line 73, in get
File "requests\api.py", line 59, in request
File "requests\sessions.py", line 589, in request
File "requests\sessions.py", line 703, in send
File "requests\adapters.py", line 677, in send
requests.exceptions.ConnectionError: HTTPConnectionPool(host='127.0.0.1', port=9880): Max retries exceeded with url: /tts?text=%E4%BD%A0%E5%A5%BD%E5%95%8A%E6%88%91%E7%9A%84%E6%9C%8B%E5%8F%8B.+&text_lang=zh&ref_audio_path=yingyufanben.wav&prompt_text=Before+we+begin%2C+you+will+need+a+few+things.+First%2C+of+course%2C+is+your+ThinkPad+X220%2C+a+USB+drive+at+least+8GB+to+create+our+bootable+installer.+&prompt_lang=en&speed_factor=1.0 (Caused by NewConnectionError(': Failed to establish a new connection: [WinError 10061] 由于目标计算机积极拒绝,无法连接。'))


=
system:Windows-10-10.0.19045-SP0
version:v3.92
frozen:True
language:zh
root_dir:D:/TTS/win-pyvideotrans-v3.92

1 Replies

您在使用 GPT-SoVITS 进行语音克隆配音时,遇到了“连接被拒绝”的错误。这表明软件无法连接到您本地运行的 GPT-SoVITS 服务。

核心原因:GPT-SoVITS 服务未启动或端口不匹配。

请按以下步骤排查和解决:

  1. 启动 GPT-SoVITS 服务

    • 确保您已经正确部署并启动了 GPT-SoVITS 项目。
    • 在命令行中,进入您的 GPT-SoVITS 项目目录,并运行启动命令(通常是 python api.py 或类似命令)。
    • 关键验证:服务成功启动后,在浏览器中访问 http://127.0.0.1:9880(或您配置的其他端口),应该能看到 GPT-SoVITS 的 Web 界面或 API 提示。如果无法访问,说明服务未正确启动。
  2. 检查端口号

    • 错误日志显示软件正在尝试连接 127.0.0.1:9880
    • 请确认您的 GPT-SoVITS 服务监听的端口号确实是 9880。如果您的服务运行在其他端口(例如 7860),需要在 pyVideoTrans 中进行配置。
  3. 在 pyVideoTrans 中配置 GPT-SoVITS 地址

    • 在 pyVideoTrans 主界面,点击 “设置更多参数” 或进入 菜单 -> 工具 -> 设置
    • 找到 “GPT-SoVITS 配置” 区域。
    • “API地址” 修改为您本地 GPT-SoVITS 服务实际运行的地址和端口,例如 http://127.0.0.1:9880(如果端口是 9880)或 http://127.0.0.1:7860(如果端口是 7860)。
    • 保存设置并重试。

总结操作顺序:先确保 GPT-SoVITS 服务独立运行成功并可访问 -> 然后在 pyVideoTrans 中正确配置该服务的地址。

如果以上步骤无法解决,请提供您启动 GPT-SoVITS 服务的命令行输出截图。

请查看更多参考文档:

Post Your Reply
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.

Donate: https://ko-fi.com/jianchang512

Similar issues already exist

Trending Questions