Python discord.ext.commands.errors.CommandInvokeError:命令引发异常:AttributeError:“非类型”对象没有属性“提及”
我的代码: @commands.commandpass_context=True @仅限commands.guild\u 异步def所有者自身,ctx: 等待ctx.sendctx.guild.owner.notice 错误: discord.ext.commands.errors.CommandInvokeError:命令引发了错误 异常:AttributeError:“非类型”对象没有属性 “提到”Python discord.ext.commands.errors.CommandInvokeError:命令引发异常:AttributeError:“非类型”对象没有属性“提及”,python,discord,discord.py,Python,Discord,Discord.py,我的代码: @commands.commandpass_context=True @仅限commands.guild\u 异步def所有者自身,ctx: 等待ctx.sendctx.guild.owner.notice 错误: discord.ext.commands.errors.CommandInvokeError:命令引发了错误 异常:AttributeError:“非类型”对象没有属性 “提到” 在discord.py1.5.x的新版本中,在意图上有一些变化。意图就像权限。您需要定义它,
在discord.py1.5.x的新版本中,在意图上有一些变化。意图就像权限。您需要定义它,以便向频道、成员等发送消息 进口不和 意图=不和谐 client=discord.Botprefix=,intents=intents 有关详细信息,您可以检查。ctx.guild.owner为“无”,因此无法获得“提及”属性