-
Notifications
You must be signed in to change notification settings - Fork 1
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
Capital lettered service names are converted to small letters #66
Comments
Yes indeed, sorry that I didn't catch this immediately after a long day but the reason for this can be found here for cpp and here for python. In both cases we transform the string to lower case. So this is not something from ROS but rather set by us historically. Of course this is not obvious, so there are several options:
What do you think @eeberhard @bpapaspyros |
was there a reason for this choice? we should at least print warnings if we keep it in (changing my service names without letting me know was quite challenging to debug), and maybe write in the docs |
huh, good to know, I hadn't noticed either. I like the RCL idea because this would potentially require less maintenance and let's say it's the ROS way of doing things, but at the same time I don't see a pressing reason to conform to this. Imo at this point perhaps option no 1 combined with adding it in the docs should be more than enough and doesn't break existing use cases, but this is a decision for the very core developers. In fact, regardless of what we do it would be nice to have short mention for this in the docs. |
The other thing to note is that services that does not exist do not make a complain. The service simply gets called, and then the backend moves on. Is this intended? Or should we add a warning message? |
Yeah that is a bit more complicated. As we can see here, the state engine makes a asynchronous request with the rclcpp Service client and we cant wait for the service to return something since that would block the rest of the state engine. Hence, we can't track an unsuccessful service call. Keeping a list of available services would be too much additional effort for the state engine. |
For easier discussion, I will post the relevant lines in RCL here:
As we can see, we can't actually get into most of these cases with our current sanitation of topic names (see my inline comments). There is only one case that we don't cover and it's when the string starts with a number. Hence, my suggestion is:
|
Sorry about double comments but I realized what exactly we are discussing here. Let's go step by step with the example of an input (outputs and services are treated the same):
What's important to note is that the actual topic name that we give to ROS when we create the subscriber is the value of the parameter which can be set by the user through the app, so it could be anything and making the subscriber might still fail even if we validated the signal name in the first place. I personally draw the following conclusions from this:
In conclusion, I still propose the 3 steps from above and will add that if a user fails to set a valid topic name in the app, the creation of the subscribers through ROS will fail and modulo will correctly catch and log the error here |
Thank you for both explanations. I agree with the suggestions which make sense to me as a design. |
Thank you for the clear write up, and sorry I could not give my feedback sooner. I completely agree that we prefer to be more restrictive because we are trying to maintain a consistent and opinionated abstraction in our application framework. We tend to use As a small note, our application schema restricts most namespaces to the regexp Still, we should suggest |
So I discovered a bug/feature (?) where capital letters of service names get made small. For example:
Service as defined in the component: publish_RAPID_var_pose
Service called by API: publish_RAPID_var_pose
Service gets called (202 response) but the service does not run.
Service as defined in the component: publish_RAPID_var_pose
Service called by API: publish_rapid_var_pose
Service gets called (202 response) and the service runs.
Furthermore, I found both capitalised and non-capitalised service names in ros2 service list.
The text was updated successfully, but these errors were encountered: