Re: how to make cron works

2008-02-15 Thread Thomas Guettler
On unix (at least linux) you can run a script with an empty environment like this: env -i path/to/script This way you can test on the shell what goes wrong. I do all the set up in .bashrc an and run the cron job like this: 0 * * * . $HOME/.bashrc; $HOME/.../script HTH, Thomas [EMAIL PROTECT

Re: how to make cron works

2008-02-14 Thread Amit Ramon
As Malcolm pointed before, the problem is most likely with the value of your PYTHONPATH environment variable. Since you're using a shell script, simply set this variable in this script itself, before invoking the python script. --- Amit * [EMAIL PROTECTED] <[EMAIL PROTECTED]> [2008-02-14 22:07

Re: how to make cron works

2008-02-14 Thread [EMAIL PROTECTED]
thanks! i need to focus on mkaing shell script works for me On Feb 15, 2:17 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Thu, 2008-02-14 at 22:07 -0800, [EMAIL PROTECTED] wrote: > > the error as below: > > 1.  Traceback (most recent call last): > >  File "feedup.py", line 3, in ? > >    

Re: how to make cron works

2008-02-14 Thread Malcolm Tredinnick
On Thu, 2008-02-14 at 22:07 -0800, [EMAIL PROTECTED] wrote: > the error as below: > 1. Traceback (most recent call last): > File "feedup.py", line 3, in ? >from django.core.management import setup_environ > ImportError: No module named django.core.management > > 2. Traceback (most recent c

Re: how to make cron works

2008-02-14 Thread [EMAIL PROTECTED]
the error as below: 1. Traceback (most recent call last): File "feedup.py", line 3, in ? from django.core.management import setup_environ ImportError: No module named django.core.management 2. Traceback (most recent call last): File "mstart", line 13, in ? import msnlib ImportError: No m

Re: how to make cron works

2008-02-14 Thread Malcolm Tredinnick
On Thu, 2008-02-14 at 21:32 -0800, [EMAIL PROTECTED] wrote: > i have a python script which works smooth for me in command line. > but now it cannot work in cron job. > > path: /home/data > script: test.py > it works as i type : python test.py > > now i wirte a shell script as below(test.sh):