importerror: No module named django

后端 未结 4 734
梦毁少年i
梦毁少年i 2021-01-18 09:41

I installed python 2.6 alongside my mac\'s 2.5.2 version. As soon as I did, python2.6 manage.py runserver failed because it couldn\'t find django.core.management.

Fr

4条回答
  •  遥遥无期
    2021-01-18 10:01

    Because each installation of Python uses its own directory to store libraries. On a Mac, they are in /Library/Python/2.x/site-packages/. Presumably you originally installed Django in the 2.5 directory, but it isn't yet in the 2.6 one. You can symlink it there if you want to, or reinstall it using the new version.

提交回复
热议问题