Galarzaa90 / NabBot

Discord bot for Tibia servers
https://nabbot.xyz
Apache License 2.0
52 stars 25 forks source link

TypeError: '<=' not supported between instances of 'int' and 'NoneType' #87

Closed drptbl closed 6 years ago

drptbl commented 6 years ago
Traceback (most recent call last):
  File "nabbot.py", line 440, in <module>
    nabbot.run(token)
  File "/usr/local/lib/python3.6/dist-packages/discord/client.py", line 580, in run
    return task.result()
  File "/usr/local/lib/python3.6/dist-packages/discord/client.py", line 488, in start
    yield from self.connect(reconnect=reconnect)
  File "/usr/local/lib/python3.6/dist-packages/discord/client.py", line 408, in connect
    yield from self._connect()
  File "/usr/local/lib/python3.6/dist-packages/discord/client.py", line 370, in _connect
    yield from self.ws.poll_event()
  File "/usr/local/lib/python3.6/dist-packages/discord/gateway.py", line 448, in poll_event
    msg = yield from self.recv()
  File "/usr/local/lib/python3.6/dist-packages/websockets/protocol.py", line 323, in recv
    raise ConnectionClosed(self.close_code, self.close_reason)
  File "/usr/local/lib/python3.6/dist-packages/websockets/exceptions.py", line 147, in __init__
    if 3000 <= code < 4000:
TypeError: '<=' not supported between instances of 'int' and 'NoneType'

I'm not sure why and when it happened (NabBot is running on VPS), but I'm guessing that it lost connection with Discord and tried to reconnect - then it crashed.

Galarzaa90 commented 6 years ago

What version of discord.py are you using?

This seems like an issue with discord.py.

If you know how to run python on the command line:

python3
>>> import discord
>>> discord.version
'1.0.0a'

Example: image

drptbl commented 6 years ago

@Galarzaa90 Sorry for not providing these details at the beginning, please let me know if you need more.

discord_version

Galarzaa90 commented 6 years ago

I wasn't able to reproduce this, exactly how are you running NabBot?

drptbl commented 6 years ago

@Galarzaa90 Sorry but I'm not using NabBot actively anymore, so it seems that we can close this one.