Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix error on yakut/cmd/monitor/_model.py (#108)
While passing a Node List (7519.List.1.0.dsdl) from a hardware node to Ubuntu, yakut monitor produces the following error: pycyphal.util._broadcast: Unhandled exception in <bound method Avatar._on_trace of Avatar(node_id=219)>: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all() File "/home/$USER/.local/lib/python3.12/site-packages/yakut/cmd/monitor/_model.py", line 195, in expand_subjects if m.mask: ^^^^^^ ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all() The node list is produced using .h files produced by nnvg and the "mask_bitpacked_" field is used instead of "sparse_list" The error is solved by first checking that the mask is not None and then checking if it is empty with .any(). --------- Authored-by" Vasileios Vasilopoulos<[email protected]> Co-authored-by: Pavel Kirienko <[email protected]>
- Loading branch information