[CONPY-59] Cursor fetchall with error Created: 2020-04-23  Updated: 2020-04-23  Resolved: 2020-04-23

Status: Closed
Project: MariaDB Connector/Python
Component/s: DBAPI 2.0, Generic
Affects Version/s: 0.9.57
Fix Version/s: 0.9.58

Type: Bug Priority: Minor
Reporter: Cody Christopher Assignee: Georg Richter
Resolution: Fixed Votes: 0
Labels: None
Environment:

Ubuntu 18.04.4 LTS Bionic
Python 3.7.0
libmariadb-dev:
Installed: 1:10.4.12+maria~bionic
Candidate: 1:10.4.12+maria~bionic



 Description   

I suspect this might be similar to: https://github.com/mkleehammer/pyodbc/issues/475

I'm attempting to query a table on a remote server via python (unfortunately I cannot provide the data causing the problem), and mariadb pipeline returns a value error:

---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
ValueError: year 0 is out of range

The above exception was the direct cause of the following exception:

SystemError Traceback (most recent call last)
<ipython-input-5-dd76bdee1402> in <module>
---> 27 res = cur.fetchall()

SystemError: <method 'fetchall' of 'mariadb.connection.cursor' objects> returned a result with an error set



 Comments   
Comment by Georg Richter [ 2020-04-23 ]

fixed in rev. 30281329fa93b44030a5e8cbc78e5f20db1407e7

Instead of rasing an exception for incorrect date(time) values a None value will be returned.

Generated at Thu Feb 08 03:29:56 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.