#8838 Error during subtitle translation stage [Google Translate (Free)] 400 Client Error: Bad Request for url: https://edge.mi

138.84**0 Posted at: 16 hours ago

Error during subtitle translation stage [Google Translate (Free)] 400 Client Error: Bad Request for url: https://edge.microsoft.com/translate/translatetext?from=&to=tl&isEnterpriseClient=false
Traceback (most recent call last):
File "videotrans\translator\_base.py", line 79, in run
File "videotrans\translator\_base.py", line 117, in _run_text
File "tenacity\__init__.py", line 338, in wrapped_f
File "tenacity\__init__.py", line 477, in call
File "tenacity\__init__.py", line 378, in iter
File "tenacity\__init__.py", line 421, in exc_check
tenacity.RetryError: RetryError[]

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "videotrans\task\only_one.py", line 113, in run
File "videotrans\task\_stage_translate.py", line 31, in trans
File "videotrans\translator\_runner.py", line 71, in run
File "videotrans\translator\_base.py", line 85, in run
File "tenacity\__init__.py", line 480, in call
File "videotrans\translator\_microsoft.py", line 51, in _item_task
File "requests\models.py", line 1026, in raise_for_status
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://edge.microsoft.com/translate/translatetext?from=&to=tl&isEnterpriseClient=false

trk=Translation V/A 单视频模式
Select Media File: C:/Users/ADMIN/Downloads/Video/AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg.mp4,
Output Di
......
Z3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg-mp4,
self.cfg.cache_folder='C:/Users/ADMIN/Downloads/Compressed/win-pyvideotrans-v4.18/tmp/1652/e3273f6983'
Selected Clear Output, Not-Selected Enable CUDA
STT Service:faster-whisper(Built-in), large-v3-turbo, Spoken: English
Max Speech Duration (s): 5s
Min Speech Duration (ms): 3000ms
Min Silence Duration for Split (ms): 600ms
VAD Speech Threshold: 0.45
VAD Engine: silero
Compute Type:default
Beam Size:5
Best Of:5
Condition on Previous Text:False
Repetition Penalty:1.0
Compression Ratio Threshold:2.4
TranslateSrt:Google Translate (Free),Spoken:English,Target:Filipino
Traditional Translation Batch Size (Lines): 5
TTS Service:Edge-TTS (Free), Voices:Blessica(Female/PH), Target:Filipino
Volume:+0%, Speed:+0%, Selected TTS Speedup, Not-Selected Slow Video
Selected Trim Start/End Silence in Dubbed Segments
Silence Removal Intensity: default
Soft Subtitles
video duration:3787333ms
video information:{'video_fps': 30.0, 'r_frame_rate': 30.0, 'video_codec_name': 'h264', 'audio_codec_name': 'aac', 'width': 720, 'height': 1280, 'time': 3787333, 'streams_len': 2, 'streams_audio': 1, 'video_streams': 1, 'color': 'yuv420p'}
self.cfg=TaskCfgVTT(uuid='e3273f6983', name='C:/Users/ADMIN/Downloads/Video/AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg.mp4', dirname='C:/Users/ADMIN/Downloads/Video', noextname='AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg', basename='AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg.mp4', ext='mp4', target_dir='C:/Users/ADMIN/Downloads/Video/_video_out/AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg-mp4', cache_folder='C:/Users/ADMIN/Downloads/Compressed/win-pyvideotrans-v4.18/tmp/1652/e3273f6983', is_cuda=False, source_language='English', source_language_code='en', source_sub='C:/Users/ADMIN/Downloads/Video/_video_out/AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg-mp4/en.srt', source_wav='C:/Users/ADMIN/Downloads/Compressed/win-pyvideotrans-v4.18/tmp/1652/e3273f6983/en.wav', source_wav_output='C:/Users/ADMIN/Downloads/Video/_video_out/AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg-mp4/en.m4a', target_language='Filipino', target_language_code='fil', target_sub='C:/Users/ADMIN/Downloads/Video/_video_out/AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg-mp4/fil.srt', target_wav='C:/Users/ADMIN/Downloads/Compressed/win-pyvideotrans-v4.18/tmp/1652/e3273f6983/target.wav', target_wav_output='C:/Users/ADMIN/Downloads/Video/_video_out/AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg-mp4/fil.m4a', translate_type=0, tts_type=0, volume='+0%', pitch='+0Hz', voice_rate='+0%', voice_role='Blessica(Female/PH)', voice_autorate=True, video_autorate=False, remove_silent_mid=False, align_sub_audio=True, detect_language='en', recogn_type=0, model_name='large-v3-turbo', shibie_audio=None, remove_noise=False, enable_diariz=False, nums_diariz=0, rephrase=False, fix_punc=0, app_mode='biaozhun', subtitle_language=None, targetdir_mp4='C:/Users/ADMIN/Downloads/Video/_video_out/AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg-mp4/AQNZ3pkNETE1UVoPu9SEcCTCk87DQLZlSZmMn6sZ3bKOiFVNNvI6473m-dZp24DkUILFKHlfIjXS2T4cOiQ2jPb6P7SdWrLZ156DZB0b5TN8Bg.mp4', novoice_mp4='C:/Users/ADMIN/Downloads/Compressed/win-pyvideotrans-v4.18/tmp/1652/e3273f6983/novoice.mp4', is_separate=False, embed_bgm=True, instrument='C:/Users/ADMIN/Downloads/Compressed/win-pyvideotrans-v4.18/tmp/1652/e3273f6983/instrument.wav', vocal='C:/Users/ADMIN/Downloads/Compressed/win-pyvideotrans-v4.18/tmp/1652/e3273f6983/vocal.wav', clear_cache=True, background_music='', subtitle_type=2, only_out_mp4=False, recogn2pass=False, output_srt=0, copysrt_rawvideo=False, loop_backaudio=1, backaudio_volume=0.8, batch=False)
video_duration_ms=3787333


=
system:Windows-10-10.0.26300-SP0
version:v4.18
frozen:True
language:en_US
root_dir:C:/Users/ADMIN/Downloads/Compressed/win-pyvideotrans-v4.18

1 Replies

#1 DeepSeek reply at 16 hours ago

The Google Translate (Free) channel request failed (it requires a proxy in mainland China); the software then automatically fell back to Microsoft's free endpoint, and Microsoft returned 400 Bad Request for the Filipino code to=tl. In other words, the problem is at the translation channel layer, not at speech recognition or dubbing.

Solution (use any one of the following):

  1. If you are in mainland China and intend to keep using Google Translate: enter a working proxy in the Proxy box to the right of the alignment row on the main interface, for example http://127.0.0.1:7890, make sure the proxy program is running and the port is correct, then rerun with Clear Output checked.
  2. Recommended: switch the translation channel to an AI channel (for example DeepSeek). Filipino is a smaller language, and AI channels are far more fault-tolerant than traditional APIs for this kind of language and do not have language code mapping problems. Configure it in Menu → Translation Settings → DeepSeek with the API key, then select Deepseek in the translation channel drop-down and check SendSRT.
  3. Or directly switch the translation channel to Microsoft Translate (Free) and retry, to see whether it is only the fallback call that is failing.
  4. Upgrade to v4.19: the fallback and language code handling for Google/Microsoft channels have been adjusted in newer versions.

Also note by the way: the video file name is extremely long (more than 100 random characters); rename it to a short English name (for example video1.mp4) and place it in a shallow directory, otherwise errors are easily triggered in later ffmpeg stages.

Please refer to the related documentation:

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