提问人:Kot_v_palto 提问时间:11/18/2023 更新时间:11/18/2023 访问量:21
discord.py |ValueError:“Test”必须全部小写 [closed]
discord.py | ValueError: 'Test' must be all lower-case [closed]
问:
我正在创建一个斜杠命令,但遇到了麻烦 ValueError:“Test”必须全部为小写。如何解决?
import discord
from discord.ext import commands
from discord import app_commands
intents = discord.Intents.default()
intents.message_content = True
client = discord.Client(intents=intents)
bot = commands.Bot(command_prefix=config["prefix"], intents=intents)
@bot.tree.command(name='Test',description='slash welcome')
async def slash_command(interaction:discord.Interaction):
await interaction.response.send_message("Hello World!")
答: 暂无答案
评论
Test
test
/test
/Test