[Python-Dev] Consistent logging in the standard library (original) (raw)
Vinay Sajip vinay_sajip at yahoo.co.uk
Wed Sep 17 17:43:58 EDT 2003
- Previous message: [Python-Dev] Py2.3.1
- Next message: [Python-Dev] Consistent logging in the standard library
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
A recent thread has discussed integrating logging with the rest of the standard library. Among other things, a question has arisen about what logging channel names standard library modules should use, and possible clashes with channel names used by applications.
I'd like to propose that some portion of the namespace be reserved for use by logging in the standard library. If acceptable, all that would need to be done would be to update the documentation to indicate the namespace reservation. The actual use of the namespace could be implemented as and when each module is changed to use the logging module.
The scheme of having all standard library logging under one umbrella allows applications to be configured so that all library-level messages can be routed to specific handlers, filtered simply at one point, etc.
My preference for namespace reservation is that any logger name beginning with "python." should be reserved for use by the standard distribution. I think that each module should use an eponymous logging channel name rooted in the hierarchy for the Python library - e.g. asyncore would use "python.asyncore", etc.
Matthew Barnes, who kicked off the original thread, prefers "stdlib" as the prefix to use, rather than "python".
Comments, please!
Vinay Sajip
- Previous message: [Python-Dev] Py2.3.1
- Next message: [Python-Dev] Consistent logging in the standard library
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]