I have installed the latest versions of both django and python. The default "python" command is set to 2.7; if I want to use python 3, I have to type "python3".
Having to type "python3" and a django command causes problems. For example if I type: "python3 manage.py migrate" , I get an error. The error is:
Traceback (most recent call last): File "manage.py", line 8, in from django.core.management import execute_from_command_line ImportError: No module named 'django'
Django does not seem to recognize my python 3. How do I get around this? Your help is greatly appreciated.
您需要安装django
的python 3
, pip3 install django
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.