mercredi 13 août 2014

Django-admin.py startproject monsite python 2.7 - débordement de pile ne fonctionne ne pas


I've read a ton of articles about adding things to the windows PATH variable but none of them have worked so far. I also read about editing regedit and finding some things, however I was unable to find what people were referring to.


So I'm trying to run:


django-admin.py startproject mysite

Previously it would open a window asking me which program to open the file with. I stupidly added it to python.exe, however I think this is now causing more problems as when I run the above command it opens a little black windows then vanishes as Python.exe now tries to open the file. But I think this could be preventing the command working?


It certainly isn't creating anything...


Would this indeed cause problems, or are things just as broke as previously? Really need some help here, it's very frustrating that nothing seems to get it working. Is there is additional information you need, please let me know.




I think your system is not finding the file django-admin.py. Use cmd and navigate to the directory that contains this file and try to execute the command from there:


python django-admin.py startproject mysite

If it works, I recommend you to create an environment variable (e.g. DJANGO_ADMIN) to point do django-admin.py so you can execute the command below from anywhere:


python %DJANGO_ADMIN% startproject mysite 



You can Follow @AmauryMedeiros answer or you can set a path to system environment variable to


C:\Python27\Scripts

its work..



I've read a ton of articles about adding things to the windows PATH variable but none of them have worked so far. I also read about editing regedit and finding some things, however I was unable to find what people were referring to.


So I'm trying to run:


django-admin.py startproject mysite

Previously it would open a window asking me which program to open the file with. I stupidly added it to python.exe, however I think this is now causing more problems as when I run the above command it opens a little black windows then vanishes as Python.exe now tries to open the file. But I think this could be preventing the command working?


It certainly isn't creating anything...


Would this indeed cause problems, or are things just as broke as previously? Really need some help here, it's very frustrating that nothing seems to get it working. Is there is additional information you need, please let me know.



I think your system is not finding the file django-admin.py. Use cmd and navigate to the directory that contains this file and try to execute the command from there:


python django-admin.py startproject mysite

If it works, I recommend you to create an environment variable (e.g. DJANGO_ADMIN) to point do django-admin.py so you can execute the command below from anywhere:


python %DJANGO_ADMIN% startproject mysite 


You can Follow @AmauryMedeiros answer or you can set a path to system environment variable to


C:\Python27\Scripts

its work..


0 commentaires:

Enregistrer un commentaire