thank you for your work making this great reource. Recently, I have had trouble running the following code after I upgraded my system from Ubuntu 18.04 to 20.04. Previously this code ran fine:
import dataset
db = dataset.connect('mysql+mysqlconnector://user@localhost/covid'
result = db.query("alter table patient auto_increment = 1")
Now I get the error:
Traceback (most recent call last):
File "clean_db.py", line 12, in <module>
result = db.query("alter table patient auto_increment = 1")
File "/usr/local/lib/python3.8/dist-packages/dataset/database.py", line 302, in query
return ResultIter(rp, row_type=self.row_type, step=_step)
File "/usr/local/lib/python3.8/dist-packages/dataset/util.py", line 43, in __init__
self.keys = list(result_proxy.keys())
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/result.py", line 700, in keys
return self._metadata.keys
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/cursor.py", line 1201, in keys
self._we_dont_return_rows()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/cursor.py", line 1178, in _we_dont_return_rows
util.raise_(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/util/compat.py", line 198, in raise_
raise exception
sqlalchemy.exc.ResourceClosedError: This result object does not return rows. It has been closed automatically.
Hi,
thank you for your work making this great reource. Recently, I have had trouble running the following code after I upgraded my system from Ubuntu 18.04 to 20.04. Previously this code ran fine:
Now I get the error: