The min year within a date in python is 1 and since 0000 is less than the min date we are getting this error. How can we handle this to get the values?
I believe the issue is with Pythons datetime.date class when parsing the datetime objects. The date class expects a year, month and day. According to the documentation, year must be between MINYEAR and MAXYEAR
datetime.MINYEAR
The smallest year number allowed in a date or datetime object. MINYEAR is 1.
datetime.MAXYEAR
The largest year number allowed in a date or datetime object. MAXYEAR is 9999.
so python is throwing an exception when the date class is given a date with no year 0000. I will raise this issue with my team.