diff --git a/README.md b/README.md index b0b6063..29b11b1 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ These bindings are being written organically when things are needed by me and ot How to use -------------------- 1. Make sure you have libclang installed. (e.g. libclang-dev on ubuntu) -2. Depend on this package in Cargo.toml: `r2r = "0.8.3"` +2. Depend on this package in Cargo.toml: `r2r = "0.8.4"` 3. You need to source your ROS2 installation before building/running. 4. The bindings will rebuild automatically if/when you source your workspace(s). 5. If you make changes to existing message types, run `cargo clean -p r2r_msg_gen` to force recompilation of the rust message types on the next build. @@ -45,6 +45,9 @@ What works? Changelog -------------------- #### [Unreleased] + +#### [0.8.4] - 2024-03-19 +- Fix QoS for rolling - Update for ros2 iron #### [0.8.3] - 2024-01-14 diff --git a/r2r/Cargo.toml b/r2r/Cargo.toml index cf7d4a7..4fe1b8f 100644 --- a/r2r/Cargo.toml +++ b/r2r/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "r2r" -version = "0.8.3" +version = "0.8.4" authors = ["Martin Dahl "] description = "Easy to use, runtime-agnostic, async rust bindings for ROS2." license = "MIT AND Apache-2.0" @@ -18,11 +18,11 @@ serde = { version = "1.0.147", features = ["derive"] } serde_json = "1.0.89" thiserror = "1.0.37" lazy_static = "1.4.0" -r2r_common = { path = "../r2r_common", version = "0.8.3" } -r2r_rcl = { path = "../r2r_rcl", version = "0.8.3" } -r2r_msg_gen = { path = "../r2r_msg_gen", version = "0.8.3" } -r2r_actions = { path = "../r2r_actions", version = "0.8.3" } -r2r_macros = { path = "../r2r_macros", version = "0.8.3" } +r2r_common = { path = "../r2r_common", version = "0.8.4" } +r2r_rcl = { path = "../r2r_rcl", version = "0.8.4" } +r2r_msg_gen = { path = "../r2r_msg_gen", version = "0.8.4" } +r2r_actions = { path = "../r2r_actions", version = "0.8.4" } +r2r_macros = { path = "../r2r_macros", version = "0.8.4" } uuid = { version = "1.2.2", features = ["serde", "v4"] } futures = "0.3.25" log = "0.4.18" @@ -37,8 +37,8 @@ cdr = "0.2.4" criterion = "0.5.1" [build-dependencies] -r2r_common = { path = "../r2r_common", version = "0.8.3" } -r2r_msg_gen = { path = "../r2r_msg_gen", version = "0.8.3" } +r2r_common = { path = "../r2r_common", version = "0.8.4" } +r2r_msg_gen = { path = "../r2r_msg_gen", version = "0.8.4" } rayon = "1.7.0" force-send-sync = "1.0.0" quote = "1.0.28" diff --git a/r2r/src/subscribers.rs b/r2r/src/subscribers.rs index ba49571..5239345 100644 --- a/r2r/src/subscribers.rs +++ b/r2r/src/subscribers.rs @@ -104,7 +104,6 @@ where let handle_ptr = Box::into_raw(handle_box); let ret = rcl_return_loaned_message_from_subscription(handle_ptr, msg as *mut c_void); - drop(Box::from_raw(handle_ptr)); if ret != RCL_RET_OK as i32 { let err_str = rcutils_get_error_string(); let err_str_ptr = &(err_str.str_) as *const std::os::raw::c_char; @@ -113,13 +112,15 @@ where let topic_str = rcl_subscription_get_topic_name(handle_ptr); let topic = CStr::from_ptr(topic_str); - panic!( + crate::log_error!( + "r2r", "rcl_return_loaned_message_from_subscription() \ failed for subscription on topic {}: {}", topic.to_str().expect("to_str() call failed"), error_msg.to_str().expect("to_str() call failed") ); } + // drop(Box::from_raw(handle_ptr)); }); WrappedNativeMsg::::from_loaned(loaned_msg as *mut T::CStruct, deallocator) } else { diff --git a/r2r_actions/Cargo.toml b/r2r_actions/Cargo.toml index 6413d3e..4fa220f 100644 --- a/r2r_actions/Cargo.toml +++ b/r2r_actions/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "r2r_actions" -version = "0.8.3" +version = "0.8.4" authors = ["Martin Dahl "] description = "Internal dependency to the r2r crate." license = "MIT" @@ -11,12 +11,12 @@ repository = "https://github.com/sequenceplanner/r2r" documentation = "https://docs.rs/r2r/latest/r2r" [dependencies] -r2r_rcl = { path = "../r2r_rcl", version = "0.8.3" } -r2r_msg_gen = { path = "../r2r_msg_gen", version = "0.8.3" } +r2r_rcl = { path = "../r2r_rcl", version = "0.8.4" } +r2r_msg_gen = { path = "../r2r_msg_gen", version = "0.8.4" } [build-dependencies] bindgen = "0.63.0" -r2r_common = { path = "../r2r_common", version = "0.8.3" } +r2r_common = { path = "../r2r_common", version = "0.8.4" } [features] save-bindgen = ["r2r_rcl/save-bindgen", "r2r_msg_gen/save-bindgen"] diff --git a/r2r_cargo.cmake b/r2r_cargo.cmake index 9b22ed7..c0e1afc 100644 --- a/r2r_cargo.cmake +++ b/r2r_cargo.cmake @@ -1,5 +1,5 @@ # -# For r2r 0.8.3. +# For r2r 0.8.4. # # cmake code for simple colcon integration. # See https://github.com/m-dahl/r2r_minimal_node/ diff --git a/r2r_common/Cargo.toml b/r2r_common/Cargo.toml index f93e328..825b933 100644 --- a/r2r_common/Cargo.toml +++ b/r2r_common/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "r2r_common" -version = "0.8.3" +version = "0.8.4" authors = ["Martin Dahl "] description = "Minimal ros2 bindings." license = "MIT" diff --git a/r2r_macros/Cargo.toml b/r2r_macros/Cargo.toml index 9669705..f803a6c 100644 --- a/r2r_macros/Cargo.toml +++ b/r2r_macros/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "r2r_macros" -version = "0.8.3" +version = "0.8.4" authors = ["Martin Dahl "] description = "Minimal ros2 bindings." license = "MIT" diff --git a/r2r_msg_gen/Cargo.toml b/r2r_msg_gen/Cargo.toml index b85bec2..4ceb417 100644 --- a/r2r_msg_gen/Cargo.toml +++ b/r2r_msg_gen/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "r2r_msg_gen" -version = "0.8.3" +version = "0.8.4" authors = ["Martin Dahl "] description = "Internal dependency to the r2r crate." license = "MIT" @@ -11,8 +11,8 @@ repository = "https://github.com/sequenceplanner/r2r" documentation = "https://docs.rs/r2r/latest/r2r" [dependencies] -r2r_rcl = { path = "../r2r_rcl", version = "0.8.3" } -r2r_common = { path = "../r2r_common", version = "0.8.3" } +r2r_rcl = { path = "../r2r_rcl", version = "0.8.4" } +r2r_common = { path = "../r2r_common", version = "0.8.4" } phf = { version = "0.11.1", features = ["macros"] } quote = "1.0.28" proc-macro2 = "1.0.60" @@ -22,8 +22,8 @@ rayon = "1.7.0" [build-dependencies] bindgen = "0.63.0" -r2r_rcl = { path = "../r2r_rcl", version = "0.8.3" } -r2r_common = { path = "../r2r_common", version = "0.8.3" } +r2r_rcl = { path = "../r2r_rcl", version = "0.8.4" } +r2r_common = { path = "../r2r_common", version = "0.8.4" } quote = "1.0.28" syn = { version = "2.0.18", features = ["full"] } rayon = "1.7.0" diff --git a/r2r_rcl/Cargo.toml b/r2r_rcl/Cargo.toml index c3d7e9b..52a453e 100644 --- a/r2r_rcl/Cargo.toml +++ b/r2r_rcl/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "r2r_rcl" -version = "0.8.3" +version = "0.8.4" authors = ["Martin Dahl "] description = "Internal dependency to the r2r crate." license = "MIT" @@ -16,7 +16,7 @@ widestring = "1.0.2" [build-dependencies] bindgen = "0.63.0" -r2r_common = { path = "../r2r_common", version = "0.8.3" } +r2r_common = { path = "../r2r_common", version = "0.8.4" } [features] save-bindgen = []