rclpy
rclpy copied to clipboard
Missing exception states in rclpy
Feature request
rclpy seems to missing ROS Exceptions from rospy
Feature description
rospy has the following exceptions:
- ROSInterruptException/ROSException - used in joint_state_publisher
- ROSInitException - used in joint_state_publisher
- ROSTimeMovedBackwardsException
- ROSInternalException
- TransportException/TransportTerminated/TransportInitError
rclpy seems to missing all the above exceptions. The following are more relevant to the migration
- ROSInterruptException/ROSException - used in joint_state_publisher
- ROSInitException - used in joint_state_publisher
Additionally, it might be useful to have ROSTimeMovedBackwardsException, I am not sure about 4 and 5
https://github.com/ros/ros_comm/blob/60be2504d5341eb3bc80d86e5d16f1c53dc97ccd/clients/rospy/src/rospy/exceptions.py
Implementation considerations
- There is existing exceptions.py which could be extended to encase the missing exception
- Create rosexception.py which entails all these exceptions
Reference: https://discourse.ros.org/t/mapping-between-rospy-and-rclpy/5737?u=wjwwood
Hi @hemantku, are there more exceptions than ROSInterruptExcption that you would like to see ported? Would you mind adding to the issue description the exceptions you would like to see and the use cases that needs them? I think if the ticket was more specific it would be easier to ask for help on and could be completed quicker.
Hi @sloretz, I have made the ticket more specific(sorry about making it generic). I can add these exceptions if you guys agree with what I see I can make change and send you guys the PR