`roslibpy topic list` crashes if no topics are available
SubaruArai opened this issue · comments
Description
roslibpy topic list
crashes if no topics are available.
Fixed in pr #869.
- Library Version: 0.11.16-2focal.20230620.193802
- ROS Version: noetic
- Platform / OS: Ubuntu 20.04LTS
Steps To Reproduce
- Run any of the
rosbridge_server
launch files with atopics_glob
that contains no topics. E.g.[/dummy/*]
- In another terminal, run
roslibpy topic list
Expected Behavior
An empty list returns
Actual Behavior
The server (rosapi) logs the following error:
Error processing request: not enough values to unpack (expected 2, got 0)
['Traceback (most recent call last):\n', ' File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_service.py", line 633, in _handle_request\n response = convert_return_to_response(self.handler(request), self.response_class)\n', ' File "/opt/ros/noetic/lib/rosapi/rosapi_node", line 72, in get_topics\n topics, types = proxy.get_topics_and_types(rosapi.glob_helper.topics_glob)\n', 'ValueError: not enough values to unpack (expected 2, got 0)\n']
Fixed in #869