简体   繁体   中英

Python package is in venv/lib/site-packages folder and shows as installed in PyCharm but throws ModuleNotFoundError

As described in the title, I tried installing the Markdown2 package through pip and through PyCharm's built-in package installer, as well as with easy_install, all of which appeared to be successful, but I'm still getting a ModuleNotFoundError at runtime.

I'm working in a Django venv, not sure if that impacts it. I checked the library and scripts folders and the markdown2 files seem to be present. Not sure what I'm doing wrong at this point but any help would be appreciated!

Also I checked to make sure the interpreter is in the venv/scripts folder and it is. I'm still super new to python venvs so I could be doing something else wrong.

Turns out the configuration (top right corner) was using a different interpreter than what was in the project settings. Oops.

If anyone else has this problem, click the configuration dropdown in the top right (icon left of "run" button) --> edit configurations --> Environment --> Python interpreter. I might just be dumb and didn't know it was separate from the project settings interpreter but TMYK I guess?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM