diff --git a/database_caller.py b/database_caller.py index a6e30fe..50390f7 100755 --- a/database_caller.py +++ b/database_caller.py @@ -839,8 +839,8 @@ if __name__ == '__main__': except Exception as e: - print(e) - raise e + print(str(e)) + exc_type, exc_obj, exc_tb = sys.exc_info() fname = os.path.split(exc_tb.tb_frame.f_code.co_filename)[1] logf.write(str(e)) diff --git a/server.py b/server.py index 10f2829..8a3b2b7 100755 --- a/server.py +++ b/server.py @@ -131,8 +131,15 @@ def index(): GIF_settings = json.load(open('csv/GIF_settings.json', 'r')) message_settings = json.load(open('csv/message_settings.json', 'r')) general_settings = json.load(open('csv/general_settings.json', 'r')) - api_keys = api_key2[1] - wifi_SSID = wifiline[5][6:].replace('"','') + try: # incase this doesnt exist + api_keys = api_key2[1] + except: + api_keys = '' + + try: + wifi_SSID = wifiline[5][6:].replace('"','') + except: + wifi_SSID = '' templateData = { diff --git a/setup_config_files.sh b/setup_config_files.sh index 029ad22..b9e8b00 100755 --- a/setup_config_files.sh +++ b/setup_config_files.sh @@ -21,7 +21,7 @@ filenames="crypto_settings.json last_updates.json league_tables.json current_wea echo '{"update_available": false, "first_boot": true}' >> system_info.json echo [\"Standard\", [[\"Stocks\", \"Crypto\", \"Forex\"]]] >> display_settings.json -echo '{"stocks": {"time": "06/03/2022 04:12:09", "force": true}, "crypto": {"time": "06/03/2022 04:10:39", "force": true}, "news": {"time": "06/03/2022 04:07:09", "force": true}, "weather": {"time": "06/03/2022 04:08:20", "force": true}, "forex": {"time": "06/03/2022 03:54:02", "force": true}, "sports": {"time": "06/03/2022 04:10:09", "force": true}}' >> last_updates.json +echo '{"stocks": {"time": "07/03/2022 12:33:06", "force": true}, "crypto": {"time": "07/03/2022 12:28:51", "force": true}, "news": {"time": "07/03/2022 12:28:51", "force": true}, "weather": {"time": "07/03/2022 12:28:51", "force": true}, "forex": {"time": "07/03/2022 12:28:51", "force": true}, "sports_l": {"time": "07/03/2022 12:32:46", "force": true}, "sports_p": {"time": "07/03/2022 12:32:26", "force": true}, "sports_u": {"time": "07/03/2022 12:31:55", "force": true}, "sports_t": {"time": "07/03/2022 12:32:56", "force": true}}' >> last_updates.json echo '{"feature": "Stocks", "speed": "medium","speed2": "medium", "animation": "down", "percent": false, "point": true, "logos": true, "chart": false, "title": true, "symbols": {"ETH,USD": {"current": "2629.32", "24hr_change": "-27.6432", "percent_change": "-1.04"}, "BTC,USD": {"current": "38161.00", "24hr_change": "-50.8386", "percent_change": "-0.13"}, "BNB,USD": {"current": "372.57", "24hr_change": "0.4140", "percent_change": "0.11"}, "ADA,BTC": {"current": "0.0000", "24hr_change": "-0.0000", "percent_change": "-3.74"}}}' >> crypto_settings.json diff --git a/stockTicker.py b/stockTicker.py index 32ed30c..fa45c63 100755 --- a/stockTicker.py +++ b/stockTicker.py @@ -2777,7 +2777,7 @@ if __name__ == '__main__': msg = getInput() stock_ticker.process_msg(msg) except Exception as e: - print(e) + print(str(e)) exc_type, exc_obj, exc_tb = sys.exc_info() fname = os.path.split(exc_tb.tb_frame.f_code.co_filename)[1] diff --git a/templates/index.html b/templates/index.html index e279445..02aeb0b 100644 --- a/templates/index.html +++ b/templates/index.html @@ -2865,7 +2865,7 @@