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

Make debug option also configurable via environment #2450

Merged
merged 3 commits into from
Oct 16, 2023

Conversation

antonpirker
Copy link
Member

Introducing new SENTRY_DEBUG environment variable that can be used to set the debug option in sentry_sdk.init().

@antonpirker antonpirker changed the title Make "debug" option also configurable via environment Make debug option also configurable via environment Oct 16, 2023
Comment on lines +113 to +117
rv["debug"] = os.environ.get("SENTRY_DEBUG", "False").lower() in (
"true",
"1",
"t",
)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I kinda remember that we added a helper for determining if a config option was set to something truthy. Can't find it off the top of my head but will look a bit more 👀

Copy link
Contributor

@sentrivana sentrivana left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't find the util function. 🤷🏻‍♀️ LGTM.

@antonpirker
Copy link
Member Author

Thanks!

@antonpirker antonpirker marked this pull request as ready for review October 16, 2023 14:48
@antonpirker antonpirker merged commit fee865c into master Oct 16, 2023
284 checks passed
@antonpirker antonpirker deleted the antonpirker/sentry_debug_env_var branch October 16, 2023 14:48
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.

None yet

2 participants