On Mon, 2009-10-05 at 09:02 -0700, Ralph Heinkel wrote:
> Hi,
> 
> I just checked the environment for PYTHONPATH, it is neither set in
> the parent nor in the subshell.
> 
> Actually, I can reduce the problem to this:
> 
> 1. In my unix shell I start the python interpreter
> 2. in Python:   import os; os.system('/bin/bash')
> 3. In the just opened subshell:   python manage.py syncdb
> 
> Again, it doesn't create my own model tables, just the system tables.
> 
> Ralph
> 

Well, then let's put it another way: the only way that two
instantiations of the same program run differently is if they have
different inputs. 
Your inputs for this program are the command line, the environment and
the source code. Since you neither change the source code nor the
command line, the answer must be in your environment. 

Perhaps some difference between your .bash_profile and your .bashrc?
Running '/bin/bash' will source your .bashrc but not your .bash_profile,
and logging into a console will surely run bash as a login shell (and
hence source your .bash_profile). 

What if you change step 2 to:
        2. in Python: import os; os.system('/bin/bash -l')


Cheers

Tom


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to