Commit 7bf5ac9 David Erb
committed
1 parent c40e828 commit 7bf5ac9 Copy full SHA for 7bf5ac9
File tree 1 file changed +8
-2
lines changed
1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -215,9 +215,15 @@ async def disconnect(self):
215
215
216
216
if self .__connection is not None :
217
217
# Commit final transaction if not currently autocommitting.
218
- if not self .__connection .get_autocommit ():
219
- logger .debug (f"[DISSHU] { callsign (self )} committing final transaction" )
218
+ try :
220
219
await self .__connection .commit ()
220
+ logger .debug (
221
+ f"[DISSHU] { callsign (self )} successfully committed final transaction"
222
+ )
223
+ except Exception as exception :
224
+ logger .warning (
225
+ callsign (self , explain (exception , "committing final transaction" ))
226
+ )
221
227
logger .debug (f"[DISSHU] { callsign (self )} closing connection to server" )
222
228
self .__connection .close ()
223
229
self .__connection = None
You can’t perform that action at this time.
0 commit comments