Only run background telemetry updates when location service is available
This commit is contained in:
parent
19cacd0e86
commit
484d7ddf7a
|
@ -2253,6 +2253,7 @@ class SidebandCore():
|
|||
def telemetry_job():
|
||||
while self.telemetry_running:
|
||||
try:
|
||||
if self.owner_service._gps_started:
|
||||
self.update_telemetry()
|
||||
except Exception as e:
|
||||
import traceback
|
||||
|
@ -2313,7 +2314,10 @@ class SidebandCore():
|
|||
RNS.log("Error while sending latest telemetry to service: "+str(e), RNS.LOG_ERROR)
|
||||
|
||||
except Exception as e:
|
||||
RNS.log("Error while updating telemetry: "+str(e), RNS.LOG_ERROR)
|
||||
import traceback
|
||||
exception_info = "".join(traceback.TracebackException.from_exception(e).format())
|
||||
RNS.log(f"An {str(type(e))} occurred while updating telemetry: {str(e)}", RNS.LOG_ERROR)
|
||||
RNS.log(exception_info, RNS.LOG_ERROR)
|
||||
|
||||
def update_telemeter_config(self):
|
||||
if self.config["telemetry_enabled"] == True:
|
||||
|
|
Loading…
Reference in New Issue