Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

使用Google Gemini AI文本翻译出现未知错误 #102

Open
848244210 opened this issue Apr 29, 2024 · 2 comments
Open

使用Google Gemini AI文本翻译出现未知错误 #102

848244210 opened this issue Apr 29, 2024 · 2 comments

Comments

@848244210
Copy link

0%| | 0/607 [00:02<?, ?it/s]未知错误,用户可以尝试查看报错信息并在Repository里提交issue
Unknown Error, please check the error log and open an issue in the repository


TypeError Traceback (most recent call last)
in <cell line: 97>()
95 t = SubtitleTranslator(sub_src=sub_name)
96
---> 97 translation, _, = t.translate_by_line()
98
99 if output_format == 'ass':

in translate_by_line(self)
81 for line in tqdm(sub_trans,total = total_lines):
82 line_trans = translate(prompt, target_language, line.text)
---> 83 line.text += (r'\N'+ line_trans)
84 print(line_trans)
85 self.translations.append(line_trans)

TypeError: can only concatenate str (not "NoneType") to str

@CooperWang0912
Copy link
Contributor

应该是Runtime出问题了,你可以试一下reconnect runtime然后再执行这个单元格

@eddiehex
Copy link

我也出现这个问题,好像是代理地址不支持api使用,我切到别的地区就好了,另外gemini free 有请求限制每分钟15次,每天1500。
请求过多就会报错WARNING:tornado.access:429 POST

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants