【发布时间】:2020-11-19 16:25:39
【问题描述】:
该机器人在几周前启动并运行,我今天检查了一下,发现它已离线。我试图再次运行它,这个错误消息击中了我。自上次运行以来未进行任何更改...
来自控制台的错误消息:
Traceback (most recent call last):
File "bot.py", line 347, in <module>
bot.run(TOKEN)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\client.py", line 640, in run
return future.result()
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\client.py", line 621, in runner
await self.start(*args, **kwargs)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\client.py", line 585, in start
await self.connect(reconnect=reconnect)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\client.py", line 499, in connect
await self._connect()
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\client.py", line 463, in _connect
await self.ws.poll_event()
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\gateway.py", line 471, in poll_event
await self.received_message(msg)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\gateway.py", line 425, in received_message
func(data)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\state.py", line 750, in parse_guild_create
guild = self._get_create_guild(data)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\state.py", line 725, in _get_create_guild
guild._from_data(data)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\guild.py", line 297, in _from_data
self._sync(guild)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\guild.py", line 328, in _sync
self._add_channel(CategoryChannel(guild=self, data=c, state=self._state))
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\channel.py", line 726, in __init__
self._update(guild, data)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\channel.py", line 737, in _update
self._fill_overwrites(data)
File "C:\Users\bjha0\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\abc.py", line 294, in _fill_overwrites
self._overwrites.append(_Overwrites(id=overridden_id, **overridden))
TypeError: __new__() got an unexpected keyword argument 'deny_new'
【问题讨论】:
标签: python python-3.x python-3.6 discord.py-rewrite