mirror of
https://opendev.org/x/pyghmi
synced 2025-10-30 02:42:30 +00:00
Merge "Add month/day/year to parse"
This commit is contained in:
@@ -56,4 +56,8 @@ def parse_time(timeval):
|
||||
return datetime.strptime(timeval, '%Y-%m-%d')
|
||||
except ValueError:
|
||||
pass
|
||||
try:
|
||||
return datetime.strptime(timeval, '%m/%d/%Y')
|
||||
except ValueError:
|
||||
pass
|
||||
return None
|
||||
Reference in New Issue
Block a user