Commit 8bd413c 1 parent 5bf2c87 commit 8bd413c Copy full SHA for 8bd413c
File tree 1 file changed +3
-2
lines changed
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 50
50
filters = json .dumps ({"filter" : input_data .get ("filter" , {})})
51
51
case_ids = gql .execute (filters = filters )
52
52
53
- if os .path .exists ("/peregrine-creds.json" )
53
+ if os .path .exists ("/peregrine-creds.json" ):
54
54
try :
55
55
with open ("/peregrine-creds.json" ) as pelican_creds_file :
56
56
peregrine_creds = json .load (pelican_creds_file )
57
57
except json .JSONDecodeError as e :
58
58
print (f"Failed to load credentials file: { e } " )
59
59
peregrine_creds = {}
60
60
else :
61
- print (f"Credentials file not found: { e } " )
61
+ print (f"Credentials file not found. Using environment variables." )
62
+ peregrine_creds = {}
62
63
63
64
# Set variables, prioritizing environment variables
64
65
DB_HOST = os .getenv ("DB_HOST" , peregrine_creds .get ("db_host" ))
You can’t perform that action at this time.
0 commit comments