Skip to content

Commit 0f6a1db

Browse files
Removed trailing whitespace from the codebase.
Signed-off-by: Leander Stephen D'Souza <[email protected]>
1 parent fb8e1dd commit 0f6a1db

6 files changed

+6
-10
lines changed

rclcpp/doc/api_review_march_2020.md

-1
Original file line numberDiff line numberDiff line change
@@ -434,4 +434,3 @@
434434

435435
- (tfoote) There should be no jumps in steady time. If there's a big change in system time, it doesn't necessarily mean that time jumped, just that you might have been sleeping for a long time. Most ntp systems adjust the slew rate these days instead of jumping but still that's an external process and I don't know of any APIs to introspect the state of the clock. I'm not sure that we have a way to detect jumps in time for system or steady time. To that end I think that we should be clear that we only provide callbacks when simulation time starts or stops, or simulation time jumps. We should also strongly recommend that operators not actively adjust their system clocks while running ROS nodes.
436436
- (jacobperron) I agree with Tully, if we don't have a way to detect system time jumps then I think we should just document that this only works with ROS time. In addition to documentation, we could log an info or warning message if the user registers jump callback with steady or system time, but it may be unnecessarily noisy.
437-

rclcpp/doc/proposed_node_parameter_callbacks.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22

33
## Introduction:
44

5-
The original requirement came in **gazebo_ros_pkgs** for setting individual wheel slip parameters based on global wheel slip value [link to original issue](https://github.com/ros-simulation/gazebo_ros_pkgs/pull/1365).
5+
The original requirement came in **gazebo_ros_pkgs** for setting individual wheel slip parameters based on global wheel slip value [link to original issue](https://github.com/ros-simulation/gazebo_ros_pkgs/pull/1365).
66

7-
The main requirement is to set one or more parameters after another parameter is set successfully.
7+
The main requirement is to set one or more parameters after another parameter is set successfully.
88

99
Additionally, it would be nice if users could be notified locally (via a callback) when parameters have been set successfully (i.e. post validation).
1010

1111
Related discussion can be found in [#609](https://github.com/ros2/rclcpp/issues/609) [#1789](https://github.com/ros2/rclcpp/pull/1789)
1212

13-
With the current parameters API, the `add_on_set_parameters_callback` is intended for validation of parameter values before they are set, it should **not** cause any side-effects.
13+
With the current parameters API, the `add_on_set_parameters_callback` is intended for validation of parameter values before they are set, it should **not** cause any side-effects.
1414

1515
There is also the `ParameterEventHandler` that publishes changes to node parameters on `/parameter_events` topic for external nodes to see. Though the node could subscribe to the `/parameter_events` topic to be notified of changes to its own parameters, it is less than ideal since there is a delay caused by waiting for an executor to process the callback.
1616

@@ -19,11 +19,11 @@ We propose adding a `PostSetParametersCallbackHandle` for successful parameter s
1919
The validation callback is often abused to trigger side effects in the code, for instance updating class attributes even before a parameter has been set successfully. Instead of relying on the `/parameter_events` topic to be notified of parameter changes, users can register a callback with a new API, `add_post_set_parameters_callback`.
2020

2121
It is possible to use the proposed `add_post_set_parameters_callback` for setting additional parameters, but this might result in infinite recursion and does not allow those additional parameters to be set atomically with the original parameter(s) changed.
22-
To workaround these issues, we propose adding a "pre set" callback type that can be registered with `add_pre_set_parameters_callback`, which will be triggered before the validation callbacks and can be used to modify the parameter list.
22+
To workaround these issues, we propose adding a "pre set" callback type that can be registered with `add_pre_set_parameters_callback`, which will be triggered before the validation callbacks and can be used to modify the parameter list.
2323

2424
![Desgin API](https://github.com/ros2/rclcpp/blob/deepanshu/local-param-changed-callback-support/rclcpp/doc/param_callback_design.png?raw=true)
2525

2626
## Alternatives
2727

2828
* Users could call `set_parameter` while processing a message from the `/parameter_events` topic, however, there is extra overhead in having to create subscription (as noted earlier).
29-
* Users could call `set_parameter` inside the "on set" parameters callback, however it is not well-defined how side-effects should handle cases where parameter validation fails.
29+
* Users could call `set_parameter` inside the "on set" parameters callback, however it is not well-defined how side-effects should handle cases where parameter validation fails.

rclcpp/test/msg/String.msg

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
string data
1+
string data

rclcpp_components/cmake/rclcpp_components_package_hook.cmake

-1
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,3 @@ foreach(resource_index ${_RCLCPP_COMPONENTS_PACKAGE_RESOURCE_INDICES})
1818
ament_index_register_resource(
1919
${resource_index} CONTENT "${_RCLCPP_COMPONENTS_${resource_index}__NODES}")
2020
endforeach()
21-

rclcpp_components/cmake/rclcpp_components_register_nodes.cmake

-1
Original file line numberDiff line numberDiff line change
@@ -69,4 +69,3 @@ macro(rclcpp_components_register_nodes target)
6969
endforeach()
7070
endif()
7171
endmacro()
72-

rclcpp_components/package.xml

-1
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,3 @@
3838
<build_type>ament_cmake</build_type>
3939
</export>
4040
</package>
41-

0 commit comments

Comments
 (0)