腾讯云
开发者社区
文档
建议反馈
控制台
登录/注册
首页
学习
活动
专区
工具
TVP
最新优惠活动
文章/答案/技术大牛
搜索
搜索
关闭
发布
精选内容/技术社群/优惠产品,
尽在小程序
立即前往
文章
问答
(6832)
视频
沙龙
1
回答
错误
:
命令
引发
异常
:
AttributeError
:'
Message
‘
对象
没有
属性
'
member
’
我正在尝试使用discord.py向我的Discord机器人添加货币
命令
。这是我的代码: @client.command() await open_account(ctx.
message
.
member
) users = await get_bank_data() use
浏览 23
提问于2021-04-24
得票数 0
3
回答
Discord.py dm
命令
、
@bot.command() id =
member
.id awaitbot.send_
message
(id, "")从exc discord.ext.commands.errors.CommandInvokeError:
命令
引发
的
引发
CommandInvokeEr
浏览 4
提问于2021-02-15
得票数 0
回答已采纳
1
回答
我的神通
命令
不起作用-我该怎么修复它?
、
、
@client.command() if not
member
:
member
= ctx.
message
.author favatar = discord.Embed(title=f"{
member
.name}'s avatarf"Requested by {ctx.author.name}#{ctx.au
浏览 2
提问于2021-02-11
得票数 0
回答已采纳
2
回答
如何检查用户是否在不和谐中扮演特定角色?
、
、
bot.command(pass_context=True) async def unmute(ctx, user: discord.
Member
): ctx.
message
.server.roles)await bot.say("{} is not muted".forma
浏览 0
提问于2019-02-23
得票数 9
回答已采纳
3
回答
Discord.py如何通过
命令
将DM发送给我想要的任何人
、
有人让我为他制作一个机器人,通过
命令
将DM发送给他指定的任何人,比如*send_dm @Jess#6461 hello。我搜索了很多次,发现了这样的代码: await client.send_
message
(
member
,content) discord.ext.commands.errors.CommandInvokeError:
命令<
浏览 0
提问于2019-08-03
得票数 0
回答已采纳
1
回答
在discord.py中使用用户ID获取用户的头像
代码 @bot.command() userAvatarUrl = avamember.avatar_urlawait ctx.send(userAvatarUrl)
错误
:
命令
引发
异常
:成员:‘
AttributeError
’
对象
没有
属性
'avatar_url‘
浏览 78
提问于2021-10-03
得票数 0
回答已采纳
2
回答
如果消息中有成员名称,则在
message
.content中签入Discord.py
、
我在我的Discord.py机器人中有一个函数,在那里我试图检查
命令
中的一个参数是否是一个成员的名称。以下是代码:async def test(ctx, *,
message
): for
member
in x: print(
member
.name) 例如:$
浏览 5
提问于2020-09-27
得票数 0
回答已采纳
1
回答
命令
引发
异常
:
AttributeError
:'str‘
对象
没有
属性
'
message
’
、
、
@bot.command() vote = ctx.
message
.content[4:].split(" / ") await ctx.add_reaction(choose, "⭕")我得到了
错误
: Command raised an exception: <
浏览 2
提问于2020-08-25
得票数 0
回答已采纳
1
回答
命令
引发
异常
:
message
:'TextChannel‘
对象
没有
属性
’
AttributeError
‘
、
我正在制造不和谐,我正在处理它的清晰消息
命令
,但它显示了这一点 Command raised an exception:
AttributeError
: 'TextChannel' object hasno attribute '
message
' 下面是完整的代码 from discord.ext import commands defcommands.has_permissions(manage_messages=True) as
浏览 18
提问于2021-07-03
得票数 0
回答已采纳
1
回答
Discord.py:“上下文”
对象
没有
属性
'id‘
错误
、
我有一个踢的
命令
,因为不和,它是工作的两个星期前,但它现在不起作用。这是代码和
错误
async def kick(self,
member
: discord.
Member
, *, reason=None):discord.ext.commands.errors.CommandInvokeError:
命令
引发
浏览 4
提问于2020-06-27
得票数 1
回答已采纳
1
回答
我正在寻找Discord.py
命令
,以便使用该
命令
为每个人设置角色
、
@client.command(pass_context=True) user = ctx.
message
.author await ctx.add_roles(user, role) 但当我使用这个
命令
。我得到了这个
错误
(discord.ext.commands.errors.CommandInvokeError:
命令
浏览 0
提问于2020-11-17
得票数 0
回答已采纳
1
回答
提到用户的discord.py随机消息
py最近和我想要机器人发送随机消息,提到用户,但它给了我这个
错误
:以下是代码:async def randomroman(ctx, *,
member
: discord.
Member
=Non
浏览 2
提问于2020-07-10
得票数 0
回答已采纳
1
回答
为什么send_
message
不存在?
、
、
、
discord.ext.commands.errors.CommandInvokeError:
命令
引发
了一个
异常
:
AttributeError
:'Bot‘
对象
没有
属性
'send_
message
’这是我的密码: await client.send_
message
(ctx.
message
.author, 'sad')``` <em
浏览 5
提问于2019-09-27
得票数 0
1
回答
如何修复不和谐音乐机器人
属性
、
错误
:import youtube_dl async def join(ctx): channel = ctx.
浏览 2
提问于2021-08-07
得票数 0
回答已采纳
3
回答
如何仅使用用户id将DM发送给用户
、
、
@client.command() user = client.get_user(userID)这是出现的
错误
: discord.ext.commands.errors.CommandInvokeError:
命令
引发
一个
异常
:
AttributeError
:'NoneType‘
对象
没有
<em
浏览 17
提问于2022-12-01
得票数 0
1
回答
discord py -使用on_command_error处理
错误
、
、
、
我需要帮助在discord.py中的
错误
处理。如果我的机器人
没有
足够的权限执行
命令
,或者如果我的机器人
没有
足够的权限(原因是
没有
足够的权限)他需要的权限,我想向服务器所有者发送一条私人消息。我知道如何向所有者发送私人消息,但"isinstance“这件事让我很困惑,我以前从来
没有
用过它。但这是一个重要的特性,我很想集成它。
浏览 9
提问于2021-02-26
得票数 1
1
回答
如何读取不一致消息并将其用作变量?Python
、
、
每当我使用该
命令
时,我得到的所有rn都是一个
错误
。
错误
:
命令
引发
异常
:
AttributeError
:'Bot‘
对象
没有
属性
'wait_for_
message
’ @client.command() await ctx.send('Enter
member
name: ')
浏览 15
提问于2020-07-28
得票数 0
2
回答
如何解除用户禁令?
、
、
、
我有以下代码输出
错误
: @commands.has_role("Moderator") mesg = ctx.
message
浏览 4
提问于2018-01-04
得票数 3
回答已采纳
1
回答
命令
引发
异常
:
AttributeError
:'Guild‘
对象
没有
'voice’
属性
错误
我创建了一个音乐机器人,但我犯了一个
错误
。我得到的
错误
完全是这样的; discord.ext.commands.errors.CommandInvokeError: Command raised an exception:
AttributeError
: 'Guild' object has no attribute 'voice'
命令
; @Bot.command(pass_context=True) voice
浏览 8
提问于2021-01-30
得票数 0
2
回答
如何用discord.py编辑嵌入的颜色?
、
、
、
我想知道如何使用edit_
message
更改消息的嵌入颜色。"Embed color changing""" msg = await self.
message
.channel.send(embed=em1) await self.bot.edit_
浏览 6
提问于2020-01-01
得票数 0
回答已采纳
点击加载更多
扫码
添加站长 进交流群
领取专属
10元无门槛券
手把手带您无忧上云
相关
资讯
互联网面试必备之超时订单自动关闭的优雅实现
Python基础教程 raise 语句
Python中的AttributeError:属性错误处理
Python异常处理:如何处理程序中出现的异常?
Python标准库系列:我们讨厌的异常
热门
标签
更多标签
云服务器
ICP备案
对象存储
腾讯会议
云直播
活动推荐
运营活动
广告
关闭
领券