question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Nav2_msg require error

See original GitHub issue

version: rclnodejs@0.16.0 ros: ros2 foxy

when:

const nav2_msgs = rclnodejs.require('nav2_msgs').msg;

what:

/path/nodejs/node_modules/rclnodejs/lib/interface_loader.js:86
Object.defineProperty(pkg[info.type], info.name, {
              ^
 
TypeError: Object.defineProperty called on non-object
at Function.defineProperty (<anonymous>)
at /path/nodejs/node_modules/rclnodejs/lib/interface_loader.js:86:14
at Array.forEach (<anonymous>)
at Object.loadInterfaceByPath (/parth/nodejs/node_modules/rclnodejs/lib/interface_loader.js:85:20)
at Object.loadInterfaceByString (/path/nodejs/node_modules/rclnodejs/lib/interface_loader.js:65:19)
at Object.loadInterface (/path/nodejs/node_modules/rclnodejs/lib/interface_loader.js:100:21)
at Object.require (path/nodejs/node_modules/rclnodejs/index.js:334:19)
at Object.<anonymous> (/path/nodejs/main.js:20:29)
at Module._compile (internal/modules/cjs/loader.js:1015:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1035:10)

Why:

I have no idea why this occurs. Other messages are imported properly. Nav2_msgs are generated.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
wayneparrottcommented, Nov 20, 2020

@minggangw I can submit a PR with fix and test case if no one else is planning to work this issue. Thoughts?

0reactions
minggangwcommented, Nov 20, 2020

@wayneparrott Please submit a PR to fix this issue, thanks!

When the npm version will be patched?

Hopefully, the next release v0.17.0 can land the patch and we will publish it once the current issues get addressed.

Read more comments on GitHub >

github_iconTop Results From Across the Web

node.js - why there is type error in require in when sending ...
src/routes/adminRoutes')(nav); ^ TypeError: require(...) is not a function. it's showing error in the nav and have no clue why.
Read more >
nav2_bt_navigator - ROS Index
The BT Navigator receives a goal pose and navigates the robot to the specified destination(s). To do so, the module reads an XML...
Read more >
Create a virtual Button Box for X-Plane 11 - SIM Dashboard Help
A Button Box in SIM Dashboard allows you to interact with your Game (e.g. X-Plane). Either directly via X-Plane Commands or by simulating...
Read more >
No Match For Operator ! Operands Types Are Pointer And Object
Line 16: Char 17: error: no match for 'operator!' operand types are. ... are #include stdmsgs/msg/string.hpp #include nav2msgs/action/navigatetopose.hpp.
Read more >
Spanish | PDF | Diseño de vehículos | Vuelo - Scribd
STRING An error occurred during scenery installation:====Hubo un error ... necesario para la instalación: %3:required disk space%\n\n%4:status message%
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found