Translation API returned the input string unchanged for some languages
Hi,
I am facing a problem in with language translation. When I give 1000 Mandarin comments it translates it to English. When I give 200 mixed content of English, German, Spanish and Mandarin it gives me "raise NotTranslated('Translation API returned the input string unchanged"
Can any one please help me on this.
NotTranslated means that the Google API simply returned the same string unchanged; it doesn't think there is any work to do. Are the strings in question the same in both source and target languages?
I presume when you say 'mixed content', you don't mean that all of those languages are present in the same string, right? I don't think that will work - each request should only contain one language.
If you can provide an example, we can look into it.
The things is that the for loop stops once it finds an English sentence. I think you should put the for loop in a while loop and handle to bypas the NotTranslated error raised by the TextBlob. Good luck!
Hi @itsravimalhotra3 did u find a fix to it?
Hi Jeff,
Sorry for so late reply. It worked for me. Thanks.
On 03-Jan-2018, at 1:44 AM, Jeff Schnurr [email protected] wrote:
NotTranslated means that the Google API simply returned the same string unchanged; it doesn't think there is any work to do. Are the strings in question the same in both source and target languages?
I presume when you say 'mixed content', you don't mean that all of those languages are present in the same string, right? I don't think that will work - each request should only contain one language.
If you can provide an example, we can look into it.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.
Hi,
It worked for me. Sorry for so late response.
Thank you.
On 01-Sep-2018, at 12:16 PM, Nfekih [email protected] wrote:
The things is that the for loop stops once it finds an English sentence. I think you should put the for loop in a while loop and handle to bypas the NotTranslated error raised by the TextBlob. Good luck!
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.
Hi,
It worked for me. Sorry for so late response.
Thank you.
On 15-Oct-2018, at 7:41 PM, dripti [email protected] wrote:
Hi @itsravimalhotra3 did u find a fix to it?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.
what did u do to make it work?
what did u do to make it work?
The things is that the for loop stops once it finds an English sentence. I think you should put the for loop in a while loop and handle to bypas the NotTranslated error raised by the TextBlob. Good luck!
I am also facing the same problem. So, can you please share the code for this problem?
please tell how to fix this problem :(