Airsaid / AndroidLocalizePlugin

:earth_asia: Android localization plugin. supports multiple languages and multiple translators.
https://plugins.jetbrains.com/plugin/11174-androidlocalize
Apache License 2.0
583 stars 91 forks source link

一两个string翻译不了,就卡出来了 #53

Closed AtlantisFaded closed 2 years ago

AtlantisFaded commented 2 years ago

Please ensure you have given all the following requested information in your report.

Please select the affected platforms

Please select the translator to use

Version of Plugin and IDE

Issue details

一两个string翻译不了,就卡出来了,没有成功过一次。

AtlantisFaded commented 2 years ago

Translation error: com.airsaid.localization.translate.TranslationException: Failed to translate "Installed %s" text from Auto language to Arabic language: java.io.IOException: Unable to tunnel through proxy. Proxy returns "HTTP/1.1 405 Method Not Allowed"

AtlantisFaded commented 2 years ago

and the file name is wrong for android studio. only two alphabet is OK. https://www.iana.org/assignments/language-subtag-registry/language-subtag-registry the above is google's doc.

Airsaid commented 2 years ago
  1. 翻译失败的问题,建议注册自己的翻译账号,然后填入自己申请的 key,这样会更稳定。
  2. 文件名的问题,由于存在太多的国家,所以没法保证每一个都是正确的,在后面的版本中我会根据你给的这个文档校验并完善一下。
AtlantisFaded commented 2 years ago

嗯嗯已经使用了百度api,之前翻译崩溃应该是用了google的,墙的网络问题。 目前最大的问题就是翻译后的string所属对应国家的名称不对。 https://blog.csdn.net/CoderYue/article/details/77503623 你使用的是另一套国家代号,而安卓用的则是2个字母组成的国家代号。

很棒很棒!!!!!

AtlantisFaded commented 2 years ago

纠正一下:我发现google的国家代号是对的,就是百度的不对。 问一下google翻译必须要配置key吗(api那个)?我这边死活用不了google,已经翻出去了。

Airsaid commented 2 years ago

Google 翻译有两个,不需要申请 Key 的现在不是很稳定。推荐使用自己申请 Key 的,我记得新账号默认会有 50$ 的免费额度的。

AtlantisFaded commented 2 years ago

刚刚申请了key,300美元免费,已经用上了,哈哈哈,简直完美,哪里评分来着,一定要给你评5🌟。 准备给我的app进行国际化文案了哈哈哈哈哈做梦都要笑了。 api那个不好使 建议给用百度的提个醒,string对应的国家代码不对。google的倒是完全对的。

Airsaid commented 2 years ago

啊哈,插件主页可以评分哦:https://plugins.jetbrains.com/plugin/11174-androidlocalize

关于文件名问题待我在后面的版本完善一下,到时会在该 issue 上更新。

qyzhaojinxi commented 2 years ago

@AtlantisFaded 你是绑定了信用卡了么?我看谷歌api的key申请现在得绑定信用卡才能继续