I\'m getting the following errors in Pycharm.
Error: Django is not importable in this environment
It used to work well but I moved t
I got the same issue on OS X, and to fix it, I had to use an absolute path for the project interpreter
/Users/myself/Projects/... is ok ~/Projects/... was not working
I kept getting this error even after following suggestions made in other answers, like deleting .idea folder, reinstalling packages from settings->project interpreter.
Finally, I took the venv out of the project folder and created a venev beside the project folder and deleted .idea folder from project folder.
Then I opened the project and chose the interpreter as the newly created venv
I had the same error. Try to name path (and project) without "_":
../my_project/venv -> ../my-project/venv
Project interpreter, which is being used in the pycharm
setting , doesn't have the django
package installed. So go to
setting->Project->project interpreter
Then install django
package
it will work :)
I had similar problem...
I go PyCharm -> Preferences and tried to readd Django to project interpreter packages. PyCharm suddenly added everything in requirements.txt file. And now I can run project without any problem.
As everybody said ,Check for your interpreter Was it properly configured it or not.If you created your project in virtual environment ,make sure you configured the correct python interpreter or not .The python interpreter(whole) and python interpreter(for only single project using virtualenv) are different .
If you are using PyCharm Go to Setting->Project->project interpreter and pick the right interpreter Once you are done with that ,run the project if it runs,all set .if not check for the Edit configurations and check again for the interpreter