Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions opendbc/car/nissan/carcontroller.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ def __init__(self, dbc_names, CP):
self.packer = CANPacker(dbc_names[Bus.pt])

def update(self, CC, CS, now_nanos):
raise RuntimeError("car_diff error dropdown test") # TODO: remove, intentional failure to exercise car_diff error reporting
actuators = CC.actuators
hud_control = CC.hudControl
pcm_cancel_cmd = CC.cruiseControl.cancel
Expand Down
7 changes: 5 additions & 2 deletions opendbc/car/tests/car_diff.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,8 +293,11 @@ def main(platform: str | None = None, segments_per_platform: int = 10, update_re
icon = "⚠️" if with_diffs else "✅"
print(f"\n{icon} {len(with_diffs)} changed, {n_passed} passed, {len(errors)} errors")

for plat, seg, err in errors:
print(f"\nERROR {plat} - {seg}: {err}")
if errors:
print("<details><summary><b>Show errors</b></summary>\n\n```")
for err in dict.fromkeys(err for _, _, err in errors):
print(f"\n{err}")
print("```\n</details>")

if with_diffs:
print("<details><summary><b>Show changes</b></summary>\n\n```")
Expand Down
Loading