#Slash commands using discord-py-interactions
1 messages · Page 1 of 1 (latest)
its interactions try looking at your spelling
We've detected that you're mixing discord.py and interactions.py code together - do not do this, and only use one for your bots.
Why?
- Both interactions.py and discord.py are full Discord Python libraries that cover the entirety of the Discord API. It's redundant to use both, as they can do the same things.
- While the two can do the same things, how they do is drastically different from each other. For example, despite being named the same,
interactions.Clientis very different fromdiscord.Client, not just in implementation but in their core design. There's no way to make the two work together because of this because of this - code from one won't be understood by the other. - Relating to the above two points, using both at the same time will lead to errors.
While the decision of which library is up to you, it's important to only use one. As for us, as of our latest versions, we cover everything discord.py offers while boasting a better, simplier, more developer friendly experience when making bots. Take a look at the documentation and the discord.py migration guide if you're interested!
Can you share the version of the library?
You're using the docs for the v3 version of the library, which is heavily outdated
There's a few options that you can do:
- Install the v3 version of the library (heavily discouraged, requires discord-py 1.7)
- Use just discord.py 2.x
- Use just interactions.py 5.x
If you're ever unsure where to find the docs, it's in the pinned thread in #1076867263191339078, and on the github page