Running a Python script from crontab

gregory.j.baker at gregory.j.baker at
Tue Dec 2 21:27:15 CET 2008

Try using the following at the begining of your Python program:

import sys

sys.stdout = open("out.txt","w")
sys.stderr = open("err.txt","w")

Then whatever would normally go to stdout or stderr goes to text files
instead.  You will see everything that happened.

More information about the Python-list mailing list