Merge "timestamp parsed into utc instead of localtime(which was default) Closes Bug:#160531"

This commit is contained in:
Jenkins 2016-07-25 15:28:03 +00:00 committed by Gerrit Code Review
commit aa7addbc84
2 changed files with 4 additions and 4 deletions

View File

@ -83,7 +83,7 @@ class RollupQuantity(SetterComponent):
row, "min(firstrecord_timestamp_unix)",
Component.DEFAULT_UNAVAILABLE_VALUE)
earliest_record_timestamp_string = \
datetime.datetime.fromtimestamp(
datetime.datetime.utcfromtimestamp(
earliest_record_timestamp_unix).strftime(
'%Y-%m-%d %H:%M:%S')
@ -92,7 +92,7 @@ class RollupQuantity(SetterComponent):
row, "max(lastrecord_timestamp_unix)",
Component.DEFAULT_UNAVAILABLE_VALUE)
latest_record_timestamp_string = \
datetime.datetime.fromtimestamp(
datetime.datetime.utcfromtimestamp(
latest_record_timestamp_unix).strftime('%Y-%m-%d %H:%M:%S')
# record count

View File

@ -186,7 +186,7 @@ class FetchQuantity(UsageComponent):
row, "min(event_timestamp_unix_for_min)",
Component.DEFAULT_UNAVAILABLE_VALUE)
earliest_record_timestamp_string = \
datetime.datetime.fromtimestamp(
datetime.datetime.utcfromtimestamp(
earliest_record_timestamp_unix).strftime(
'%Y-%m-%d %H:%M:%S')
@ -195,7 +195,7 @@ class FetchQuantity(UsageComponent):
row, "max(event_timestamp_unix_for_max)",
Component.DEFAULT_UNAVAILABLE_VALUE)
latest_record_timestamp_string = \
datetime.datetime.fromtimestamp(
datetime.datetime.utcfromtimestamp(
latest_record_timestamp_unix).strftime('%Y-%m-%d %H:%M:%S')
# record count