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

calling basicConfig at this level for a library that should be embedded changes all dowstream logs #14

Closed
erans opened this issue Sep 22, 2022 · 1 comment · Fixed by #13
Assignees
Labels
enhancement New feature or request

Comments

@erans
Copy link
Contributor

erans commented Sep 22, 2022

Calling basicConfig on the top of the file for a library that is embedded into other projects can cause issue.
I suggest you drop it completely specifically because there are no change to it other than setting the default level to INFO.

basicConfig(level=INFO)

In our case it added ":" to the start of every log line.

@byteskeptical byteskeptical linked a pull request Sep 22, 2022 that will close this issue
@byteskeptical
Copy link
Owner

I'm not against removing it, but since it is called but default anyway on the first invocation of warning(), error(), info() or debug() if not already called I thought it best to be explicit as it allows for easy switching between levels during development. Can you provide example output of the difference without to get a better idea of the issue?

@byteskeptical byteskeptical added the enhancement New feature or request label Sep 22, 2022
@byteskeptical byteskeptical changed the title calling basicConfig at this level for a library that should be embeded changes all dowstream logs calling basicConfig at this level for a library that should be embedded changes all dowstream logs Sep 22, 2022
@byteskeptical byteskeptical self-assigned this Sep 22, 2022
@byteskeptical byteskeptical linked a pull request Sep 24, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
2 participants