classification
Title: add a loggerClass attribute to Manager
Type: enhancement Stage: patch review
Components: Versions: Python 3.2, Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: vinay.sajip Nosy List: eric.araujo, georg.brandl, vinay.sajip
Priority: high Keywords: easy, patch

Created on 2010-02-06 22:06 by georg.brandl, last changed 2010-02-07 09:02 by georg.brandl. This issue is now closed.

Files
File name Uploaded Description Edit
logging.diff georg.brandl, 2010-02-06 22:06 patch v1
Messages (7)
msg98964 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2010-02-06 22:06
This patch adds a loggerClass attribute to logging's Manager, and a setLoggerClass() function to set it.  If no loggerClass is set, the global _loggerClass is used.  This is for maximum backwards compatibility.

There are no doc updates as the Manager is not documented.
msg98965 - (view) Author: Éric Araujo (eric.araujo) * (Python committer) Date: 2010-02-06 22:09
Hello

I know the internal style (or lack thereof :) of logging forces you to use unReadableNames, but could the ocde use “cls” instead of “class”, as per PEP 8?

Kind regards
msg98966 - (view) Author: Éric Araujo (eric.araujo) * (Python committer) Date: 2010-02-06 22:10
s/ocde/code/
msg98968 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2010-02-06 22:13
You mean, instead of "klass"?  It is used in the other setLoggerClass(), and therefore consistent.
msg98969 - (view) Author: Éric Araujo (eric.araujo) * (Python committer) Date: 2010-02-06 22:15
I meant “klass”, right. My fingers are trained not to write it, it seems.

Ok, it’s already used elsewhere in the module. Too bad.

Kind regards
msg98976 - (view) Author: Vinay Sajip (vinay.sajip) * (Python committer) Date: 2010-02-07 01:38
Patch applied to trunk (r78055).
msg98984 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2010-02-07 09:02
Thanks!
History
Date User Action Args
2010-02-07 09:02:08georg.brandlsetkeywords: patch, patch, easy

messages: + msg98984
2010-02-07 01:38:13vinay.sajipsetstatus: open -> closed
keywords: patch, patch, easy
resolution: fixed
messages: + msg98976
2010-02-06 22:15:24eric.araujosetmessages: + msg98969
2010-02-06 22:13:22georg.brandlsetkeywords: patch, patch, easy

messages: + msg98968
2010-02-06 22:10:19eric.araujosetmessages: + msg98966
2010-02-06 22:09:57eric.araujosetnosy: + eric.araujo
messages: + msg98965
2010-02-06 22:06:31georg.brandlcreate