File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change 2020 PostgreSQLCreateUserError ,
2121 PostgreSQLDeleteUserError ,
2222 PostgreSQLListUsersError ,
23+ PostgreSQLUndefinedHostError ,
24+ PostgreSQLUndefinedPasswordError ,
2325)
2426from ops .charm import RelationBrokenEvent
2527from ops .framework import Object
@@ -171,7 +173,12 @@ def oversee_users(self) -> None:
171173 database_users = {
172174 user for user in self .charm .postgresql .list_users () if user .startswith ("relation-" )
173175 }
174- except PostgreSQLListUsersError :
176+ except (
177+ PostgreSQLListUsersError ,
178+ PostgreSQLUndefinedHostError ,
179+ PostgreSQLUndefinedPasswordError ,
180+ ) as e :
181+ logger .error ("Early-exit, failed to oversee users: %r" , e )
175182 return
176183
177184 # Retrieve the users from the active relations.
You can’t perform that action at this time.
0 commit comments