[Python-Dev] Problems with regrtest and with logging (original) (raw)
Vinay Sajip vinay_sajip at yahoo.co.uk
Wed May 11 21:45:12 CEST 2011
- Previous message: [Python-Dev] Problems with regrtest and with logging
- Next message: [Python-Dev] Problems with regrtest and with logging
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Éric Araujo <merwok netwok.org> writes:
I thought that if we set the level on the logger, we would prevent third-party code to get some messages. E.g., we set level to INFO but pip uses some packaging functions and would like to get DEBUG messages.
Then pip can set the level of the packaging logger as it wishes, perhaps in response to command-line arguments for verbosity. It'd be easier for pip to do that, regardless of which handlers are attached. And pip itself might be being used, say by virtualenv. It's hard in general to say what the top-level code will be, and generally that's the code which should set the handlers.
The levels set by a library for its loggers are merely defaults. Applications using the library can choose to override those levels as they wish.
Regards,
Vinay Sajip
- Previous message: [Python-Dev] Problems with regrtest and with logging
- Next message: [Python-Dev] Problems with regrtest and with logging
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]