ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
6

rqt_bag: cannot import name qInfo

asked 2017-11-01 07:07:39 -0500

Yousof gravatar image

Hi,

Today rqt_bag doesn't want to work. Giving me this error:

$ rqt_bag
Traceback (most recent call last):
  File "/opt/ros/kinetic/bin/rqt_bag", line 5, in <module>
    from rqt_bag.bag import Bag
  File "/opt/ros/kinetic/lib/python2.7/dist-packages/rqt_bag/bag.py", line 39, in <module>
    from .bag_widget import BagWidget
  File "/opt/ros/kinetic/lib/python2.7/dist-packages/rqt_bag/bag_widget.py", line 40, in <module>
    from python_qt_binding.QtCore import Qt, qInfo, qWarning, Signal
ImportError: cannot import name qInfo

I am running ROS kinetic on Ubuntu 16.04 and Ros just got updated today morning with apt upgrade.

Any idea how can I solve it?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
4

answered 2017-11-08 02:43:03 -0500

VictorLamoine gravatar image

updated 2017-11-09 01:46:13 -0500

Please read the comments for more information about the resolution of this bug


Temporary fix

Edit the file:

sudo nano /opt/ros/kinetic/lib/python2.7/dist-packages/rqt_bag/bag_widget.py

Modify the line producing the error from:

from python_qt_binding.QtCore import Qt, qInfo, qWarning, Signal

To

from python_qt_binding.QtCore import Qt, qWarning, Signal

Then comment every call to qInfo in the code, you can find them with:

grep -rn "qInfo" /opt/ros/kinetic/lib/python2.7/dist-packages/rqt_bag/

Use nano or any other editor to comment the calls inside this python code.

You can then use rqt_bag again!

edit flag offensive delete link more

Comments

Works as a charm. Tks!

Guilherme Schvarcz Franco gravatar image Guilherme Schvarcz Franco  ( 2017-11-08 08:19:19 -0500 )edit

Note that as @VictorLamoine already writes: this is really a temporary fix. As soon as you receive an updated .deb (through apt-get update fi) the changes will be overwritten.

gvdhoorn gravatar image gvdhoorn  ( 2017-11-08 08:21:04 -0500 )edit

Bug where this is tracked: ros-visualization/rqt_bag#15.

And PR that (presumably) fixes it: ros-visualization/rqt_bag#16.

gvdhoorn gravatar image gvdhoorn  ( 2017-11-08 08:22:02 -0500 )edit

And a PR that fixes the previous PR: ros-visualization/rqt_bag#17.

To quote @Dirk Thomas:

rqt_bag version 0.4.11 will fix the problem. I have just released that version so it might be a bit until it is available from Debian packages.

gvdhoorn gravatar image gvdhoorn  ( 2017-11-08 08:23:45 -0500 )edit

For me, the temporary fix allows rqt_bag to start; however, attempting to load a bag file results in the same qInfo error. (Ubuntu 16.04, Kinetic)

Marvin gravatar image Marvin  ( 2017-11-12 09:40:55 -0500 )edit

@Marvin make sure you have done the last steps (grep + edit the file)

VictorLamoine gravatar image VictorLamoine  ( 2017-11-13 02:20:33 -0500 )edit

Another option is to enable the Shadow Repository and install rqt and related pkgs from there. Don't forget to switch back to the default repository after doing that.

gvdhoorn gravatar image gvdhoorn  ( 2017-11-13 02:40:10 -0500 )edit

I tried @VictorLamoine temporary fix and it worked for me, thanks

tonyParker gravatar image tonyParker  ( 2017-12-01 05:58:26 -0500 )edit

Question Tools

3 followers

Stats

Asked: 2017-11-01 07:07:39 -0500

Seen: 1,329 times

Last updated: Nov 09 '17