Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rqt Topic Monitor crashes when toggling topic inspection #436

Closed
christianrauch opened this issue Feb 26, 2017 · 1 comment
Closed

rqt Topic Monitor crashes when toggling topic inspection #436

christianrauch opened this issue Feb 26, 2017 · 1 comment

Comments

@christianrauch
Copy link

christianrauch commented Feb 26, 2017

When toggling the box for a topic in the "Topic Monitor", rqt crashes with the following message:

[ERROR] [1488142988.337040]: bad callback: <bound method TopicInfo.message_callback of <rqt_topic.topic_info.TopicInfo object at 0x7f4315d40d50>>
Traceback (most recent call last):
  File "/opt/ros/kinetic/lib/python2.7/dist-packages/rospy/topics.py", line 720, in _invoke_callback
    cb(msg)
  File "/opt/ros/kinetic/lib/python2.7/dist-packages/rqt_topic/topic_info.py", line 100, in message_callback
    self.sizes.append(buff.len)
AttributeError: 'cStringIO.StringO' object has no attribute 'len'

Traceback (most recent call last):
  File "/opt/ros/kinetic/lib/python2.7/dist-packages/rqt_topic/topic_widget.py", line 193, in refresh_topics
    self._update_topics_data()
  File "/opt/ros/kinetic/lib/python2.7/dist-packages/rqt_topic/topic_widget.py", line 204, in _update_topics_data
    bytes_per_s, _, _, _ = topic_info.get_bw()
  File "/opt/ros/kinetic/lib/python2.7/dist-packages/rqt_topic/topic_info.py", line 120, in get_bw
    max_size = max(self.sizes)
ValueError: max() arg is an empty sequence

However, I can use the Topic Monitor for e.g. dragging a topic to the "Pose View" widget.

This issue has been introduced by merging PR #421, e.g. by commit 76f158c (use Python 3 compatible syntax). My default python version is 2.7.12.

@dirk-thomas
Copy link
Contributor

Please see #434 which already fixed the problem. The patch will be available with the next patch release. Until then you can either apply the change to the installed sources manually or build the package from source using the latest sources.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants