Skip to content

logging configuration turns off existing loggers #1381

@caseyjlaw

Description

@caseyjlaw

I'm developing an application based on distributed. That is, I intend to run a Python session, import a few libraries, including distributed, then execute code.
I am using the logging-file-config to control logging. However, the call to configure logging disables existing loggers by default. The code is at

logging.config.fileConfig(config['logging-file-config'])
.
It took a while to figure this out, but when calling fileConfig, this argument is also needed disable_existing_loggers=False. The logging library suggests this is "for backwards compatibility", but that does not seem like a pressing concern here. I've made a PR to keep existing loggers enabled.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions