1
0
mirror of https://github.com/EDCD/EDMarketConnector.git synced 2025-04-14 08:17:13 +03:00

Add UTC timezone to timestamps in BPC and CSV output.

This commit is contained in:
Jonathan Harris 2015-06-04 18:48:52 +01:00
parent d6d80aa441
commit eb940f52dc

2
bpc.py
View File

@ -14,7 +14,7 @@ def export(data, csv=False):
filename = join(config.get('outdir'), '%s.%s.%s.%s' % (data['lastSystem']['name'].strip(), data['lastStarport']['name'].strip(), time.strftime('%Y-%m-%dT%H.%M.%S', time.localtime(querytime)), csv and 'csv' or 'bpc'))
timestamp = time.strftime('%Y-%m-%dT%H:%M:%S', time.gmtime(querytime))
timestamp = time.strftime('%Y-%m-%dT%H:%M:%SZ', time.gmtime(querytime))
if csv:
header = 'System;Station;Commodity;Sell;Buy;Demand;;Supply;;Date;\n'
rowheader = '%s;%s' % (data['lastSystem']['name'].strip(), data['lastStarport']['name'].strip())