-
Notifications
You must be signed in to change notification settings - Fork 79
Add missing methods for node #1140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -385,40 +385,67 @@ Napi::Value GetNodeNames(const Napi::CallbackInfo& info) { | |||||||||||||||
|
|
||||||||||||||||
|
||||||||||||||||
| if (info.Length() < 2 || !info[1].IsBoolean()) { | |
| Napi::TypeError::New(env, "Expected at least two arguments, with the second being a Boolean.") | |
| .ThrowAsJavaScriptException(); | |
| return env.Null(); | |
| } |
Copilot
AI
May 20, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] The error message used here is generic ("Failed to get_node_names."). Consider updating it to something like "Failed to get node names with enclaves." to clarify which branch failed.
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -67,6 +67,9 @@ expectType<rclnodejs.NamesAndTypesQueryResult[]>( | |||||||||
| expectType<rclnodejs.NamesAndTypesQueryResult[]>(node.getTopicNamesAndTypes()); | ||||||||||
| expectType<string[]>(node.getNodeNames()); | ||||||||||
| expectType<rclnodejs.NodeNamesQueryResult[]>(node.getNodeNamesAndNamespaces()); | ||||||||||
| expectType<rclnodejs.NodeNamesQueryResultWithEnclaves[]>( | ||||||||||
| node.getNodeNamesAndNamespacesEnclaves() | ||||||||||
|
||||||||||
| node.getNodeNamesAndNamespacesEnclaves() | |
| node.getNodeNamesAndNamespacesWithEnclaves() |
Outdated
Copilot
AI
May 20, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The test calls getNodeNamesAndNamespacesEnclaves(), but the actual method is named getNodeNamesAndNamespacesWithEnclaves(). Update the test to use the correct method name.
| node.getNodeNamesAndNamespacesEnclaves() | |
| node.getNodeNamesAndNamespacesWithEnclaves() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] The JSDoc comment for
getFullyQualifiedNamecan be simplified for clarity. For example: