heiheiheichou
heiheiheichou

Reputation: 3

discord.py simple commands not working (in pythonista)

I’m just getting started with a discord.py bot in Pythonista but I am unsure as to why this starting code (copied from official docs) is not working - when I type “!test hello” the bot doesn’t reply, whereas when I used an “on_message” before, it worked fine. It also didn’t work when I tried it in PyCharm on a laptop. Any help appreciated. Thanks!

import discord
from discord.ext import commands

bot = commands.Bot(command_prefix='!')

@bot.command()
async def test(ctx, arg):
    await ctx.send(arg)


bot.run("myToken")

Upvotes: 0

Views: 121

Answers (1)

Pickl
Pickl

Reputation: 46

Since I don't really see a problem, maybe you could try updating discord.py doing pip install -U discord.py

Upvotes: 0

Related Questions