don't block startup on time (#31074)

* don't block startup on time

* cleanup

* unused
pull/31076/head
Adeeb Shihadeh 1 year ago committed by GitHub
parent f3689ef561
commit 16cd20f4eb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 7
      selfdrive/thermald/thermald.py

@ -1,5 +1,4 @@
#!/usr/bin/env python3
import datetime
import os
import json
import queue
@ -15,7 +14,6 @@ import cereal.messaging as messaging
from cereal import log
from cereal.services import SERVICE_LIST
from openpilot.common.dict_helpers import strip_deprecated_keys
from openpilot.common.time import MIN_DATE
from openpilot.common.filter_simple import FirstOrderFilter
from openpilot.common.params import Params
from openpilot.common.realtime import DT_TRML
@ -293,11 +291,6 @@ def thermald_thread(end_event, hw_queue) -> None:
# **** starting logic ****
# Ensure date/time are valid
now = datetime.datetime.utcnow()
startup_conditions["time_valid"] = now > MIN_DATE
set_offroad_alert_if_changed("Offroad_InvalidTime", (not startup_conditions["time_valid"]) and peripheral_panda_present)
startup_conditions["up_to_date"] = params.get("Offroad_ConnectivityNeeded") is None or params.get_bool("DisableUpdates") or params.get_bool("SnoozeUpdate")
startup_conditions["not_uninstalling"] = not params.get_bool("DoUninstall")
startup_conditions["accepted_terms"] = params.get("HasAcceptedTerms") == terms_version

Loading…
Cancel
Save