Re: logging to two files

2005-04-20 Thread Duncan Booth
not use basicConfig if you want multiple handlers. Instead set up the configuration explicitly. Here is some code I used recently which you can use as a base. It isn't logging to two files, instead it logs to a file and the console. # Initialise logging def setupLogging(): SCRIPT = os.pa

Re: logging to two files

2005-04-20 Thread Laszlo Zsolt Nagy
Tor Erik Sønvisen wrote: Hi Have the following code: import logging logging.basicConfig(level = logging.DEBUG, format = '[%(levelname)-8s %(asctime)s] %(message)s', filename = 'rfs.log', filemode = 'w') When u

logging to two files

2005-04-20 Thread Tor Erik Sønvisen
Hi Have the following code: import logging logging.basicConfig(level = logging.DEBUG, format = '[%(levelname)-8s %(asctime)s] %(message)s', filename = 'rfs.log', filemode = 'w') When using logging.(debug