Skip to content
This repository was archived by the owner on Jan 14, 2023. It is now read-only.
This repository was archived by the owner on Jan 14, 2023. It is now read-only.

Message Headers missing dependency information #16

Open

Description

@stonier

It appears that published messages are missing the message definition for the child types which is used for message introspection.

ros/common_msgs#20

Activity

  1. valentinp commented on May 18, 2014

    @valentinp

    Has there been any progress on this bug? This is particularly annoying for collecting rosbags from Android devices.

  2. stonier commented on May 19, 2014

    @stonier
    ContributorAuthor

    Rosjava is mostly following a scratch that itch development cycle at the moment. Those of us who are scratching itches right now are working at companies and can commit time to fixes where we need it or can justify it. We don't have a need for this one at our company (yet), so it's on the todo...unless someone else gets a terrific urge to scratch this itch ;)

    It's probably not too hard to fix - I think you'll need to compare the way gencpp/genpy does things with the code in message_generation.

  3. changed the title [-]ROS messages are malformed[/-] [+]Messages missing dependency information[/+] on Jun 29, 2014
  4. stonier commented on Jun 29, 2014

    @stonier
    ContributorAuthor

    To summarise the discussion in the issue posted on common_msgs, a likely source is that the message_definition field specified in TCPROS Specification is not providing the dependencies definition as well as the msg definition (should exactly match a rosrun roslib gendeps --cat _msg_file_).

  5. changed the title [-]Messages missing dependency information[/-] [+]Message Headers missing dependency information[/+] on Jun 29, 2014
  6. gavanderhoorn commented on Mar 4, 2018

    @gavanderhoorn

    Not a proper fix at all, but at least a work-around: as I had quite some bags that contained messages published by rosjava publishers where I ran into the exception reported in ros/common_msgs#20, I went for the nuclear option and wrote something that replaces the msg defs in connection headers in bag files with completely expanded ones.

    The message definitions obviously need to be available (and identical to what was used by the publisher(s)) on the machine running the script, but that is typically the case.

    See gavanderhoorn/rosbag_fixer.


    Edit: just solved a pretty serious oversight in rosbag_fixer that caused it to not properly close the bag it writes the "fixed" connection headers to. Smaller bags would suffer data loss which sometimes caused rosbag to not be able to read any messages after running the fixer script. This should now be resolved.

  7. ramonss commented on Nov 20, 2018

    @ramonss

    Is there any update on this issue? A permanent fix would be greatly appreciated. Currently, I've been having to use the rosbag_fixer quite often (strangely I do not always have the problem) when recording topics with different types of nodes (rosjava and non-rosjava nodes).

  8. gavanderhoorn commented on Nov 20, 2018

    @gavanderhoorn

    I don't believe there has been any development to fix this. As @stonier writes in his comment above, rosjava itself must be changed for this.

  9. ramonss commented on Nov 21, 2018

    @ramonss

    Thanks for the reply. Is there any planned update for rosjava itself? I think the current bug compromises the compatibility with non-rosjava nodes, since recording ros topics into bag files is a very basic ros feature and extensively used for testing purposes.

  10. gavanderhoorn commented on Nov 21, 2018

    @gavanderhoorn

    I'm just a user, like you :)

    Dependent on the rosjava gods.

  11. jubeira commented on Nov 21, 2018

    @jubeira

    hi @ramonss,

    Rosjava is currently developed mainly by its community; there are no developers working full time or part time on it that I know of. If you need this feature, feel free to submit a PR; I'll review it as soon as I can. If it's something that adds new features and doesn't have too much risk of breaking the existing codebase it will be merged rather fast. I've been pretty packed up lately and I don't have the time to implement this right now.

    Dependent on the rosjava gods.

    That certainly made me laugh 😅

  12. krixkrix commented on Jun 3, 2019

    @krixkrix

    @gavanderhoorn: thanks for the rosbag_fixer script, it works for me on melodic.
    What about adding an option to rosbag record to use local defs? I would like to do it, but not sure if I am capable. Any hints?

  13. gavanderhoorn commented on Jun 3, 2019

    @gavanderhoorn

    What about adding an option to rosbag record to use local defs?

    Well, that would be adding a work-around for an issue local to rosjava to a tool that sees most of its usage outside rosjava contexts.

    Unless there are other use-cases, I doubt the rosbag maintainers are going to accept something like that -- and I think I would agree with them.

  14. ravesteijnd commented on Jul 21, 2020

    @ravesteijnd

    I have created a fix here.

    I had trouble getting the child headers for dependencies outside of the current package during runtime, so I'm spawning a process for rosrun roslib gendeps --cat while generating the headers. This makes the generation of interfaces and belonging defintions very slow and forces a dependency on gendeps so this is not a proper fix in my opinion, but it does the job.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions