#๐ No module named 'pkg_resources'
16 messages ยท Page 1 of 1 (latest)
@worn spade
Remember to:
- Ask your Python question, not if you can ask or if there's an expert who can help.
- Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
- Explain what you expect to happen and what actually happens.
:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.
:/home/container$ if [[ -d .git ]] && [[ ${AUTO_UPDATE} == "1" ]]; then git pull; fi; if [[ ! -z ${PY_PACKAGES} ]]; then pip install -U --prefix .local ${PY_PACKAGES}; fi; if [[ -f /home/container/${REQUIREMENTS_FILE} ]]; then pip install -U --prefix .local -r ${REQUIREMENTS_FILE}; fi; /usr/local/bin/python ${PY_START_FLAGS} /home/container/${BOT_PY_FILE}
Requirement already satisfied: discord.py==1.7.3 in ./.local/lib/python3.12/site-packages (from -r requirements.txt (line 1)) (1.7.3)
Requirement already satisfied: aiohttp in ./.local/lib/python3.12/site-packages (from -r requirements.txt (line 2)) (3.7.4.post0)
Collecting aiohttp (from -r requirements.txt (line 2))
Using cached aiohttp-3.10.5-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (7.5 kB)
Requirement already satisfied: requests in ./.local/lib/python3.12/site-packages (from -r requirements.txt (line 3)) (2.32.3)
Requirement already satisfied: colorama in ./.local/lib/python3.12/site-packages (from -r requirements.txt (line 4)) (0.4.6)
Requirement already satisfied: Flask in ./.local/lib/python3.12/site-packages (from -r requirements.txt (line 5)) (3.0.3)
Requirement already satisfied: pystyle in ./.local/lib/python3.12/site-packages (from -r requirements.txt (line 6)) (2.9)
Requirement already satisfied: bs4 in ./.local/lib/python3.12/site-packages (from -r requirements.txt (line 7)) (0.0.2)
Requirement already satisfied: pyfiglet==0.8.post1 in ./.local/lib/python3.12/site-packages (from -r requirements.txt (line 8)) (0.8.post1)
Requirement already satisfied: openai==0.28.0 in ./.local/lib/python3.12/site-packages (from -r requirements.txt (line 9)) (0.28.0)
ERROR: Could not find a version that satisfies the requirement pkg-resources (from versions: none)
ERROR: No matching distribution found for pkg-resources
/home/container/main.py:91: SyntaxWarning: invalid escape sequence '\ '
""",
/home/container/main.py:246: SyntaxWarning: invalid escape sequence '\*'
await ctx.send("- `" + user.name.replace("*", "\*").replace(
/home/container/main.py:247: SyntaxWarning: invalid escape sequence '\`'
"`", "\`").replace("_", "\_") + "#" + user.discriminator +
/home/container/main.py:247: SyntaxWarning: invalid escape sequence '\_'
"`", "\`").replace("_", "\_") + "#" + user.discriminator +
/home/container/main.py:252: SyntaxWarning: invalid escape sequence '\*'
"*", "\*").replace("`", "\`").replace("_", "\_") + "#" +
/home/container/main.py:252: SyntaxWarning: invalid escape sequence '\`'
"*", "\*").replace("`", "\`").replace("_", "\_") + "#" +
/home/container/main.py:252: SyntaxWarning: invalid escape sequence '\_'
"*", "\*").replace("`", "\`").replace("_", "\_") + "#" +
/home/container/main.py:286: SyntaxWarning: invalid escape sequence '\*'
await ctx.send("- `" + user.name.replace("*", "\*").replace(
/home/container/main.py:287: SyntaxWarning: invalid escape sequence '\`'
"`", "\`").replace("_", "\_") + "#" + user.discriminator +
/home/container/main.py:287: SyntaxWarning: invalid escape sequence '\_'
"`", "\`").replace("_", "\_") + "#" + user.discriminator +
/home/container/main.py:294: SyntaxWarning: invalid escape sequence '\*'
user2.name.replace('*', "\*").replace(
/home/container/main.py:295: SyntaxWarning: invalid escape sequence '\`'
'`', "\`").replace('_', "\_") + '#' +
/home/container/main.py:295: SyntaxWarning: invalid escape sequence '\_'
'`', "\`").replace('_', "\_") + '#' +
Traceback (most recent call last):
File "/home/container/main.py", line 30, in <module>
from pyfiglet import Figlet
File "/home/container/.local/lib/python3.12/site-packages/pyfiglet/__init__.py", line 11, in <module>
import pkg_resources
ModuleNotFoundError: No module named 'pkg_resources'```
console
If you want to use pyfiglet you probably need to downgrade your Python version to ... 3.10 probably?
Also your syntax warning error is a separate issue witth the code in your main.py
3.11 actually
@worn spade Are you using Unix system?
And it's running on linux?
List of package versions for project python:pyfiglet in all repositories
You need to install correct one I guess
This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.