From bdbc08e0abaf1cbd88a34145f933ed266c8051db Mon Sep 17 00:00:00 2001 From: John Ralls Date: Wed, 22 Apr 2026 11:28:31 -0700 Subject: [PATCH] Python Bindings: Destroy the QofSession in the Python Session dtor. Failing to do so can leave a DBI database locked, see https://github.com/Gnucash/gnucash/pull/2203 --- bindings/python/gnucash_core.py | 1 + 1 file changed, 1 insertion(+) diff --git a/bindings/python/gnucash_core.py b/bindings/python/gnucash_core.py index 61fff6e6b0..563ceee0d8 100644 --- a/bindings/python/gnucash_core.py +++ b/bindings/python/gnucash_core.py @@ -372,6 +372,7 @@ class Session(GnuCashCoreClass): if not exc_type: self.save() self.end() + self.destroy() def raise_backend_errors(self, called_function="qof_session function"): """Raises a GnuCashBackendException if there are outstanding