summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xweather-logger-receiver5
1 files changed, 2 insertions, 3 deletions
diff --git a/weather-logger-receiver b/weather-logger-receiver
index 209c961..5f7cd1b 100755
--- a/weather-logger-receiver
+++ b/weather-logger-receiver
@@ -46,8 +46,7 @@ def add_data_to_db(data, handle, db_connection):
db_connection.commit()
-def loop(config, serial_connection, db_connection, logger):
- known_devices = config["known_devices"][config["active_location"]]
+def loop(known_devices, serial_connection, db_connection, logger):
while True:
logger.info("(Re-)Starting receiver loop")
@@ -139,6 +138,6 @@ if __name__ == "__main__":
try:
loop(known_devices, serial_connection, db_connection, logger)
except Exception as e:
- logger.error(f"Exception: '{e}'")
+ logger.error(f"Exception: {e}")
finally:
shutdown(config, serial_connection, db_connection, logger)