From feb1f442c24aeae195e16a4ffb4501ed43ce2af2 Mon Sep 17 00:00:00 2001 From: firestar5683 <168790843+firestar5683@users.noreply.github.com> Date: Sat, 31 Oct 2026 20:44:19 -0500 Subject: [PATCH] Repair Ford BluePilot startup fixtures and native test loader identity --- opendbc_repo/opendbc/car/ford/tests/test_aol_startup.py | 9 ++++++--- prebuilt.json | 2 +- tools/ci/run_vehicle_tests.py | 3 +++ 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/opendbc_repo/opendbc/car/ford/tests/test_aol_startup.py b/opendbc_repo/opendbc/car/ford/tests/test_aol_startup.py index bf3d3094f2..6c92ab20c5 100644 --- a/opendbc_repo/opendbc/car/ford/tests/test_aol_startup.py +++ b/opendbc_repo/opendbc/car/ford/tests/test_aol_startup.py @@ -5,7 +5,9 @@ import pytest from opendbc.car import gen_empty_fingerprint, structs from opendbc.car.ford.interface import CarInterface -from opendbc.car.ford.values import CAR +from opendbc.car.ford.values import CAR, FordFlags +from opendbc.bluepilot_lateral.core.values_ext import FordSafetyFlagsSP +from opendbc.bluepilot_lateral.hosts.starpilot.safety_param import BP_SAFETY_PARAM_SHIFT PROFILES = ( @@ -76,6 +78,8 @@ def run_startup(identity, base_word, alpha, release, topology, monkeypatch): initial_word = base_word | int(expected_long) expected_word = initial_word | (256 if topology == "manual" else 0) initial = CarInterface.get_params(identity, fingerprint, [], expected_long, release, False) + if not initial.flags & FordFlags.LKA_STEERING: + expected_word |= FordSafetyFlagsSP.BP_LATERAL << BP_SAFETY_PARAM_SHIFT initial.carVin = "0" * 17 initial.carFw = [] admitted = True @@ -88,8 +92,7 @@ def run_startup(identity, base_word, alpha, release, topology, monkeypatch): with OpenpilotPrefix(): saved = Params() for key, value in (("OpenpilotEnabledToggle", True), ("AlwaysOnLateral", True), - ("AlphaLongitudinalEnabled", alpha), ("IsReleaseBranch", release), - ("FordHumanTurnDetection", False)): + ("AlphaLongitudinalEnabled", alpha), ("IsReleaseBranch", release)): saved.put_bool(key, value, block=True) observed = (identity, fingerprint, initial.carVin, [], initial.fingerprintSource, True) subscriber = messaging.sub_sock("carParams", timeout=100, conflate=True) diff --git a/prebuilt.json b/prebuilt.json index cb446fcda4..be30c29065 100644 --- a/prebuilt.json +++ b/prebuilt.json @@ -1 +1 @@ -{"protected_inventory_sha256": "cd8c615958ada909b930d7ca76d9e24103f34e308a7e716591641759eea12403", "schema_version": 1} +{"protected_inventory_sha256": "ec942078f3cfc87d5683b73d47e4c45adea7152ea1ddfa76c49bd4668cbedcd6", "schema_version": 1} diff --git a/tools/ci/run_vehicle_tests.py b/tools/ci/run_vehicle_tests.py index 5a94f61c48..1a38d3973e 100644 --- a/tools/ci/run_vehicle_tests.py +++ b/tools/ci/run_vehicle_tests.py @@ -690,6 +690,9 @@ def native_provenance(): def build_safety_library(release, output): from opendbc.car.structs import CarParams from opendbc.safety.tests.libsafety import libsafety_py + alias = "opendbc_repo.opendbc.safety.tests.libsafety.libsafety_py" + if sys.modules.setdefault(alias, libsafety_py) is not libsafety_py: + raise RuntimeError("Vehicle tests imported multiple native safety loaders") commands = [] check_call = subprocess.check_call