Closed yemix closed 1 year ago
Under System Information, this returns when i running this... python3 -m discord -v
You installed discord.py-self over a different package that uses the discord
namespace, such as upstream discord.py.
Uninstall everything and reinstall or use a fresh env.
Summary
commands.Bot() dont work after reinstall
Reproduction Steps
from discord.ext import commands
prefix = "!!" token = "XXX.xxx.XXX"
client = commands.Bot(command_prefix=prefix)
@client.command() async def hello(ctx): await ctx.send("Hello, You!")
client.run(token)
Code
No response
Expected Results
Bot is successfully online.
Actual Results
Traceback (most recent call last): File "C:\Users\USER\Downloads\test\test.py", line 1, in
from discord.ext import commands
File "C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord__init.py", line 25, in
from .client import Client
File "C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\client.py", line 53, in
from .webhook import Webhook
File "C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\webhook\ init_.py", line 11, in
from .async import *
File "C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\webhook\async_.py", line 41, in
from ..channel import PartialMessageable
ImportError: cannot import name 'PartialMessageable' from 'discord.channel' (C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\channel.py)
System Information
Traceback (most recent call last): File "", line 189, in _run_module_as_main
File "", line 148, in _get_module_details
File "", line 112, in _get_moduledetails
File "C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord__init.py", line 25, in
from .client import Client
File "C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\client.py", line 53, in
from .webhook import Webhook
File "C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\webhook\ init__.py", line 11, in
from .async import *
File "C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\webhook\async_.py", line 41, in
from ..channel import PartialMessageable
ImportError: cannot import name 'PartialMessageable' from 'discord.channel' (C:\Users\USER\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\channel.py)
Checklist
Additional Information
No response