dateutil.parser.parse unexpected and wrong parse

Bug #954491 reported by Brian Larsen
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
dateutil
Confirmed
Undecided
Unassigned

Bug Description

We just had an application where dates were specified as DOY (%j in strptime), dateutil.parser.parse happily parsed this in an odd and incorrect way.

Here is an example
In [5]: dateutil.parser.parse('2013:045 00:00:00')
Out[5]: datetime.datetime(2012, 3, 13, 0, 0)

Instead of failing or doing anything I can figure from the above it gave todays datetime.

It should instead give an error or
datetime.datetime(2013, 2, 14, 0, 0)

Changed in dateutil:
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.