From cc705b4e41a1f9ad7e6f19fbfe9e6d305eef76e8 Mon Sep 17 00:00:00 2001 From: Jonathan Miller Date: Thu, 9 Jan 2025 10:02:26 -0500 Subject: [PATCH] Split sentry envs --- eve/__init__.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/eve/__init__.py b/eve/__init__.py index 919cd83..bd17463 100644 --- a/eve/__init__.py +++ b/eve/__init__.py @@ -41,9 +41,13 @@ def load_env(db): # start sentry sentry_dsn = os.getenv("SENTRY_DSN") + sentry_env = "production" if db == "PROD" else "staging" if sentry_dsn: sentry_sdk.init( - dsn=sentry_dsn, traces_sample_rate=1.0, profiles_sample_rate=1.0 + dsn=sentry_dsn, + traces_sample_rate=1.0, + profiles_sample_rate=1.0, + environment=sentry_env, ) # load api keys