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

请求过多报错 #37

Open
StillForever opened this issue Sep 16, 2021 · 10 comments
Open

请求过多报错 #37

StillForever opened this issue Sep 16, 2021 · 10 comments

Comments

@StillForever
Copy link

以前能用现在提示
Errrrrrrrrror: HTTPSConnectionPool(host='translate.google.com', port=443): Max retries exceeded with url: /translate_a/single?client=webapp&sl=auto&tl=zh-CN&hl=en&dt=at&dt=bd&dt=ex&dt=ld&dt=md&dt=qca&dt=rw&dt=rm&dt=sos&dt=ss&dt=t&ssel=0&tsel=0&kc=1&tk=523228.82798&q=Konstantin (Caused by ConnectTimeoutError(, 'Connection to translate.google.com timed out. (connect timeout=5)'))

在session = requests.session()后面加过 session.keep_alive = False requests.adapters.DEFAULT_RETRIES = 5 无效果,url之类的语句没摸清,无从下手,特地来这里问问老哥们,何解 ?

@JohanChane
Copy link

实测 python -m googletranslate zh-CN "word" -s "translate.google.cn" 要代理才行。

用浏览器访问 https://translate.google.cn/translate_a/single?client=webapp&sl=auto&tl=zh-CN&hl=en&dt=at&dt=bd&dt=ex&dt=ld&dt=md&dt=qca&dt=rw&dt=rm&dt=sos&dt=ss&dt=t&ssel=0&tsel=0&kc=1&tk=659074.833072&q=word 时,我的自动代理 swithyomega 要对 *.google.com 使用代理才行。不知道是作者的 url 的问题,还是谷歌翻译的问题。

@xiaoWangBaAgain
Copy link

以前能用现在提示
Errrrrrrrrror: HTTPSConnectionPool(host='translate.google.com', port=443): Max retries exceeded with url: /translate_a/single?client=webapp&sl=auto&tl=zh-CN&hl=en&dt=at&dt=bd&dt=ex&dt=ld&dt=md&dt=qca&dt=rw&dt=rm&dt=sos&dt=ss&dt=t&ssel=0&tsel=0&kc=1&tk=523228.82798&q=Konstantin (Caused by ConnectTimeoutError(, 'Connection to translate.google.com timed out. (connect timeout=5)'))

在session = requests.session()后面加过 session.keep_alive = False requests.adapters.DEFAULT_RETRIES = 5 无效果,url之类的语句没摸清,无从下手,特地来这里问问老哥们,何解 ?

我也是这个问题,也是最近几天出现的,使用某些梯子就可以,不使用就不行

@MarkZhangGZ
Copy link

以前能用现在提示
Errrrrrrrrror: HTTPSConnectionPool(host='translate.google.com', port=443): Max retries exceeded with url: /translate_a/single?client=webapp&sl=auto&tl=zh-CN&hl=en&dt=at&dt=bd&dt=ex&dt=ld&dt=md&dt=qca&dt=rw&dt=rm&dt=sos&dt=ss&dt=t&ssel=0&tsel=0&kc=1&tk=523228.82798&q=Konstantin (Caused by ConnectTimeoutError(, 'Connection to translate.google.com timed out. (connect timeout=5)'))
在session = requests.session()后面加过 session.keep_alive = False requests.adapters.DEFAULT_RETRIES = 5 无效果,url之类的语句没摸清,无从下手,特地来这里问问老哥们,何解 ?

我也是这个问题,也是最近几天出现的,使用某些梯子就可以,不使用就不行

非常感谢,使用梯子才可以。使用proxychains python -m googletranslate zh-CN "word" -s "translate.google.cn"就可以正常访问了

@JohanChane
Copy link

JohanChane commented Sep 24, 2021

如果是 linux 系统,可以先用 translate-shell 代替。

# ### goldendict 添加程序(纯文本)   
# ### 中文翻译
trans -e google -l zh -t zh -no-ansi -show-translation-phonetics n -show-prompt-message n -show-alternatives n '%GDWORD%'
# ### 英文翻译
trans -e google -l zh -t en -no-ansi -show-original-phonetics n -show-prompt-message n -show-alternatives n '%GDWORD%'

@zququ
Copy link

zququ commented Oct 28, 2021

以前能用现在提示
Errrrrrrrrror: HTTPSConnectionPool(host='translate.google.com', port=443): Max retries exceeded with url: /translate_a/single?client=webapp&sl=auto&tl=zh-CN&hl=en&dt=at&dt=bd&dt=ex&dt=ld&dt=md&dt=qca&dt=rw&dt=rm&dt=sos&dt=ss&dt=t&ssel=0&tsel=0&kc=1&tk=523228.82798&q=Konstantin (Caused by ConnectTimeoutError(, 'Connection to translate.google.com timed out. (connect timeout=5)'))
在session = requests.session()后面加过 session.keep_alive = False requests.adapters.DEFAULT_RETRIES = 5 无效果,url之类的语句没摸清,无从下手,特地来这里问问老哥们,何解 ?

我也是这个问题,也是最近几天出现的,使用某些梯子就可以,不使用就不行

非常感谢,使用梯子才可以。使用proxychains python -m googletranslate zh-CN "word" -s "translate.google.cn"就可以正常访问了

proxychain4 python -m googletranslate zh-CN "word" -s "translate.google.cn" 顺利解决,感谢!

@xinebf
Copy link
Owner

xinebf commented Dec 11, 2021

正常情况下 translate.google.cn 应该是可以访问的, 如果是有代理的话, 可以试试程序的 -p 参数.

@JohanChane
Copy link

正常情况下 translate.google.cn 应该是可以访问的, 如果是有代理的话, 可以试试程序的 -p 参数.

linux 用 proxychains4, windows 用 -p 参数。目前只能这样了。

@LexsionLee
Copy link

看作者更新后的文档里面已经删除了指定Google.cn的选项了,所以是因为.cn的不行了?

@lwaelcyrge
Copy link

lwaelcyrge commented Mar 9, 2022 via email

@LexsionLee
Copy link

Hi, Sorry I don't speak Chinese. By the way, I have no knowledge in Github or programming languages. I think I made a mistake when clicking forking to the project. I really have no idea about forking. So, yeah. I apologize.

On Wed, Mar 9, 2022, 3:13 PM LexsionLee @.> wrote: 看作者更新后的文档里面已经删除了指定Google.cn的选项了,所以是因为.cn http://xn--siq0pw1r09l5xe.cn 的不行了? — Reply to this email directly, view it on GitHub <#37 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFSPKTKTJVTWVRNLCN7OZ2TU7BMTTANCNFSM5EDV6MUQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you are subscribed to this thread.Message ID: @. com>

Hi,
I'm guessing you got an email from GitHub, this email wasn't sent to you alone. The reason for this may be that you have watched this repository. When someone in the repository submits issues, the person who watched this repository or participated in this issue will receive a notification email. If you cannot help or participate in the discussion , just ignore the message. You don't need to apologize for this.
If you no longer pay attention to this repository, you can open the home page of this repository, click the small triangle at the Watch (eye icon) at the upper right of the page, and select Ignore. This way you should not be notified in the future.

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

8 participants