Skip to content
This repository was archived by the owner on May 31, 2025. It is now read-only.
This repository was archived by the owner on May 31, 2025. It is now read-only.

rosmsg: Error when showing message from a bag file #1002

@kvalev

Description

@kvalev

I am trying to show a custom message from a bag file by calling rosmsg show -b my.bag msg_here, which fails with the following error message:

Traceback (most recent call last):
  File "xxxx/ros_catkin_ws/install_isolated/bin/rosmsg", line 35, in <module>
    rosmsg.rosmsgmain()
  File "xxxx/ros_catkin_ws/install_isolated/lib/python2.7/site-packages/rosmsg/__init__.py", line 747, in rosmsgmain
    sys.exit(rosmsg_cmd_show(ext, full, command))
  File "xxxx/ros_catkin_ws/install_isolated/lib/python2.7/site-packages/rosmsg/__init__.py", line 607, in rosmsg_cmd_show
    print(get_msg_text(datatype, options.raw, pytype._full_text))
  File "xxxx/ros_catkin_ws/install_isolated/lib/python2.7/site-packages/rosmsg/__init__.py", line 425, in get_msg_text
    for p in rospack.list():
AttributeError: 'str' object has no attribute 'list'

Looking at the source code, it seems that the message's full text (as a string) is being passed to a method that expects a rospack object.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions