{"action":"created","issue":{"url":"https://api.github.com/repos/RobotWebTools/roslibjs/issues/287","repository_url":"https://api.github.com/repos/RobotWebTools/roslibjs","labels_url":"https://api.github.com/repos/RobotWebTools/roslibjs/issues/287/labels{/name}","comments_url":"https://api.github.com/repos/RobotWebTools/roslibjs/issues/287/comments","events_url":"https://api.github.com/repos/RobotWebTools/roslibjs/issues/287/events","html_url":"https://github.com/RobotWebTools/roslibjs/issues/287","id":314478379,"number":287,"title":"No returned status for the roslibjs APIs that interact with bridge","user":{"login":"qiuzhong","id":11829497,"avatar_url":"https://avatars1.githubusercontent.com/u/11829497?v=4","gravatar_id":"","url":"https://api.github.com/users/qiuzhong","html_url":"https://github.com/qiuzhong","followers_url":"https://api.github.com/users/qiuzhong/followers","following_url":"https://api.github.com/users/qiuzhong/following{/other_user}","gists_url":"https://api.github.com/users/qiuzhong/gists{/gist_id}","starred_url":"https://api.github.com/users/qiuzhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/qiuzhong/subscriptions","organizations_url":"https://api.github.com/users/qiuzhong/orgs","repos_url":"https://api.github.com/users/qiuzhong/repos","events_url":"https://api.github.com/users/qiuzhong/events{/privacy}","received_events_url":"https://api.github.com/users/qiuzhong/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-04-16T02:13:19Z","updated_at":"2018-04-16T08:35:30Z","closed_at":null,"author_association":"NONE","body":"When `roslibjs` interacts with a ros bridge, it sends JSON format requests based on the [protocol](https://github.com/RobotWebTools/rosbridge_suite/blob/develop/ROSBRIDGE_PROTOCOL.md). For example, there is an API: `Ros.setStatusLevel()`. \r\n\r\n> Ros.setStatusLevel(level, id)\r\n\r\nWhen we call `Ros.setStatusLevel('error', '/example_id')`, it might send a request like `{set_level: 'error', id: '/example_id}')` and the web socket will receive a response. But this API doesn't handle the response. Users will never know whether this calling succeed or fail.\r\n\r\nIs it possible to return a status for the APIs that communicates with bridge?"},"comment":{"url":"https://api.github.com/repos/RobotWebTools/roslibjs/issues/comments/381522570","html_url":"https://github.com/RobotWebTools/roslibjs/issues/287#issuecomment-381522570","issue_url":"https://api.github.com/repos/RobotWebTools/roslibjs/issues/287","id":381522570,"user":{"login":"T045T","id":871405,"avatar_url":"https://avatars3.githubusercontent.com/u/871405?v=4","gravatar_id":"","url":"https://api.github.com/users/T045T","html_url":"https://github.com/T045T","followers_url":"https://api.github.com/users/T045T/followers","following_url":"https://api.github.com/users/T045T/following{/other_user}","gists_url":"https://api.github.com/users/T045T/gists{/gist_id}","starred_url":"https://api.github.com/users/T045T/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/T045T/subscriptions","organizations_url":"https://api.github.com/users/T045T/orgs","repos_url":"https://api.github.com/users/T045T/repos","events_url":"https://api.github.com/users/T045T/events{/privacy}","received_events_url":"https://api.github.com/users/T045T/received_events","type":"User","site_admin":false},"created_at":"2018-04-16T08:35:30Z","updated_at":"2018-04-16T08:35:30Z","author_association":"CONTRIBUTOR","body":"this is a good idea - I'm assuming you're asking because `rclnodejs` actually implements `status` messages (`rosbridge_suite` does not, as far as I can tell)?\r\n\r\nit shouldn't be too hard to implement this, with one caveat: \r\n\r\n`roslibjs` would have to check every `status` message against the list of `id`s for all the actions that might receive a status response, but haven't yet. \r\n\r\n(that means the response would have to be delivered to the caller via a callback, but that's neither here nor there)\r\n\r\nbut since the status level ist adjustable (even to `none` in the most extreme case), those responses might never come, so that list of IDs to check for would almost certainly just keep growing forever.\r\n\r\nI can't think of a good solution to this; You don't want to send an \"ack\" message after every publish call, for example, because that would take up valuable bandwidth. That sort of \"ack\" would be an `info` message, so one could set the `status_level` to `error`, but then if no errors happen, we'd leak memory :(\r\n\r\nThis is just me thinking about it for 15 minutes though, maybe someone else can think of a more elegant solution."}}
{"actor":{"display_login":"T045T"}}