From 849bbc8a2f2264825c039767fd870ace8a6beac8 Mon Sep 17 00:00:00 2001 From: Willem Melching Date: Thu, 17 Feb 2022 16:47:42 +0100 Subject: [PATCH] process replay: fix branch name alert (#23783) * env is modified after start * update ref old-commit-hash: 14260c01c6a91554a63377acfce504758af4d096 --- selfdrive/controls/lib/events.py | 4 ++-- selfdrive/test/process_replay/ref_commit | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/selfdrive/controls/lib/events.py b/selfdrive/controls/lib/events.py index 0b6537d1e..931932cc0 100644 --- a/selfdrive/controls/lib/events.py +++ b/selfdrive/controls/lib/events.py @@ -15,7 +15,6 @@ VisualAlert = car.CarControl.HUDControl.VisualAlert AudibleAlert = car.CarControl.HUDControl.AudibleAlert EventName = car.CarEvent.EventName -REPLAY = "REPLAY" in os.environ # Alert priorities class Priority(IntEnum): @@ -218,8 +217,9 @@ def user_soft_disable_alert(alert_text_2: str) -> AlertCallbackType: def startup_master_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: bool, soft_disable_time: int) -> Alert: branch = get_short_branch("") - if REPLAY: + if "REPLAY" in os.environ: branch = "replay" + return StartupAlert("WARNING: This branch is not tested", branch, alert_status=AlertStatus.userPrompt) def below_engage_speed_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: bool, soft_disable_time: int) -> Alert: diff --git a/selfdrive/test/process_replay/ref_commit b/selfdrive/test/process_replay/ref_commit index 57c51c1f1..6c915d8f8 100644 --- a/selfdrive/test/process_replay/ref_commit +++ b/selfdrive/test/process_replay/ref_commit @@ -1 +1 @@ -ff965c772bd1bc85dec717d090cee4466033ce73 \ No newline at end of file +302258d8bdfea779c546f76c191ed451b18062f5 \ No newline at end of file