﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
18249	strange error with django-admin.py startproject myproject.  Run with /bin/zsh	lucassrod@…	Lucas Simon	"Hi,
Today I was testing a install application django with virtualenv, pip. I run Ubuntu Os 12.04, with /bin/zsk and https://github.com/robbyrussell/oh-my-zsh.

Look my steps:


{{{
$ virtualenv --distribute project
New python executable in project4/bin/python
Installing distribute.............................................................................................................................................................................................done.
Installing pip...............done.



$ cd project/

$ source bin/activate

$ sudo pip install yolk
Downloading/unpacking yolk
  Downloading yolk-0.4.3.tar.gz (86Kb): 86Kb downloaded
  Running setup.py egg_info for package yolk
    
    warning: no files found matching '*.txt' under directory 'tests'
    warning: no files found matching '*.conf' under directory 'docs'
    warning: no files found matching '*.css_t' under directory 'docs'
    warning: no files found matching 'indexsidebar.html' under directory 'docs'
    warning: no files found matching 'tests/test_cli.py'
Requirement already satisfied (use --upgrade to upgrade): distribute in ./lib/python2.7/site-packages/distribute-0.6.24-py2.7.egg (from yolk)
Installing collected packages: yolk
  Running setup.py install for yolk
    
    warning: no files found matching '*.txt' under directory 'tests'
    warning: no files found matching '*.conf' under directory 'docs'
    warning: no files found matching '*.css_t' under directory 'docs'
    warning: no files found matching 'indexsidebar.html' under directory 'docs'
    warning: no files found matching 'tests/test_cli.py'
    Installing yolk script to /home/lucas/workspace-django/project4/bin
Successfully installed yolk
Cleaning up...



$ sudo pip install Django
Downloading/unpacking Django
  Downloading Django-1.4.tar.gz (7.6Mb): 7.6Mb downloaded
  Running setup.py egg_info for package Django
    
Installing collected packages: Django
  Running setup.py install for Django
    changing mode of build/scripts-2.7/django-admin.py from 644 to 755
    
    changing mode of /home/lucas/workspace-django/project4/bin/django-admin.py to 755
Successfully installed Django
Cleaning up...


}}}


----

Here shows the problem 

{{{


$ django-admin.py startproject myproject

$ cd myproject/

(project)➜  myproject  ls
__init__.py  manage.py  settings.py  urls.py
(project)➜  myproject  tree
.
├── __init__.py
├── manage.py
├── settings.py
└── urls.py

$ yolk -l
Django          - 1.4          - active 
Python          - 2.7.3        - active development (/usr/lib/python2.7/lib-dynload)
argparse        - 1.2.1        - active development (/usr/lib/python2.7)
distribute      - 0.6.24       - active 
pip             - 1.1          - active 
wsgiref         - 0.1.2        - active development (/usr/lib/python2.7)
yolk            - 0.4.3        - active 


$ cat manage.py
#!/usr/bin/env python
from django.core.management import execute_manager
import imp
try:
    imp.find_module('settings') # Assumed to be in the same directory.
except ImportError:
    import sys
    sys.stderr.write(""Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized things.\nYou'll have to run django-admin.py, passing it your settings module.\n"" % __file__)
    sys.exit(1)

import settings

if __name__ == ""__main__"":
    execute_manager(settings)
}}}



----



== the file manage.py does not appear like a official manage.py in version django[1] 1.4.
And the structure of the folder myproject its strange. ==
 

{{{
Official:
manage.py
myapp/
    __init__.py
    models.py
mysite/
    __init__.py
    settings.py
    urls.py

My test app:
(project)➜  myproject  tree
.
├── __init__.py
├── manage.py
├── settings.py
└── urls.py
}}}



''' Totally different.'''


----



== There are other thing that I did test. If I run this steps: ==


{{{

$ /bin/bash

// Suppose I was in the folder myproject

$ source ../bin/activate

$ cd ..

$ ls
bin  include  lib  local  myproject

$ django-admin.py startproject myproject2

$ cd myproject2

$ ls
manage.py  myproject2
$ tree
.
├── manage.py
└── myproject2
    ├── __init__.py
    ├── settings.py
    ├── urls.py
    └── wsgi.py

1 directory, 5 files

}}}



== OOOOOOOOOHHHHH JESUS !!!! It's Work!! ==
I can't understand this error or bug but I need to share to devel departament django 



[1]https://docs.djangoproject.com/en/dev/releases/1.4/


"	Uncategorized	closed	Testing framework	1.4	Normal	duplicate	django-admin.py,django,ksh,bash		Unreviewed	0	0	0	0	0	0
