From 3c2ac30e23744e38aa84f3a673b4cc644bd76c37 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Fri, 25 Feb 2022 11:40:04 -0800 Subject: update sentry SDK configuration --- python/fatcat_cleanup.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'python/fatcat_cleanup.py') diff --git a/python/fatcat_cleanup.py b/python/fatcat_cleanup.py index b5e50425..b2bd4f0f 100755 --- a/python/fatcat_cleanup.py +++ b/python/fatcat_cleanup.py @@ -9,9 +9,6 @@ import sentry_sdk from fatcat_tools import authenticated_api from fatcat_tools.cleanups import FileCleaner, JsonLinePusher -# Yep, a global. Gets DSN from `SENTRY_DSN` environment variable -sentry_client = sentry_sdk.init() - def run_files(args: argparse.Namespace) -> None: fmi = FileCleaner( @@ -71,6 +68,7 @@ def main() -> None: # token is an optional kwarg (can be empty string, None, etc) token=os.environ.get(args.auth_var), ) + sentry_sdk.init(environment=args.env) args.func(args) -- cgit v1.2.3