Error with django-admin.py

16 views
Skip to first unread message

Tet Yeap

unread,
Feb 17, 2018, 12:48:58 PM2/17/18
to Django users
Hi,

    I was trying to crate a django project using "django-admin.py startproject mysite". The a message showed up in notepad 

"#!C:\WinPython-64bit-3.6.1.0Qt5\python-3.6.1.amd64\python.exe
from django.core import management

if __name__ == "__main__":
    management.execute_from_command_line()

    I am using Django 2.0, Python 3.6. Both programs run on Windows 8.

    Do anyone know what is wrong? Tx.


Etienne Robillard

unread,
Feb 17, 2018, 12:51:35 PM2/17/18
to Tet Yeap, django...@googlegroups.com

Please send the actual traceback and error message.

Etienne
--
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/7eef68cc-5480-4a3a-b0b8-11a97044ca0d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

-- 
Etienne Robillard
tka...@yandex.com
https://www.isotopesoftware.ca/

Dylan Reinhold

unread,
Feb 17, 2018, 1:07:23 PM2/17/18
to django...@googlegroups.com
This means your windows system has python files (.py) associated with notepad not python.
It's okay, but anything you are going to run a python script like django-admin.py or manage.py you need to run pythin first.

>  python django-admin.py startproject myapp
>  python manage.py

If you get an error about python comand not found you will need to fix the path, the easy way might be to re run the python3 installer and make sure add python to the path and associdate .py files to python is checked.

Dylan

--
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+unsubscribe@googlegroups.com.

Tet Yeap

unread,
Feb 17, 2018, 3:51:26 PM2/17/18
to Django users
Hi Dylan,

     Thank you for the pointers. As you have suggested, after re-installing Python, I am able to continue my work. I must have screw up the path.

Regards,

Tet Yeap
Reply all
Reply to author
Forward
0 new messages