{"action":"opened","issue":{"url":"https://api.github.com/repos/RethinkRobotics-opensource/rosnodejs/issues/104","repository_url":"https://api.github.com/repos/RethinkRobotics-opensource/rosnodejs","labels_url":"https://api.github.com/repos/RethinkRobotics-opensource/rosnodejs/issues/104/labels{/name}","comments_url":"https://api.github.com/repos/RethinkRobotics-opensource/rosnodejs/issues/104/comments","events_url":"https://api.github.com/repos/RethinkRobotics-opensource/rosnodejs/issues/104/events","html_url":"https://github.com/RethinkRobotics-opensource/rosnodejs/issues/104","id":333890235,"node_id":"MDU6SXNzdWUzMzM4OTAyMzU=","number":104,"title":"Inaccurate message type names generated by ActionClientInterface","user":{"login":"jstnhuang","id":1175286,"node_id":"MDQ6VXNlcjExNzUyODY=","avatar_url":"https://avatars0.githubusercontent.com/u/1175286?v=4","gravatar_id":"","url":"https://api.github.com/users/jstnhuang","html_url":"https://github.com/jstnhuang","followers_url":"https://api.github.com/users/jstnhuang/followers","following_url":"https://api.github.com/users/jstnhuang/following{/other_user}","gists_url":"https://api.github.com/users/jstnhuang/gists{/gist_id}","starred_url":"https://api.github.com/users/jstnhuang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jstnhuang/subscriptions","organizations_url":"https://api.github.com/users/jstnhuang/orgs","repos_url":"https://api.github.com/users/jstnhuang/repos","events_url":"https://api.github.com/users/jstnhuang/events{/privacy}","received_events_url":"https://api.github.com/users/jstnhuang/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-06-20T01:08:43Z","updated_at":"2018-06-20T01:08:43Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"I think the way the type names for an ActionClient are generated is inaccurate. If you create an action client for a type `foo_msgs/Bar` (filename Bar.action), the correct message types are `foo_msgs/BarActionGoal`, `foo_msgs/BarActionFeedback`, etc.\r\n\r\nThis should be true even if the type name ends with \"Action.\" For example, if the action type is `foo_msgs/BarAction` (filename BarAction.action), the correct message types should be `foo_msgs/BarActionActionGoal`, `foo_msgs/BarActionActionFeedback`, etc.\r\n\r\nThe ActionServerInterface correctly appends \"ActionGoal\", \"ActionFeedback\", etc. to the base name of the action type. However, ActionClientInterface only appends \"Goal\", \"Feedback\", etc. The string \"Action\" is appended beforehand in NodeHandle.js, but only after this check:\r\n```js\r\nif (!type.endsWith('Action')) {\r\n  type += 'Action';\r\n}\r\n```\r\n\r\nIf you have an action whose type name ends with \"Action,\" this leads the ActionClientInterface to generate type names like `foo_msgs/BarActionGoal` instead of `foo_msgs/BarActionActionGoal`. This leads to md5 matching errors with other nodes, since `foo_msgs/BarActionGoal` is also a valid type.\r\n\r\nI think the fix should be simple: remove the three lines quoted above from NodeHandle.js, and change ActionClientInterface to always append \"ActionGoal\", \"ActionFeedback\", etc. to the type name.\r\n\r\nPlease let me know what you think. Is this just an edge case that should be fixed, or is it likely that lots of people depend on this behavior? If we want to fix it, I'd be happy to make the pull request."}}
{"actor":{"display_login":"jstnhuang"}}