Graham Dumpleton wrote: > Where does setting up 'logging' module configuration fall in all of > this and who/what should handle it?
Indeed, this is definitely something I've wondered myself... > """paster, when loading an application via the paster serve, shell or > setup-app commands, calls the logging.fileConfig function on that > specified ini file if it contains a 'loggers' entry. > logging.fileConfig reads the logging configuration from a ConfigParser > file.""" I'll the the opportunity to note that I experienced head banging to the point of giving up with fileConfig: iirc it has no ability to use log handlers and the like that aren't defined in the logging package (such as mailinglogger) > So, the paster serve is doing special setup for Pylons WSGI > components. Without knowing this magic is required, when you take a > Pylons WSGI component to another WSGI server, the logging doesn't work > as expected. To get it to work one has to duplicate the special things > that paster serve is doing in some way. The reverse also holds true. If the app configures logging and gets users with paster serve, you'll end up with two sets of logs. For me, it does feel like the responsibility of the server to configure logging, and I think this is something that should be documented somewhere. Afterall, as you guys have been discussing, it's the server that holds configuration for things like listening sockets, etc and logging feels like that kind of thing to me... cheers, Chris -- Simplistix - Content Management, Zope & Python Consulting - http://www.simplistix.co.uk _______________________________________________ Web-SIG mailing list Web-SIG@python.org Web SIG: http://www.python.org/sigs/web-sig Unsubscribe: http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com