G
G
Goshujin2022-04-20 20:38:05
Python
Goshujin, 2022-04-20 20:38:05

How to make Python see libraries?

There is a discord bot in python, it uses the libraries "discord", "colorama", and others. Today at start there was an error
ModuleNotFoundError: No module named ‘discord’
And such error occurs now for each installed module.

Why did this error appear at all, and how to solve it? I tried to reinstall the library, I tried to add it through PyCharm, but if I don’t run the program through the terminal, import errors still appear.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
Pan Propan, 2022-04-21
@mgis

Set PYTHONPATH in the project directory.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question