From a41371dd3d49a7bf13ba4e9d4f4ffbd7e6f8958b Mon Sep 17 00:00:00 2001 From: Justin Date: Wed, 9 Nov 2022 17:01:24 +0800 Subject: [PATCH] added back force fetch stock prices upon boot --- database_caller.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/database_caller.py b/database_caller.py index a191736..d69c5fb 100755 --- a/database_caller.py +++ b/database_caller.py @@ -22,14 +22,14 @@ from multiprocessing import Process try: time.sleep(80) -# f = open('csv/last_updates.json', 'r') -# last_updates = json.load(f) -# f.close() -# last_updates['stocks']['force'] = True + 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() + f = open('csv/last_updates.json', 'w') + json.dump(last_updates, f) + f.close() except: pass