File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
lib/charms/postgresql_k8s/v0 Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 35
35
36
36
# Increment this PATCH version before using `charmcraft publish-lib` or reset
37
37
# to 0 if you are raising the major API version
38
- LIBPATCH = 48
38
+ LIBPATCH = 49
39
39
40
40
# Groups to distinguish HBA access
41
41
ACCESS_GROUP_IDENTITY = "identity_access"
@@ -626,6 +626,7 @@ def list_access_groups(self) -> Set[str]:
626
626
Returns:
627
627
List of PostgreSQL database access groups.
628
628
"""
629
+ connection = None
629
630
try :
630
631
with self ._connect_to_database () as connection , connection .cursor () as cursor :
631
632
cursor .execute (
@@ -646,6 +647,7 @@ def list_users(self) -> Set[str]:
646
647
Returns:
647
648
List of PostgreSQL database users.
648
649
"""
650
+ connection = None
649
651
try :
650
652
with self ._connect_to_database () as connection , connection .cursor () as cursor :
651
653
cursor .execute ("SELECT usename FROM pg_catalog.pg_user;" )
@@ -664,6 +666,7 @@ def list_users_from_relation(self) -> Set[str]:
664
666
Returns:
665
667
List of PostgreSQL database users.
666
668
"""
669
+ connection = None
667
670
try :
668
671
with self ._connect_to_database () as connection , connection .cursor () as cursor :
669
672
cursor .execute (
You can’t perform that action at this time.
0 commit comments