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

Prevent leaving breadcrumbs when log is below a certain level #55

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bonroyage
Copy link

Goal

Currently anything that is below the notify level gets added as a breadcrumb on a log that is notifiable. In one of our apps we use debug logs extensively during development, but don't expect these to be logged on a production environment at all, because they can contain sensitive data.

The intention of the breadcrumbLevel is to set a minimum level of a log message for it to be added as a breadcrumb.

Design

I have kept it in line with the existing notifyLevel property and setNotifyLevel method. The default for the breadcrumbLevel is DEBUG. Unless explicitly changed, functionally nothing with change for existing users.

Testing

Existing test was modified to set the minimum breadcrumb level to INFO, causing the DEBUG log that was there not to trigger the leaveBreadcrumb method.

@clr182 clr182 added the feature request Request for a new feature label Dec 1, 2023
@clr182
Copy link

clr182 commented Dec 1, 2023

Hi @bonroyage
Thank you for opening this PR. I've passed it on to our engineers for further consideration. We will let you know more once we have an update.

@clr182 clr182 added the backlog We hope to fix this feature/bug in the future label Dec 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog We hope to fix this feature/bug in the future feature request Request for a new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants