Skip to content

Commit

Permalink
Merge branch 'release_15.10' into release_16.01
Browse files Browse the repository at this point in the history
Conflicts:
	lib/galaxy/util/__init__.py
  • Loading branch information
nsoranzo committed Feb 19, 2016
2 parents b4c823f + 6c83fbe commit b5e91d2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/galaxy/util/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,11 @@ def pretty_print_time_interval( time=False, precise=False ):
elif isinstance( time, datetime ):
diff = now - time
elif isinstance( time, string_types ):
time = datetime.strptime( time, "%Y-%m-%dT%H:%M:%S.%f" )
try:
time = datetime.strptime( time, "%Y-%m-%dT%H:%M:%S.%f" )
except ValueError:
# MySQL may not support microseconds precision
time = datetime.strptime( time, "%Y-%m-%dT%H:%M:%S" )
diff = now - time
else:
diff = now - now
Expand Down

0 comments on commit b5e91d2

Please sign in to comment.