Force fetch latest stock data upon boot
This commit is contained in:
@@ -650,7 +650,18 @@ if __name__ == '__main__':
|
|||||||
t = time.time()
|
t = time.time()
|
||||||
update_processes = []
|
update_processes = []
|
||||||
|
|
||||||
|
try:
|
||||||
|
time.sleep(60)
|
||||||
|
f = open('csv/last_updates.json', 'r')
|
||||||
|
last_updates = json.load(f)
|
||||||
|
f.close()
|
||||||
|
last_updates['stocks']['force'] = True
|
||||||
|
#last_updates['weather']['force'] = True
|
||||||
|
f = open('csv/last_updates.json', 'w')
|
||||||
|
json.dump(last_updates, f)
|
||||||
|
f.close()
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user