From 0ed670c03b5309bacbe63705b34038bd0554bb92 Mon Sep 17 00:00:00 2001 From: Kevin Smith Date: Wed, 31 Jul 2024 12:20:55 -0500 Subject: [PATCH] Fix cyclical references --- singlestoredb/mysql/connection.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/singlestoredb/mysql/connection.py b/singlestoredb/mysql/connection.py index cdf57199..b388ee4b 100644 --- a/singlestoredb/mysql/connection.py +++ b/singlestoredb/mysql/connection.py @@ -716,6 +716,7 @@ def close(self): Error : If the connection is already closed. """ + self._result = None if self.host == 'singlestore.com': return if self._closed: @@ -1909,12 +1910,12 @@ def __init__(self, connection, unbuffered=False): encoding_errors=connection.encoding_errors, ).items() if v is not UNSET } - self._read_rowdata_packet = functools.partial( - _singlestoredb_accel.read_rowdata_packet, self, False, - ) - self._read_rowdata_packet_unbuffered = functools.partial( - _singlestoredb_accel.read_rowdata_packet, self, True, - ) + + def _read_rowdata_packet(self, *args, **kwargs): + return _singlestoredb_accel.read_rowdata_packet(self, False, *args, **kwargs) + + def _read_rowdata_packet_unbuffered(self, *args, **kwargs): + return _singlestoredb_accel.read_rowdata_packet(self, True, *args, **kwargs) class LoadLocalFile: