It seems Jan 14 at 10am is recognized properly, but Jan 14 at 10 is not. It may introduce other issues if "10" is somehow parsed, this may be by design but I wanted to share nonetheless. If it is by design, let me know. Or perhaps there is a flag to parse a little more loosely so that 10 may be recognized.
I have this function:
def get_time(value, timezone_string): cal = parsedatetime.Calendar() datetime_obj, parse_status = cal.parseDT(datetimeString=value, sourceTime=arrow.get().to(timezone_string).datetime, tzinfo=timezone(timezone_string)) if not parse_status: return None return datetime_obj
Look at these 3 differences (all processed in a few seconds)
It seems Jan 14 at 10am is recognized properly, but Jan 14 at 10 is not. It may introduce other issues if "10" is somehow parsed, this may be by design but I wanted to share nonetheless. If it is by design, let me know. Or perhaps there is a flag to parse a little more loosely so that 10 may be recognized.