Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo
Version 1.2.2, timedelta blindly converts timedeltas. MySQL version 4 max TIME max days = 34.
datetime.timedelta(hours=-839, minutes=-59, seconds=-59) using the convert function "'-35 0:0:1'" which is out of bounds for mysql
In : f(datetime.timedelta(hours=-817), None)
Out: "'-35 23:0:0'"
So what do we do about it, considering it's a limitation in the field type?
Its not the limitation part that I was complaining about, but rather that the value datetime.timedelta(hours=-839, minutes=-59, seconds=-59) is within the bounds of MySQL. (When I said max days = 34, I meant < 35), so basically MySQLDB should try to insert "-34 11:59:59" rather than "-35 0:0:1".
The reason why MySQLDB did "-35 0:0:1" is I think because thats what python does when you stringify that specific timedelta. There MySQL should take care of those boundry cases mentioned in the body and other comment.