Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

new loggers inherit root logger properties #18

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

wildart
Copy link

@wildart wildart commented Apr 28, 2015

New loggers inherit root logger properties unless specified otherwise explicitly.

julia> using Logging

julia> Logging.configure(level=DEBUG) # root is DEBUG now
Logger(root,DEBUG,TTY(open, 0 bytes waiting),root)

julia> logger1 = Logger("logger1") # logger1 is DEBUG as well
Logger(logger1,DEBUG,TTY(open, 0 bytes waiting),root)

julia> logger2 = Logger("logger2", level=INFO) # logger2 is INFO
Logger(logger2,INFO,TTY(open, 0 bytes waiting),root)

Plus, compatibility and trailing spaces fix.

@kmsquire
Copy link
Owner

This seems reasonable. Can you add a note to the README under "More advanced usage"?

@colinfang
Copy link

I would like the child logger behave the same as the ones in Python Logging, with unset level so that it follows the runtime level of root logger.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants