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

[FEAT] Add function to refresh logger state for rust #2323

Merged
merged 1 commit into from
May 29, 2024

Conversation

samster25
Copy link
Member

@samster25 samster25 commented May 29, 2024

When daft is imported it cached the current python log level to avoid grabbing the GIL for every log statement. See this page for more details.

This PR exposes a method to "refresh" the cache. This is useful when the user updates the log level later in the code, like when they configure logging.

Here is a example showing this. Note prior to refreshing the logger, no logs were coming out!
image

@github-actions github-actions bot added the enhancement New feature or request label May 29, 2024
@samster25 samster25 enabled auto-merge (squash) May 29, 2024 03:47
@samster25 samster25 merged commit 8a0d844 into main May 29, 2024
44 checks passed
@samster25 samster25 deleted the sammy/rust-logger-refresh branch May 29, 2024 03:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
1 participant