Use get_package_share_path just as python#112
Conversation
9df7db4 to
9781967
Compare
Signed-off-by: Tim Clephas <tim.clephas@nobleo.nl>
Signed-off-by: Tim Clephas <tim.clephas@nobleo.nl>
Signed-off-by: Tim Clephas <tim.clephas@nobleo.nl>
9781967 to
a3b1568
Compare
|
I like the change. It's way cleaner than the previous version. |
| */ | ||
| AMENT_INDEX_CPP_PUBLIC | ||
| void | ||
| get_package_share_directory(const std::string & package_name, std::filesystem::path & path); |
There was a problem hiding this comment.
we need to update downstream packages
There was a problem hiding this comment.
How? Or to what?
Or do we (shortly) keep this function around for depreciation?
There was a problem hiding this comment.
I think the API in question was added after kilted and therefore we can directly remove/replace it before the next release.
Removing this API will break all the tests etc that were already moved to the new API and need to be fixed.
E.g. if you check out the full rolling stack and remove the old API fix all compile failures resulting from this and do PRs for it.
There was a problem hiding this comment.
And then merge simultaneously?
Then we would need someone with merge access to all these repos I guess?
Edit: or we can let everyone merge at their own pace I guess
There was a problem hiding this comment.
I have permission to merge PRs across all the ROS 2 core.
We should deprecate the method instead of removing it
There was a problem hiding this comment.
I deprecated the previous implementation. So this can be merged and the other repositories will get a deprecation warning.
Signed-off-by: Tim Clephas <tim.clephas@nobleo.nl>
|
Pulls: #112, ros2/rmw_zenoh#913, ros2/rviz#1671, ros/resource_retriever#119, ros/ros_tutorials#193, ros-perception/image_common#391 |
ahcorde
left a comment
There was a problem hiding this comment.
Windows is not compiling
utest.cpp
utest.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) class std::filesystem::path __cdecl ament_index_cpp::get_package_share_path(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (__imp_?get_package_share_path@ament_index_cpp@@YA?AVpath@filesystem@std@@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@@Z) referenced in function "private: virtual void __cdecl AmentIndexCpp_get_package_share_path_Test::TestBody(void)" (?TestBody@AmentIndexCpp_get_package_share_path_Test@@EEAAXXZ) [C:\ci\ws\build\ament_index_cpp\ament_index_cpp_utest.vcxproj]
C:\ci\ws\build\ament_index_cpp\Release\ament_index_cpp_utest.exe : fatal error LNK1120: 1 unresolved externals [C:\ci\ws\build\ament_index_cpp\ament_index_cpp_utest.vcxproj]Co-authored-by: Alejandro Hernández Cordero <ahcorde@gmail.com> Signed-off-by: Tim Clephas <tim.clephas@nobleo.nl>
Signed-off-by: Tim Clephas <tim.clephas@nobleo.nl>
Found a wrong include, I hope windows works now? |
|
Pulls: #112, ros2/rmw_zenoh#913, ros2/rviz#1671, ros/resource_retriever#119, ros/ros_tutorials#193, ros-perception/image_common#391 |
|
Is there a source of truth somewhere for deprecations and deletions and their associated PRs? A docs.ros.org page? A ROS discourse post? When moveit2 rolling starts failing CI jobs around deprecations, it takes me a frustrating amount of time for me to find the particular GH organization and repo associated with that breakage to understand and fix it, whether that is something in rclcpp, ament, tf, etc. I imagine if this existed/was more widely known, more package maintainers would mention the deprecation/deletion PR in their issue, which would make it easier for other package maintainers to do their migration. |
…and ament_index_cpp::get_package_share_directory(*, *) to ament_index_cpp::get_package_share_path(package_name) addressing ament/ament_index#112 Revert QT support changes which will be addressed in a separate PR Temporarily add '-Wno-error=deprecated-declarations' to suppress other upstream deprecatios from short circuiting CI
|
Can this be backported to active distro's? Minus the deprecation message of course. To prevent these kind of constructions for packages that use a single branch for all active distros: https://github.com/moveit/moveit2/pull/3705/changes#diff-c5eab2d24cfc0cc52d9d0fadc0596533f00ca45e3f8ea45a31bcd8c72b34fafaR40 |
cpp and python were going out of sync.
Besides
Looks much better than
Due to the short-livedness of the
get_package_share_directory(..., std::filesystem::path)syntax, I didn't deprecated it.I can finish this PR including the tests etc if that's appreciated. For now I wanted feedback first. 🙂