Skip to content

Commit

Permalink
feat: apply autoware_ prefix for duplicated_node_checker (#9970)
Browse files Browse the repository at this point in the history
* feat(duplicated_node_checker): apply `autoware_` prefix (see below):

  Note:
    * In this commit, I did not organize a folder structure.
      The folder structure will be organized in the next some commits.
    * The changes will follow the Autoware's guideline as below:
        - https://autowarefoundation.github.io/autoware-documentation/main/contributing/coding-guidelines/ros-nodes/directory-structure/#package-folder

Signed-off-by: Junya Sasaki <[email protected]>

* rename(duplicated_node_checker): move a header under `include/autoware`:

  * Fixes due to this changes for .hpp/.cpp files will be applied in the next commit

Signed-off-by: Junya Sasaki <[email protected]>

* fix(duplicated_node_checker): fix include header path

  * To follow the previous commit

Signed-off-by: Junya Sasaki <[email protected]>

* rename: `duplicated_node_checker` => `autoware_duplicated_node_checker`

Signed-off-by: Junya Sasaki <[email protected]>

* style(pre-commit): autofix

* bug(autoware_duplicated_node_checker): revert wrongly updated copyrights

Signed-off-by: Junya Sasaki <[email protected]>

* update(autoware_duplicated_node_checker): `README.md`

Signed-off-by: Junya Sasaki <[email protected]>

* update: `CODEOWNERS`

Signed-off-by: Junya Sasaki <[email protected]>

---------

Signed-off-by: Junya Sasaki <[email protected]>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
sasakisasaki and pre-commit-ci[bot] authored Jan 22, 2025
1 parent 8418ae9 commit 56f29fe
Show file tree
Hide file tree
Showing 11 changed files with 24 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ system/diagnostic_graph_aggregator/** [email protected]
system/diagnostic_graph_utils/** [email protected]
system/autoware_dummy_diag_publisher/** [email protected] [email protected]
system/dummy_infrastructure/** [email protected]
system/duplicated_node_checker/** [email protected] [email protected] [email protected]
system/autoware_duplicated_node_checker/** [email protected] [email protected] uken.ryu@tier4.jp junya.sasaki@tier4.jp
system/hazard_status_converter/** [email protected]
system/mrm_comfortable_stop_operator/** [email protected] [email protected]
system/mrm_emergency_stop_operator/** [email protected] [email protected]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
cmake_minimum_required(VERSION 3.14)
project(duplicated_node_checker)
project(autoware_duplicated_node_checker)

find_package(autoware_cmake REQUIRED)
autoware_package()
Expand All @@ -10,8 +10,8 @@ ament_auto_add_library(${PROJECT_NAME} SHARED
)

rclcpp_components_register_node(${PROJECT_NAME}
PLUGIN "duplicated_node_checker::DuplicatedNodeChecker"
EXECUTABLE duplicated_node_checker_node
PLUGIN "autoware::duplicated_node_checker::DuplicatedNodeChecker"
EXECUTABLE ${PROJECT_NAME}_node
)

ament_auto_package(INSTALL_TO_SHARE
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ The result is published as diagnostics.
### Standalone Startup

```bash
ros2 launch duplicated_node_checker duplicated_node_checker.launch.xml
ros2 launch autoware_duplicated_node_checker duplicated_node_checker.launch.xml
```

## Inner-workings / Algorithms
Expand All @@ -30,7 +30,7 @@ The types of topic status and corresponding diagnostic status are following.

## Parameters

{{ json_to_markdown("system/duplicated_node_checker/schema/duplicated_node_checker.schema.json") }}
{{ json_to_markdown("system/autoware_duplicated_node_checker/schema/duplicated_node_checker.schema.json") }}

## Assumptions / Known limits

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#ifndef DUPLICATED_NODE_CHECKER__DUPLICATED_NODE_CHECKER_CORE_HPP_
#define DUPLICATED_NODE_CHECKER__DUPLICATED_NODE_CHECKER_CORE_HPP_
#ifndef AUTOWARE__DUPLICATED_NODE_CHECKER__DUPLICATED_NODE_CHECKER_CORE_HPP_
#define AUTOWARE__DUPLICATED_NODE_CHECKER__DUPLICATED_NODE_CHECKER_CORE_HPP_

#include <diagnostic_updater/diagnostic_updater.hpp>
#include <rclcpp/rclcpp.hpp>
Expand All @@ -22,7 +22,7 @@
#include <unordered_set>
#include <vector>

namespace duplicated_node_checker
namespace autoware::duplicated_node_checker
{
class DuplicatedNodeChecker : public rclcpp::Node
{
Expand Down Expand Up @@ -54,6 +54,6 @@ class DuplicatedNodeChecker : public rclcpp::Node
bool add_duplicated_node_names_to_msg_;
std::unordered_set<std::string> nodes_to_ignore_;
};
} // namespace duplicated_node_checker
} // namespace autoware::duplicated_node_checker

#endif // DUPLICATED_NODE_CHECKER__DUPLICATED_NODE_CHECKER_CORE_HPP_
#endif // AUTOWARE__DUPLICATED_NODE_CHECKER__DUPLICATED_NODE_CHECKER_CORE_HPP_
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<launch>
<arg name="config_file" default="$(find-pkg-share autoware_duplicated_node_checker)/config/duplicated_node_checker.param.yaml"/>

<node pkg="autoware_duplicated_node_checker" exec="autoware_duplicated_node_checker_node" name="duplicated_node_checker" output="screen">
<param from="$(var config_file)"/>
</node>
</launch>
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
<?xml version="1.0"?>
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>duplicated_node_checker</name>
<name>autoware_duplicated_node_checker</name>
<version>0.40.0</version>
<description>A package to find out nodes with common names</description>
<maintainer email="[email protected]">Shumpei Wakabayashi</maintainer>
<maintainer email="[email protected]">yliuhb</maintainer>
<maintainer email="[email protected]">Mamoru Sobue</maintainer>
<maintainer email="[email protected]">Junya Sasaki</maintainer>
<license>Apache 2.0</license>

<buildtool_depend>ament_cmake</buildtool_depend>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#include "duplicated_node_checker/duplicated_node_checker_core.hpp"
#include "autoware/duplicated_node_checker/duplicated_node_checker_core.hpp"

#include <diagnostic_updater/diagnostic_updater.hpp>
#include <rclcpp/rclcpp.hpp>
Expand All @@ -22,7 +22,7 @@
#include <string>
#include <vector>

namespace duplicated_node_checker
namespace autoware::duplicated_node_checker
{

DuplicatedNodeChecker::DuplicatedNodeChecker(const rclcpp::NodeOptions & node_options)
Expand Down Expand Up @@ -77,7 +77,7 @@ void DuplicatedNodeChecker::produceDiagnostics(diagnostic_updater::DiagnosticSta
stat.summary(level, msg);
}

} // namespace duplicated_node_checker
} // namespace autoware::duplicated_node_checker

#include <rclcpp_components/register_node_macro.hpp>
RCLCPP_COMPONENTS_REGISTER_NODE(duplicated_node_checker::DuplicatedNodeChecker)
RCLCPP_COMPONENTS_REGISTER_NODE(autoware::duplicated_node_checker::DuplicatedNodeChecker)

This file was deleted.

0 comments on commit 56f29fe

Please sign in to comment.