On Sep 19, 7:52 pm, Vinay Sajip wrote:
> If you are writing a library, you will typically:
> 2. If you want to force your users (application developers) to add
> handlers explicitly to their loggers, set your top-level logger's
> propagate flag to False.
Sorry, in the above text, where it says "t
On Sep 18, 5:35 pm, Lie Ryan wrote:
> I was expecting this to work:
>
> importlogging
> logger =logging.getLogger(__name__)
> logger.warn('this is a warning')
>
> instead it produced the error:
>
> No handlers could be found for logger "__main__"
>
> However, if instead I do:
>
> importl
On Sun, 19 Sep 2010 02:35:15 +1000, Lie Ryan wrote:
> I was expecting this to work:
>
> import logging
> logger = logging.getLogger(__name__)
> logger.warn('this is a warning')
>
> instead it produced the error:
>
> No handlers could be found for logger "__main__"
>
>
> However, if in
I was expecting this to work:
import logging
logger = logging.getLogger(__name__)
logger.warn('this is a warning')
instead it produced the error:
No handlers could be found for logger "__main__"
However, if instead I do:
import logging
logging.warn('creating logger')
logger = lo