Skip to content
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

Wildcard doesn't assign parameter if the node has namespace #954

Closed
amfern opened this issue Dec 7, 2021 · 4 comments · Fixed by ros2/rclcpp#1839
Closed

Wildcard doesn't assign parameter if the node has namespace #954

amfern opened this issue Dec 7, 2021 · 4 comments · Fixed by ros2/rclcpp#1839

Comments

@amfern
Copy link

amfern commented Dec 7, 2021

Bug report

Assign parameter to any node doesn't work, if the node has namespace.

Required Info:

  • Operating System:
    • ubuntu:20.04
  • Installation type:
    • binaries
  • Version or commit hash:
    • ros-galactic
  • DDS implementation:
    • Fast-RTPS
  • Client library (if applicable):
    • rclcpp

Steps to reproduce issue

install demo_nodes with apt install ros-galactic-demo-nodes-cpp
create config.yaml file with the following content

/*:
  parameter_blackboard:
    ros__parameters:
      miau: "miau_config"

run /opt/ros/galactic/lib/demo_nodes_cpp/parameter_blackboard --ros-args -r __ns:=/aaaa --params-file config.yaml
run ros2 param list

Expected behavior

ros2 param list should list the parameter miau, expected output is

/aaaa/parameter_blackboard:
  miau
  qos_overrides./parameter_events.publisher.depth
  qos_overrides./parameter_events.publisher.durability
  qos_overrides./parameter_events.publisher.history
  qos_overrides./parameter_events.publisher.reliability
  use_sim_time

Actual behavior

miau parameter isn't added to the node, ros2 param list returns

/aaaa/parameter_blackboard:
  qos_overrides./parameter_events.publisher.depth
  qos_overrides./parameter_events.publisher.durability
  qos_overrides./parameter_events.publisher.history
  qos_overrides./parameter_events.publisher.reliability
  use_sim_time
@amfern amfern changed the title Assign parameter to any node doesn't work, if the node has namespace Wildcard namespace doesn't assign parameter if the node has namespace Dec 7, 2021
@amfern amfern changed the title Wildcard namespace doesn't assign parameter if the node has namespace Wildcard doesn't assign parameter if the node has namespace Dec 7, 2021
@Barry-Xu-2018
Copy link
Contributor

ros2/rclcpp#1280

It seems above PR implements this functionality. But it isn't finished.
Besides, it is better to move this issue to rclcpp.

@amfern
Copy link
Author

amfern commented Dec 8, 2021

Why it rclcpp issue, isn't the parameter and yaml parsing happening in rcl?

@Barry-Xu-2018
Copy link
Contributor

Why it rclcpp issue, isn't the parameter and yaml parsing happening in rcl?

YAML parsing is in rcl. But further parsing (e.g. /**) is done in rclcpp.

@iuhilnehc-ynos submit PR to fix this bug. I think you can try it.
ros2/rclcpp#1839

@amfern
Copy link
Author

amfern commented Dec 11, 2021

this works for me, it fixes this issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants