Python 从今天起,我的discord bot找不到我的成员
我用python编写了一个discord机器人,它一直工作到今天。今天,它无法找到我的服务器的成员,这显然是一个破坏交易。为了确定故障点,我对以下测试例行程序进行了编码:Python 从今天起,我的discord bot找不到我的成员,python,discord,discord.py,Python,Discord,Discord.py,我用python编写了一个discord机器人,它一直工作到今天。今天,它无法找到我的服务器的成员,这显然是一个破坏交易。为了确定故障点,我对以下测试例行程序进行了编码: @bot.command(name='test', help='test stuff') async def test(ctx): for guild in bot.guilds: for member in guild.members: print(member) p
@bot.command(name='test', help='test stuff')
async def test(ctx):
for guild in bot.guilds:
for member in guild.members:
print(member)
print("Test done")
这是我从文档中复制和粘贴的代码,应该可以正常工作。今天我得到了反馈:
Bot is ready. (=> this print command is generated on the startup of the bot)
Keeper of Keys#4019
Test done
密钥保管器是机器人本身的名称。所以很明显,机器人能够找到自己,但不能找到公会的其他成员。我做错什么了吗?提前谢谢 好的,我浏览了文档,找到了问题的解决方案:
这应该可以解决问题。感谢您提供答案。我不知道这个变化