The issue with installing the 'python-decouple' library

Hello! I have encountered an issue while trying to install the “python-decouple” library in my project. Specifically, I receive the following error when executing the “poetry install” command:

Failed to add packages, reverting the py project.toml file to its original content.
exit status 1
Replit: Package operation failed.

After this error, a second problem arises:

Traceback (most recent call last):
  File "main.py", line 5, in <module>
    from decouple import config
ModuleNotFoundError: No module named 'decouple'

I have attempted to resolve the problem by following the recommended steps:
Checked for the presence of the “python-decouple” library in the “pyproject.toml” file. In my case, it was not listed, but adding the line [tool.poetry.dependencies]\npython-decouple = “*” did not solve the problem.
Tried running the “poetry install” command from the console, but received a “SyntaxError: invalid syntax” error.
Attempted to run the “poetry install” command in the Shell console, but the error remained, indicating an issue with Python 3.8.

poetry install is not a valid command. Do you mean poetry add?

And can you send the link to your Repl?

3 Likes

https://replit.com/@MrPetrich/MyCodeBotDiscord?v=1