You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cursor fails with "ReferenceError: weakly-referenced object no longer exists" after use with executemany().
The following program reproduced the error on both my systems. It worked using fdb 1.4.x.
-------------------------
import fdb
connection = fdb.create_database("CREATE DATABASE 'test.db' user 'SYSDBA' password 'masterkey'")
cursor = connection.cursor()
cursor.execute("CREATE TABLE TEST (ID INTEGER PRIMARY KEY)")
connection.commit()
cursor.executemany("INSERT INTO TEST VALUES(?)", [(1,), (2,)])
cursor.executemany("INSERT INTO TEST VALUES(?)", [(3,), (4,)])
-------------------------
Traceback (most recent call last):
File "C:\Users\swn\Programmering\tmp\fdb_weak_ref.py", line 14, in <module>
cursor.executemany("INSERT INTO TEST VALUES(?)", [(3,), (4,)])
File "C:\Program Files\Python35\lib\site-packages\fdb\http://fbcore.py", line 3625, in executemany
self.execute(operation, parameters)
File "C:\Program Files\Python35\lib\site-packages\fdb\http://fbcore.py", line 3564, in execute
if self._ps != None:
ReferenceError: weakly-referenced object no longer exists
Submitted by: Søren Nielsen (swn)
Cursor fails with "ReferenceError: weakly-referenced object no longer exists" after use with executemany().
The following program reproduced the error on both my systems. It worked using fdb 1.4.x.
-------------------------
import fdb
connection = fdb.create_database("CREATE DATABASE 'test.db' user 'SYSDBA' password 'masterkey'")
cursor = connection.cursor()
cursor.execute("CREATE TABLE TEST (ID INTEGER PRIMARY KEY)")
connection.commit()
cursor.executemany("INSERT INTO TEST VALUES(?)", [(1,), (2,)])
cursor.executemany("INSERT INTO TEST VALUES(?)", [(3,), (4,)])
-------------------------
Traceback (most recent call last):
File "C:\Users\swn\Programmering\tmp\fdb_weak_ref.py", line 14, in <module>
cursor.executemany("INSERT INTO TEST VALUES(?)", [(3,), (4,)])
File "C:\Program Files\Python35\lib\site-packages\fdb\http://fbcore.py", line 3625, in executemany
self.execute(operation, parameters)
File "C:\Program Files\Python35\lib\site-packages\fdb\http://fbcore.py", line 3564, in execute
if self._ps != None:
ReferenceError: weakly-referenced object no longer exists
Commits: c37c256 FirebirdSQL/fbt-repository@c507b0a
The text was updated successfully, but these errors were encountered: