What's wrong with my logging configuration
ben+python at benfinney.id.au
Sun Nov 28 01:59:50 CET 2010
rambius <rambiusparkisanius at gmail.com> writes:
> On what environment did you try it?
I get the same results with both Python 2 and Python 3 on GNU+Linux:
Python 2.6.6 (r266:84292, Oct 9 2010, 13:53:14)
Python 3.1.3rc1 (r313rc1:86453, Nov 14 2010, 05:49:40)
> This is so strange. If I import optparse outside of main() it works.
> If I import it between the two logging statement, the second one does
> not appear.
Is there a rogue module in your project tree that, by being named the
same as one of the standard library modules, shadows that module?
Does the same problem behaviour occur if you import some other module in
place of ‘optparse’?
Can you reduce the content of your ‘logging.config’ and still see the
same problem behaviour (i.e. do you really have the minimum complete
example yet)? What is the minimal config file that still results in the
same behaviour for you?
\ “Welchen Teil von ‘Gestalt’ verstehen Sie nicht? [What part of |
`\ ‘gestalt’ don't you understand?]” —Karsten M. Self |
More information about the Python-list