Am receiving an error when trying to run a command saying 'ctx is a required argument that is missing'. [Python, discord.py]
--
Music by Eric Matyas
https://www.soundimage.org
Track title: Puzzling Curiosities
--
Chapters
00:00 Question
01:16 Accepted answer (Score 1)
01:33 Answer 2 (Score 1)
02:45 Thank you
--
Full question
https://stackoverflow.com/questions/6362...
Question links:
https://pastebin.com/fQc4vE7F
Answer 1 links:
[repl]: https://repl.it
--
Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...
--
Tags
#python #discord #bots #discordpy
#avk47
ANSWER 1
Score 1
The problem seemed to be my IDE. I ran my code in repl and it worked perfectly. Repl automatically installed all the modules. So the issue I think is likely to have been either my installations and imports running on pycharm conflicting with eachother or my pycharm version being outdated since I had not updated it in quite some time. PyCharm had been telling me that the version which I was on being outdated had some bugs with pip...
Anyway, in case anyone else has a similar issue I would recommend to try run your code in repl or some other IDE as the issue in this case was not my code but rather the setup. If you are encountering the same issue on a different IDE I would recommend repl as you do not have to install anything to your computer. Repl is entirely on the cloud and will only install and import what is necessary. And you should probably update the IDE which you already have. I hope I could help anyone else with a similar issue as I could find no solutions online, but I hope I could change this.
ACCEPTED ANSWER
Score 1
you should try re-installing discord.py, also make sure to put the following at the top:
from discord.ext import commands
import discord