ubuntu 20.04 “rosrun tf view_frames” [How to Solve]

ubuntu20.04 ROS noetic

Run in terminal

$ rosrun tf view_frames

report errors

1 Listening to /tf for 5.0 seconds
2 Done Listening
3 b'dot - graphviz version 2.42.3 (0)\n'
4 Traceback (most recent call last):
5   File "/opt/ros/melodic/lib/tf/view_frames", line 119, in <module>
6     generate(dot_graph)
7   File "/opt/ros/melodic/lib/tf/view_frames", line 89, in generate
8     m = r.search(vstr)
9 TypeError: cannot use a string pattern on a bytes-like object

Solution:

Run in terminal

1 sudo vim /opt/ros/noetic/lib/tf/view_frames

Then modify the code in the VIM edit that opens

1 m = r.search(vstr.decode('utf-8'))

Similar Posts: