From 2e74f25c1d992d177159a45f63bf7cf7188b73e5 Mon Sep 17 00:00:00 2001 From: c-simpson Date: Tue, 4 May 2021 11:07:39 -0400 Subject: [PATCH] Now catching ImportError instead of KeyError KeyError is if environ access fails. --- src/server/test_api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/test_api.py b/src/server/test_api.py index 18867f8d..401be742 100644 --- a/src/server/test_api.py +++ b/src/server/test_api.py @@ -3,7 +3,7 @@ try: from secrets import BASEUSER_PW, BASEADMIN_PW -except KeyError: +except ImportError: BASEUSER_PW = os.environ['BASEUSER_PW'] BASEADMIN_PW = os.environ['BASEADMIN_PW']