Skip to content

Commit

Permalink
IsoTpParallelQuery: log empty responses (commaai#29014)
Browse files Browse the repository at this point in the history
* check if None

* log instead

* clean up

* should mark done
  • Loading branch information
sshane authored Jul 18, 2023
1 parent e7c858d commit 29837b8
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion selfdrive/car/isotp_parallel_query.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,13 @@ def get_data(self, timeout, total_timeout=60.):
addrs_responded.add(tx_addr)
response_timeouts[tx_addr] = time.monotonic() + timeout

if not dat:
if dat is None:
continue

# Log unexpected empty responses
if len(dat) == 0:
cloudlog.error(f"iso-tp query empty response: {tx_addr}")
request_done[tx_addr] = True
continue

counter = request_counter[tx_addr]
Expand Down

0 comments on commit 29837b8

Please sign in to comment.