Skip to content

Generated files for custom messages have duplicate entries #26

Description

@jmachuca77

When trying to import some custom messages I get an error:

my_node.js: Identifier 'my_custom_message' has already been declared

when checking the generated files in my_ws/devel/share/gennodejs/ros I see the files are generated for my node, but they have duplicated entries in _index.js

"use strict";

let my_custom_message1 = require('./my_custom_message1.js');
let my_custom_message2 = require('./my_custom_message2.js');
let my_custom_message1 = require('./my_custom_message1.js');
let my_custom_message2 = require('./my_custom_message2.js');

module.exports = {
  my_custom_message1: my_custom_message1,
  my_custom_message2: my_custom_message2,
  my_custom_message1: my_custom_message1,
  my_custom_message2: my_custom_message2,
};

Any idea what could be causing this? Manually removing the duplicates fixes the issue but I would rather not have to do this every time I do a build.

Originally posted in RethinkRobotics-opensource/rosnodejs#146

Activity

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions