0

I am trying to translate from AWS EC2 Instance with googletrans python library using below snippet:

translator = Translator(service_urls=['translate.google.com', 'translate.google.co.kr'])
translated_text = str(translator.translate("你好!", dest="en").text)

print(translated_text) # <------- outputs to 你好! but it should be ideally Hello there

The same code was working for 6+ months at same instance, but from last 2-3 days , I am getting output same as input. I checked it translate.google.com , it was working fine, so thought it would be a bug with googletrans

Current Behaviour:

Suppose if I want to translate 你好! to English , At Output , I am getting same value "你好!" - before that it converts to "Hello there".

Even for Single text, this is happening. Any help appreciated, Thanks!

3
  • 1
    Hi, I believe this might be a duplicate of this other post. As mentioned in my other comment, please consider using Google API for stable supported results. Commented Nov 23, 2020 at 14:59
  • Does this answer your question? GoogleTrans Python not translating Commented Nov 23, 2020 at 15:01
  • It does help - Thanks! @SergiMuñoz Commented Dec 18, 2020 at 18:44

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.