fixing eposh problems

This commit is contained in:
bt0dotninja 2020-03-11 10:50:16 -06:00
commit 96292db3c1
3 changed files with 7 additions and 6 deletions

View file

@ -93,4 +93,4 @@ This will create `stats.svg` in your `$pwd`.
#### Basic Troubleshooting :
Please take a look at this [blog-post](https://sachinwrites.xyz/2016/05/28/getting-fedstats-gsoc-production-ready/).
#####TODO

View file

@ -161,10 +161,11 @@ def save_text_metrics(output_json):
fout = open(fname, 'a')
# Write the dates into CSV
if not text_init and stats.end and stats.start:
fout.write(
[['Start Date : ', stats.start],
['End Date : ', stats.end],
['']])
fout.write( "Start Date : {}\n End Date : {}\n".format(stats.start,stats.end))
#fout.write(
# [['Start Date : ', stats.start],
# ['End Date : ', stats.end],
# ['']])
text_init = True
# Initial heading row

View file

@ -26,7 +26,7 @@ unicode_json = {}
def return_epoch(time):
if time == '':
return ''
tup = map(int, time.split('/'))
tup =list( map(int, time.split('/')))
l = (tup[2], tup[0], tup[1], 0, 0, 0)
epochs = calendar.timegm(l)
return (int(epochs))