From ba9283f9d29a390b86945b5b59dc76c8bf334b61 Mon Sep 17 00:00:00 2001
From: Tomoya Fujita <Tomoya.Fujita@sony.com>
Date: Sat, 16 Dec 2023 09:15:03 -0800
Subject: [PATCH] Revert "Revert "fix loading parameter behavior from yaml
 file. (#656)" (#660)"

This reverts commit 69aa0e4d8662b7bd06138462cc328415b3198263.

Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com>
---
 demo_nodes_py/demo_nodes_py/parameters/async_param_client.py | 3 ++-
 demo_nodes_py/demo_nodes_py/parameters/params.yaml           | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/demo_nodes_py/demo_nodes_py/parameters/async_param_client.py b/demo_nodes_py/demo_nodes_py/parameters/async_param_client.py
index 1893d29e1..1c1e9046c 100644
--- a/demo_nodes_py/demo_nodes_py/parameters/async_param_client.py
+++ b/demo_nodes_py/demo_nodes_py/parameters/async_param_client.py
@@ -73,7 +73,8 @@ def main(args=None):
     rclpy.spin_until_future_complete(node, future)
     load_parameter_results = future.result()
     if load_parameter_results is not None:
-        param_file_dict = parameter_dict_from_yaml_file(param_file_path)
+        param_file_dict = parameter_dict_from_yaml_file(
+            param_file_path, False, target_nodes=['parameter_blackboard'])
         for i, v in enumerate(param_file_dict.keys()):
             node.get_logger().info(f'    {v}:')
             node.get_logger().info(f'        successful: '
diff --git a/demo_nodes_py/demo_nodes_py/parameters/params.yaml b/demo_nodes_py/demo_nodes_py/parameters/params.yaml
index 768ddfd8e..962581ebb 100644
--- a/demo_nodes_py/demo_nodes_py/parameters/params.yaml
+++ b/demo_nodes_py/demo_nodes_py/parameters/params.yaml
@@ -1,4 +1,4 @@
-/param_test_target:
+/parameter_blackboard:
   ros__parameters:
     other_int_parameter: 0
     int_parameter: 12