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

AttributeError: 'NoneType' object has no attribute 'group' #3

Closed
ddfabbro opened this issue Jun 20, 2022 · 1 comment
Closed

AttributeError: 'NoneType' object has no attribute 'group' #3

ddfabbro opened this issue Jun 20, 2022 · 1 comment

Comments

@ddfabbro
Copy link
Owner

ddfabbro commented Jun 20, 2022

Traceback (most recent call last):
  File "/home/ubuntu/.local/lib/python3.8/site-packages/slackbot/dispatcher.py", line 55, in _dispatch_msg_handler
    func(Message(self._client, msg), *args)
  File "/home/ubuntu/mybot/translatorbot/plugins.py", line 29, in all_replies
    translate(message)
  File "/home/ubuntu/mybot/translatorbot/plugins.py", line 11, in translate
    if translator.detect(msg_in).lang == "en":
  File "/home/ubuntu/.local/lib/python3.8/site-packages/googletrans/client.py", line 255, in detect
    data = self._translate(text, 'en', 'auto', kwargs)
  File "/home/ubuntu/.local/lib/python3.8/site-packages/googletrans/client.py", line 78, in _translate
    token = [self.token_acquirer.do](http://self.token_acquirer.do/)(text)
  File "/home/ubuntu/.local/lib/python3.8/site-packages/googletrans/gtoken.py", line 194, in do
    self._update()
  File "/home/ubuntu/.local/lib/python3.8/site-packages/googletrans/gtoken.py", line 62, in _update
    code = self.RE_TKK.search(r.text).group(1).replace('var ', '')
AttributeError: 'NoneType' object has no attribute 'group'
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