#7786 Network connection failedTraceback (most recent call last):

187.40**7 Posted at: 5 hours ago

Network connection failed
Traceback (most recent call last):
File "httpx\_transports\default.py", line 101, in map_httpcore_exceptions
File "httpx\_transports\default.py", line 250, in handle_request
File "httpcore\_sync\connection_pool.py", line 216, in handle_request
File "httpcore\_sync\connection_pool.py", line 196, in handle_request
File "httpcore\_sync\connection.py", line 101, in handle_request
File "httpcore\_sync\http11.py", line 143, in handle_request
File "httpcore\_sync\http11.py", line 113, in handle_request
File "httpcore\_sync\http11.py", line 186, in _receive_response_headers
File "httpcore\_sync\http11.py", line 238, in _receive_event
httpcore.RemoteProtocolError: Server disconnected without sending a response.

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

Traceback (most recent call last):
File "google\genai\_gaos\basesdk.py", line 269, in do

http_res = client.send(req, stream=stream)

File "httpx\_cl
......
line 480, in call
File "videotrans\translator\_gemini.py", line 50, in _item_task
File "google\genai\_gaos\google_genai.py", line 278, in create

response = wrap_sdk_call(

File "google\genai\_gaos\lib\compat_errors.py", line 368, in wrap_sdk_call

return fn(*args, **kwargs)

File "google\genai\_gaos\interactions.py", line 714, in create

http_res = self.do_request(

File "google\genai\_gaos\basesdk.py", line 291, in do_request

http_res = utils.retry(do, utils.Retries(retry_config[0], retry_config[1]))

File "google\genai\_gaos\utils\retries.py", line 264, in retry

return retry_with_attempt_count_backoff(

File "google\genai\_gaos\utils\retries.py", line 399, in retry_with_attempt_count_backoff

raise exception.inner

File "google\genai\_gaos\utils\retries.py", line 231, in do_request

res = func(attempt)

File "google\genai\_gaos\basesdk.py", line 274, in do

raise e

google.genai._gaos.lib.compat_errors.APIConnectionError: Server disconnected without sending a response.

cfg=[TaskCfgVTT]当前工作模式: 翻译视频 单视频模式
原始输入文件名: C:/Users/Shah/Downloads/Video/China release first fully AI-produced long-form drama series, Beyong Wukong by Mango TV (30sec clip turned into 40min ep) AI - ResetEra.mp4,
输出结果保存到文件夹: C:/Users/Shah/Downloads/Video/_video_out/China release first fully AI-produced long-form drama series, Beyong Wukong by Mango TV (30sec clip turned into 40min ep) AI - ResetEra-mp4,
临时文件夹: C:/Users/Shah/Desktop/Pyvideotrans/tmp/38120/8ffc85d307
已选 清理已存在
已启用CUDA加速
未选 降噪
STT Service:faster-whisper(Built-in), large-v3-turbo, 发音语言: Simplified Chinese, 断句方式:默认断句
TranslateSrt:Gemini AI,原始语言:Simplified Chinese,目标语言:Hindi, 已选 SendSRT
TTS Service:Edge-TTS (Free), 角色:Swara(Female/IN), 配音语言:Hindi, 未选 二次语音识别
音量:+0%, 语速:+0%, 已选 音频加速, 未选 视频慢速
字幕: Soft Subtitles
video_duration_ms=139583


=
system:Windows-10-10.0.19045-SP0
version:v4.14
frozen:True
language:en_US
root_dir:C:/Users/Shah/Desktop/Pyvideotrans

1 Replies

#1 DeepSeek reply at 5 hours ago

The root cause is a network connection failure when calling the Gemini AI translation API.

The error Server disconnected without sending a response means the request to Google's Gemini endpoint could not be completed — this is a network/proxy issue, not a software bug.

Gemini is a Google service and is blocked in mainland China.

Even outside China, an unstable proxy/VPN will cause exactly this error.

Solution (in order):

  1. Verify proxy is working: Gemini requires a stable proxy/VPN.

    Open the proxy text box on the main interface (right side of the Alignment row) and fill in a valid HTTP proxy, e.g.

    http://127.0.0.1:10808.

    Make sure the proxy service is actually running and the port is correct.

    An invalid/empty-but-filled proxy will make all requests fail.
  2. Test your network against Google: Confirm you can reach Google services reliably.

    If your proxy node is unstable, large/streaming Gemini requests will be cut off mid-response.

    Switch to a cleaner, more stable node.
  3. Switch translation provider (recommended if you don't have a reliable proxy): Change the TranslateSrt channel from Gemini AI to a provider reachable without proxy, e.g.:

    • DeepSeek (requires API key, very low cost, no proxy needed)
    • Microsoft Translate or Google Translate (Google still needs proxy)
    • M2M100 (Built-in) local model (fully offline, first use downloads model)

    Your target language is Hindi.

    Hindi is a common language, so these traditional providers will work fine.

  4. Reduce batch size if it still drops mid-way: In Menu → Tools/Options → Advanced Options → Translation, lower Batch size (lines) for AI translation to a smaller value (e.g.

    10), so each request is smaller and less likely to be cut off by an unstable connection.
  5. Retry: After fixing the proxy or switching providers, check Clear Output on the main interface and re-run.

请查阅相关文档:

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