Skip to content

Using a custom logger requires set_logger in every task #16794

New issue

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

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

Already on GitHub? # to your account

Closed
seanmonstar opened this issue Aug 27, 2014 · 1 comment
Closed

Using a custom logger requires set_logger in every task #16794

seanmonstar opened this issue Aug 27, 2014 · 1 comment

Comments

@seanmonstar
Copy link
Contributor

Currently, the logger is stored in TLS. It's fine to setup a logger at the start of your program, but if you use spawn a lot, it's cumbersome to remember in each call to setup your logger again.

I think tasks should inherit the logger from the task that spawned it, perhaps with an option to turn it off (less important).

cc #3309

@steveklabnik
Copy link
Member

This issue has been moved to the RFCs repo: rust-lang/log#21

matthiaskrgr pushed a commit to matthiaskrgr/rust that referenced this issue Mar 10, 2024
Some minor changes in the test explorer lsp extension

followup rust-lang#16662

cc `@nemethf` `@ShuiRuTian`
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants