Make DateType capable of deserializing dates outside of datetime.MIN/MAX_YEAR

Description

https://issues.apache.org/jira/browse/CASSANDRA-10625

This blows up for large timestamps.

We may need to introduce a new type similar to util.Date and util.Time that falls back to integer display when Python can't do the date math.
https://github.com/datastax/python-driver/blob/2.7.2/cassandra/util.py#L1012-L1018

Environment

None

Pull Requests

None

Activity

Show:

Sylwia Szunejko 
March 25, 2024 at 10:23 AM

Is there a plan to fix deserializing dates outside of datetime.MIN/MAX_YEAR? This bug is known for several years, but is always using workarounds still considered the best solutions?

I submitted DRAFT PR which introduce a new type similar to util.Date and util.Time that falls back to integer display when Python can't do the date math. I am aware that this is a breaking change, so it should be carefully discussed if it is even worth the effort. I would like to start this discussion.

Adam Holmberg 
February 19, 2016 at 8:10 PM

Server patch was accepted.

Adam Holmberg 
November 24, 2015 at 8:30 PM

I've proposed a cqlsh update that does not require driver changes.

Sitting on this while we discuss on the Cassandra ticket.

Not a Problem

Details

Assignee

Reporter

Sprint

Priority

Created November 3, 2015 at 4:18 PM
Updated March 25, 2024 at 10:23 AM
Resolved February 19, 2016 at 8:10 PM