Skip to content

Commit 1686686

Browse files
d-w-moorekorydraughn
authored andcommitted
[#691] trap exception in connection finalizer
1 parent d1743eb commit 1686686

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

irods/connection.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,10 @@ def client_signature(self):
145145
return self._client_signature
146146

147147
def __del__(self):
148-
self.disconnect()
148+
try:
149+
self.disconnect()
150+
except Exception as e:
151+
logger.info("Exception in finalizer: [%r]", e)
149152
logger.debug(DESTRUCTOR_MSG)
150153

151154
def send(self, message):

0 commit comments

Comments
 (0)