Search code examples
pythonvisual-studio-codemodulepippypi

Python can't find PyPi Package in Visual Studio Code


I recently published a package on PyPi called ShellScriptHandeler, everything works fine, you can download it and Visual Studio Code also shows you that it exists, but when I try to import it I get the error message: No module named ShellScriptHandeler.

import ShellScriptHandeler

ShellScriptHandeler.Basic.open("test.sh")

I have no idea why that is and therefore also no idea what kind of information to give. You can download the package with "pip install ShellScriptHandeler"


Solution

  • In the terminal take the command of pip show ShellScriptHandeler to check where your package has been installed.

    And from the bottom-left of the VSCode to check which python interpreter you have selected. If it's not the environment you have installed the package, you can click it and select the proper one.