From 1427fb6246c46a0b5851a017ddc886abd80d895b Mon Sep 17 00:00:00 2001 From: Pablo Garrido Date: Mon, 29 Jan 2024 11:43:20 +0100 Subject: [PATCH 1/5] Fix thread include Signed-off-by: Pablo Garrido --- .../src/agent/graph_manager/graph_manager.cpp | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp b/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp index 8314955..b459264 100644 --- a/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp +++ b/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp @@ -21,6 +21,7 @@ #include #include #include +#include namespace uros { namespace agent { @@ -374,8 +375,8 @@ void GraphManager::add_datawriter( "rmw_fastrtps_cpp", participant_guid); const rmw_qos_profile_t qos_profile = fastdds_qos_to_rmw_qos(writer_qos); - graphCache_.add_entity(datawriter_gid, topic_name, type_name, - rosidl_get_zero_initialized_type_hash(), participant_gid, qos_profile, false); + graphCache_.add_entity(datawriter_gid, topic_name, + type_name, participant_gid, qos_profile, false); } void GraphManager::remove_datawriter( @@ -411,13 +412,8 @@ void GraphManager::add_datareader( "rmw_fastrtps_cpp", participant_guid); const rmw_qos_profile_t qos_profile = fastdds_qos_to_rmw_qos(reader_qos); - // TODO(acuadros95): Use typesupport to calculate type hash on micro-ROS and save and get it from reader_qos.user_data. - // Related PRs: - // https://github.com/ros2/rmw_dds_common/pull/70 - // https://github.com/ros2/rmw_fastrtps/pull/671 - // https://github.com/ros2/rmw_fastrtps/pull/680 - graphCache_.add_entity(datareader_gid, topic_name, type_name, - rosidl_get_zero_initialized_type_hash(), participant_gid, qos_profile, true); + graphCache_.add_entity(datareader_gid, topic_name, + type_name, participant_gid, qos_profile, true); } void GraphManager::remove_datareader( From 45844fd6cf1123a5e58cf6ac78ad76624a13e52b Mon Sep 17 00:00:00 2001 From: Pablo Garrido Date: Mon, 29 Jan 2024 11:49:07 +0100 Subject: [PATCH 2/5] Update CI --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 429c36a..9f1011c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,7 +23,7 @@ jobs: image: ubuntu:jammy steps: - uses: actions/checkout@v3 - - uses: ros-tooling/setup-ros@0.6.2 + - uses: ros-tooling/setup-ros@0.7.1 with: use-ros2-testing: false required-ros-distributions: ${{ matrix.ros_distribution }} @@ -31,7 +31,7 @@ jobs: run: | apt-get install ros-${{ matrix.ros_distribution }}-micro-ros-msgs apt-get install ros-${{ matrix.ros_distribution }}-rmw-fastrtps-cpp - - uses : ros-tooling/action-ros-ci@0.3.2 + - uses : ros-tooling/action-ros-ci@0.3.6 with: package-name: "micro_ros_agent" target-ros2-distro: ${{ matrix.ros_distribution }} From dd5b1f76c27aaed9858e48a75817f81fd42c0c9c Mon Sep 17 00:00:00 2001 From: Pablo Garrido Date: Mon, 29 Jan 2024 13:06:54 +0100 Subject: [PATCH 3/5] Revert "Fix thread include" This reverts commit 1427fb6246c46a0b5851a017ddc886abd80d895b. --- .../src/agent/graph_manager/graph_manager.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp b/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp index b459264..8314955 100644 --- a/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp +++ b/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp @@ -21,7 +21,6 @@ #include #include #include -#include namespace uros { namespace agent { @@ -375,8 +374,8 @@ void GraphManager::add_datawriter( "rmw_fastrtps_cpp", participant_guid); const rmw_qos_profile_t qos_profile = fastdds_qos_to_rmw_qos(writer_qos); - graphCache_.add_entity(datawriter_gid, topic_name, - type_name, participant_gid, qos_profile, false); + graphCache_.add_entity(datawriter_gid, topic_name, type_name, + rosidl_get_zero_initialized_type_hash(), participant_gid, qos_profile, false); } void GraphManager::remove_datawriter( @@ -412,8 +411,13 @@ void GraphManager::add_datareader( "rmw_fastrtps_cpp", participant_guid); const rmw_qos_profile_t qos_profile = fastdds_qos_to_rmw_qos(reader_qos); - graphCache_.add_entity(datareader_gid, topic_name, - type_name, participant_gid, qos_profile, true); + // TODO(acuadros95): Use typesupport to calculate type hash on micro-ROS and save and get it from reader_qos.user_data. + // Related PRs: + // https://github.com/ros2/rmw_dds_common/pull/70 + // https://github.com/ros2/rmw_fastrtps/pull/671 + // https://github.com/ros2/rmw_fastrtps/pull/680 + graphCache_.add_entity(datareader_gid, topic_name, type_name, + rosidl_get_zero_initialized_type_hash(), participant_gid, qos_profile, true); } void GraphManager::remove_datareader( From 170e2f379a73c9636a360f316aa4404c37a0064d Mon Sep 17 00:00:00 2001 From: Pablo Garrido Date: Mon, 29 Jan 2024 13:07:06 +0100 Subject: [PATCH 4/5] fix --- micro_ros_agent/src/agent/graph_manager/graph_manager.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp b/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp index 8314955..38a392c 100644 --- a/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp +++ b/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp @@ -21,6 +21,7 @@ #include #include #include +#include namespace uros { namespace agent { From 4a288a3de9e75a3ad9f9339da22d7f22e7fd7246 Mon Sep 17 00:00:00 2001 From: Pablo Garrido Date: Mon, 29 Jan 2024 16:02:51 +0100 Subject: [PATCH 5/5] Fix Signed-off-by: Pablo Garrido --- micro_ros_agent/include/agent/graph_manager/graph_manager.hpp | 1 + micro_ros_agent/src/agent/graph_manager/graph_manager.cpp | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/micro_ros_agent/include/agent/graph_manager/graph_manager.hpp b/micro_ros_agent/include/agent/graph_manager/graph_manager.hpp index d6df8d0..d9cf095 100644 --- a/micro_ros_agent/include/agent/graph_manager/graph_manager.hpp +++ b/micro_ros_agent/include/agent/graph_manager/graph_manager.hpp @@ -65,6 +65,7 @@ #include #include #include +#include namespace uros { namespace agent { diff --git a/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp b/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp index 38a392c..8314955 100644 --- a/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp +++ b/micro_ros_agent/src/agent/graph_manager/graph_manager.cpp @@ -21,7 +21,6 @@ #include #include #include -#include namespace uros { namespace agent {