From 34a8963eb4e161f9f0f6fd32a892c00e1644ed9a Mon Sep 17 00:00:00 2001 From: PhoebeWu21 Date: Mon, 2 Oct 2023 09:20:59 +0800 Subject: [PATCH 1/2] refactor(rtc_auto_mode_manager): rework parameters Signed-off-by: PhoebeWu21 --- .../schema/rtc_auto_mode_manager.schema.json | 42 +++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 planning/rtc_auto_mode_manager/schema/rtc_auto_mode_manager.schema.json diff --git a/planning/rtc_auto_mode_manager/schema/rtc_auto_mode_manager.schema.json b/planning/rtc_auto_mode_manager/schema/rtc_auto_mode_manager.schema.json new file mode 100644 index 0000000000000..e4bd36806de68 --- /dev/null +++ b/planning/rtc_auto_mode_manager/schema/rtc_auto_mode_manager.schema.json @@ -0,0 +1,42 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema#", + "title": "Parameters for RTC Auto Mode Manager", + "type": "object", + "definitions": { + "rtc_auto_mode_manager": { + "type": "object", + "properties": { + "module_list": { + "type": "array", + "description": "Module names managing in rtc_auto_mode_manager", + "default": "['blind_spot', 'crosswalk', 'detection_area', 'intersection', 'no_stopping_area', 'traffic_light', 'lane_change_left', 'lane_change_right', 'avoidance_left', 'avoidance_right', 'goal_planner', 'start_planner', 'intersection_occlusion']" + }, + "default_enable_list": { + "type": "array", + "description": "Module names enabled auto mode at initialization", + "default": "['blind_spot', 'crosswalk', 'detection_area', 'intersection', 'no_stopping_area', 'traffic_light', 'lane_change_left', lane_change_right', 'avoidance_left', 'avoidance_right', 'goal_planner', 'start_planner', 'intersection_occlusion']" + } + }, + "required": [ + "module_list", + "default_enable_list" + ] + } + }, + "properties": { + "/**": { + "type": "object", + "properties": { + "ros__parameters": { + "$ref": "#/definitions/rtc_auto_mode_manager" + } + }, + "required": [ + "ros__parameters" + ] + } + }, + "required": [ + "/**" + ] +} \ No newline at end of file From 613f0b57c01a0750fd1acb627596508419587b6f Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 2 Oct 2023 01:36:51 +0000 Subject: [PATCH 2/2] style(pre-commit): autofix --- .../schema/rtc_auto_mode_manager.schema.json | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/planning/rtc_auto_mode_manager/schema/rtc_auto_mode_manager.schema.json b/planning/rtc_auto_mode_manager/schema/rtc_auto_mode_manager.schema.json index e4bd36806de68..2aaf5ce93bd4e 100644 --- a/planning/rtc_auto_mode_manager/schema/rtc_auto_mode_manager.schema.json +++ b/planning/rtc_auto_mode_manager/schema/rtc_auto_mode_manager.schema.json @@ -17,10 +17,7 @@ "default": "['blind_spot', 'crosswalk', 'detection_area', 'intersection', 'no_stopping_area', 'traffic_light', 'lane_change_left', lane_change_right', 'avoidance_left', 'avoidance_right', 'goal_planner', 'start_planner', 'intersection_occlusion']" } }, - "required": [ - "module_list", - "default_enable_list" - ] + "required": ["module_list", "default_enable_list"] } }, "properties": { @@ -31,12 +28,8 @@ "$ref": "#/definitions/rtc_auto_mode_manager" } }, - "required": [ - "ros__parameters" - ] + "required": ["ros__parameters"] } }, - "required": [ - "/**" - ] -} \ No newline at end of file + "required": ["/**"] +}