Re: Logging thread with Queue and multiple threads to log messages

2008-11-10 Thread Vinay Sajip
On Nov 9, 8:28 pm, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I am trying to put up a queue (through aloggingthread) so that all worker threads can ask it to log messages. However, the problem I am facing is that, well, theloggingthread itself is running forever. It does not know when it

Re: Logging thread with Queue and multiple threads to log messages

2008-11-10 Thread Floris Bruynooghe
Hi On Nov 9, 8:28 pm, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I am trying to put up a queue (through a logging thread) so that all worker threads can ask it to log messages. There is no need to do anything like this, the logging module is thread safe and you can happily just create loggers

Re: Logging thread with Queue and multiple threads to log messages

2008-11-10 Thread [EMAIL PROTECTED]
Thank you guys, indeed, calling join() for each thread actually solved the problem. I misunderstood it and call join() right after start() so it didn't work the way I wanted. for i in range(args.threads): children[i].join() -- http://mail.python.org/mailman/listinfo/python-list

Logging thread with Queue and multiple threads to log messages

2008-11-09 Thread [EMAIL PROTECTED]
I am trying to put up a queue (through a logging thread) so that all worker threads can ask it to log messages. However, the problem I am facing is that, well, the logging thread itself is running forever. It does not know when it should exit. Any suggestion? None of the worker threads knows