"../Contents/MacOS/Python: No module named django"
Traceback (most recent call last):
File "manage.py", line 17, in <module>
"Couldn't import Django. Are you sure it's installed and "
ImportError: Couldn't import Django. Are you sure it's installed and available on your PYTHONPATH environment variable? Did you forget to activate a virtual environment?
If I change to include 3, so "$python3 manage.py runserver" all is well.
My question is do I need to always use python3 in every command now? I does not say that in the tutorial.
My Mac OSx has a native install of 2.7 which I believe is required by my machine for other apps dependency.
Any help would be really appreciated!
Hi,
The Python 3 installation is completely separate from Python 2 (the same would hold if you had both 2.7 or 2.6, or 3.6.0 and 3.6.1; each Python version you have installed on the system is completely separate from the others). Somehow when you originally installed Django, you did so in Python 3. So Python 2 has no Django installed. If you install Django on Python 2 as well, you will be able to run it either way.
Make sure you also learn to use virtualenv.
Regards,
Antonis
Antonis Christofides http://djangodeployment.com
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/00c61c2d-95ed-4022-840a-b997318e12ca%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
python3 -m venv your_virtual_dir_name
python3 -m venv mysite