ros2 / ros2cli

ROS 2 command line interface tools
Apache License 2.0
172 stars 161 forks source link

Autocompletion for message contents still broken in humble? #793

Open Matthias199 opened 1 year ago

Matthias199 commented 1 year ago

Same issue as here! https://github.com/ros2/ros2cli/issues/563

Ubuntu 22.04.1 LTS and ros humble fresh installed ...

fujitatomoya commented 1 year ago

works for me, can you share more details that reproduce this issue?

root@tomoyafujita:~# dpkg -l | grep ros-humble-ros2cli
ii  ros-humble-ros2cli                                0.18.4-1jammy.20221207.031440           amd64        Framework for ROS 2 command line tools.
ii  ros-humble-ros2cli-common-extensions              0.1.1-4jammy.20221207.042253            amd64        Meta package for ros2cli common extensions

root@tomoyafujita:~# ros2 topic pub /cli_demo geometry_msgs/msg/Pose "po<tab>
  x: 0.0
  y: 0.0
  z: 0.0
orientation:
  x: 0.0
  y: 0.0
  z: 0.0
fujitatomoya commented 1 year ago

https://github.com/ros2/ros2cli/pull/570 has been merged and released in humble release.

Matthias199 commented 1 year ago

Ahh i get if I had to add not only the " also the first letter in the message like "p in your example, yeah this way it works ... but feels a bit inconvenience. In ros1 is uses this feature also if I did not no nothing about the message to get information about it. Now i have o sure know how the message start

fujitatomoya commented 1 year ago

Ah, right. agree, even rolling does the following...

root@tomoyafujita:~/ros2_ws/colcon_ws# ros2 topic pub /cli_demo geometry_msgs/msg/Pose <tab..>
-1
--keep-alive
-n
--node-name
--once
-p
position:\^J\ \ x:\ 0.0\^J\ \ y:\ 0.0\^J\ \ z:\ 0.0\^Jorientation:\^J\ \ x:\ 0.0\^J\ \ y:\ 0.0\^J\ \ z:\ 0.0\^J\ \ w:\ 1.0\
--print
--qos-depth
--qos-durability
--qos-history
--qos-liveliness
--qos-liveliness-lease-duration-seconds
--qos-profile
--qos-reliability
-r
--rate
-s
--spin-time
-t
--times
--use-sim-time
-w
--wait-matching-subscriptions

position:\^J\ \ x:\ 0.0\^J\ \ y:\ 0.0\^J\ \ z:\ 0.0\^Jorientation:\^J\ \ x:\ 0.0\^J\ \ y:\ 0.0\^J\ \ z:\ 0.0\^J\ \ w:\ 1.0\ can be listed as suggestion with any other possible options. it is not really beautiful suggested option list, i think. that is what you mean?

tomkimsour commented 5 months ago

I think this at least deserve a small section in ros documentation. And i don't think it has been fixed yet.

fujitatomoya commented 5 months ago

@tomkimsour

I think this at least deserve a small section in ros documentation. And i don't think it has been fixed yet.

can you describe more details what needs to be added? like we should add the quote for the message contents autocompletion?

tomkimsour commented 5 months ago

@tomkimsour

I think this at least deserve a small section in ros documentation. And i don't think it has been fixed yet.

can you describe more details what needs to be added? like we should add the quote for the message contents autocompletion?

Yes I guess something like that would be ok.