Skip to content

Commit 4490560

Browse files
committed
Fix cleanup of connections.
1 parent 8d86551 commit 4490560

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

shared/wait-for-psql.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,9 @@
2121
try:
2222
conn = psycopg2.connect(user=args.db_user, host=args.db_host, port=args.db_port, password=args.db_password, dbname=args.db_name)
2323
error = ''
24-
break
2524
except psycopg2.OperationalError as e:
2625
error = e
27-
else:
26+
finally:
2827
conn.close()
2928
time.sleep(1)
3029

0 commit comments

Comments
 (0)