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

IndexError: list index out of range #10

Open
malkabani opened this issue Nov 6, 2023 · 0 comments
Open

IndexError: list index out of range #10

malkabani opened this issue Nov 6, 2023 · 0 comments

Comments

@malkabani
Copy link

Hello
first time I used this script, it works normally. after that I got this error
translator.translate_strings(file_name="Localizable.strings", target_lang="es", source_lang="en") File "/usr/local/lib/python3.11/site-packages/stringstranslate/strings_translator.py", line 54, in translate_strings file.write("\"" + word.replace("\\", "") + "\" = \"" + self.translator.translate(word, dest=target_lang, ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/googletrans/client.py", line 172, in translate data = self._translate(text, dest, src) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/googletrans/client.py", line 75, in _translate token = self.token_acquirer.do(text) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/googletrans/gtoken.py", line 184, in do self._update() File "/usr/local/lib/python3.11/site-packages/googletrans/gtoken.py", line 55, in _update self.tkk = self.RE_TKK.findall(r.text)[0] ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^ IndexError: list index out of range

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

1 participant