I am getting the following stacktrace using dateutil
to parse a date:
>>> dateutil.parser.parse('Sept 18 2014', fuzzy=True).date()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/parser.py", line 697, in parse
return DEFAULTPARSER.parse(timestr, **kwargs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/parser.py", line 310, in parse
ret = default.replace(**repl)
ValueError: month must be in 1..12
This works:
dateutil.parser.parse('Sep 18 2014', fuzzy=True).date()
Any idea how I can fix this, given user input similar to the above?