Discord.pyでコマンドを入力するとエラーメッセージが出ず何も起こらないです

前提

今Discord.pyでコマンドを作っているのですが、
前まで実行できていたコマンドが実行できなくなってしまいました。
Discord側もそのBOTのコマンド一覧(?)みたいなところを見ても
そのBOTのだけコマンドが一切表示されず、
一切何もできないです。

"hi"と打ったら"hi"と打つ応答するのはできたので
BOTは起動とかはできているようです。

実現したいこと

コマンドが実行できるようにしたいです

該当のソースコード

python

import discord from discord.ext import commands bot = commands.Bot(intents=discord.Intents.all(), command_prefix="/") @bot.command()async def help(ctx): await ctx.send("help") @bot.command()async def ban(ctx, member : discord.Member, *, reason = None): await member.ban(delete_message_days=7, reason=reason) await ctx.send("baned") @bot.eventasync def on_ready(): print('login{0.user}'.format(bot)) await bot.change_presence(activity=discord.Activity(type=discord.ActivityType.watching, name ="Youtube")) @bot.eventasync def on_message(message): if message.author.bot: return if message.content == "hi": await message.channel.send("hi")bot.run("TOKEN here")

試したこと

一度パッケージがおかしいかもと思って
再インストールしてみたりしました

補足情報(FW/ツールのバージョンなど)

python : 3.10.8
discord.py : 2.0.1

コメントを投稿

0 コメント