Skip to content

Commit

Permalink
print error on db connection issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Mathieu Provencher committed Jul 19, 2023
1 parent bb1d4fe commit 4161e41
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion stac_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,9 @@ async def startup_event():
try:
await connect_to_db(app)
break
except:
except Exception as e:
print("ERROR: Connection to DB failed. Retrying in 3s. ({retries})")
print(e)
time.sleep(3)
retries -= 1

Expand Down

0 comments on commit 4161e41

Please sign in to comment.