Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Breaking changes in YARP February 2025 (was Unstable CI failure February 2025) #1788

Closed
traversaro opened this issue Jan 31, 2025 · 7 comments · Fixed by #1789
Closed

Breaking changes in YARP February 2025 (was Unstable CI failure February 2025) #1788

traversaro opened this issue Jan 31, 2025 · 7 comments · Fixed by #1789

Comments

@traversaro
Copy link
Member

2025-01-31T02:49:04.1755901Z [3/56] Building CXX object src/devices/frameTransformGet_nwc_ros/CMakeFiles/yarp_frameTransformGet_nwc_ros.dir/yarp_plugin_frameTransformGet_nwc_ros.cpp.o
2025-01-31T02:49:04.1758199Z FAILED: src/devices/frameTransformGet_nwc_ros/CMakeFiles/yarp_frameTransformGet_nwc_ros.dir/yarp_plugin_frameTransformGet_nwc_ros.cpp.o 
2025-01-31T02:49:04.1769468Z /home/runner/miniconda3/envs/test/bin/x86_64-conda-linux-gnu-c++ -Dyarp_frameTransformGet_nwc_ros_EXPORTS -isystem /home/runner/work/robotology-superbuild/robotology-superbuild/b/install/include -Wall -Wextra -Wsign-compare -Wpointer-arith -Winit-self -Wnon-virtual-dtor -Wcast-align -Wunused -Wunused-but-set-variable -Wvla -Wmissing-include-dirs -Wlogical-op -Wreorder -Wsizeof-pointer-memaccess -Woverloaded-virtual -Wmismatched-new-delete -Wundef -Wredundant-decls -Wunknown-pragmas -Wunused-result -Wc++2a-compat -Wignored-attributes -Wdangling-else -Wmisleading-indentation -Wtautological-compare -Wsuggest-override -Wmaybe-uninitialized  -Wno-unused-parameter  -Wdeprecated-declarations -fvisibility-inlines-hidden -fmessage-length=0 -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -ffunction-sections -pipe -isystem /home/runner/miniconda3/envs/test/include -fvisibility-inlines-hidden -fmessage-length=0 -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -ffunction-sections -pipe -isystem /home/runner/miniconda3/envs/test/include -O3 -DNDEBUG -std=c++20 -fPIC -MD -MT src/devices/frameTransformGet_nwc_ros/CMakeFiles/yarp_frameTransformGet_nwc_ros.dir/yarp_plugin_frameTransformGet_nwc_ros.cpp.o -MF src/devices/frameTransformGet_nwc_ros/CMakeFiles/yarp_frameTransformGet_nwc_ros.dir/yarp_plugin_frameTransformGet_nwc_ros.cpp.o.d -o src/devices/frameTransformGet_nwc_ros/CMakeFiles/yarp_frameTransformGet_nwc_ros.dir/yarp_plugin_frameTransformGet_nwc_ros.cpp.o -c /home/runner/work/robotology-superbuild/robotology-superbuild/b/src/yarp-devices-ros/src/devices/frameTransformGet_nwc_ros/yarp_plugin_frameTransformGet_nwc_ros.cpp
2025-01-31T02:49:04.1781384Z In file included from /home/runner/work/robotology-superbuild/robotology-superbuild/b/src/yarp-devices-ros/src/devices/frameTransformGet_nwc_ros/yarp_plugin_frameTransformGet_nwc_ros.cpp:10:
2025-01-31T02:49:04.1784298Z /home/runner/work/robotology-superbuild/robotology-superbuild/src/yarp-devices-ros/src/devices/frameTransformGet_nwc_ros/FrameTransformGet_nwc_ros.h:85:10: error: conflicting return type specified for 'virtual bool FrameTransformGet_nwc_ros::getTransforms(std::vector<yarp::math::FrameTransform>&) const'
2025-01-31T02:49:04.1786499Z    85 |     bool getTransforms(std::vector<yarp::math::FrameTransform>& transforms) const override;
2025-01-31T02:49:04.1787285Z       |          ^~~~~~~~~~~~~
2025-01-31T02:49:04.1788453Z In file included from /home/runner/work/robotology-superbuild/robotology-superbuild/src/yarp-devices-ros/src/devices/frameTransformGet_nwc_ros/FrameTransformGet_nwc_ros.h:18:
2025-01-31T02:49:04.1791121Z /home/runner/work/robotology-superbuild/robotology-superbuild/b/install/include/yarp/dev/IFrameTransformStorage.h:78:36: note: overridden function is 'virtual yarp::dev::ReturnValue yarp::dev::IFrameTransformStorageGet::getTransforms(std::vector<yarp::math::FrameTransform>&) const'
2025-01-31T02:49:04.1793327Z    78 |     virtual yarp::dev::ReturnValue getTransforms(std::vector<yarp::math::FrameTransform>& transforms) const = 0;
2025-01-31T02:49:04.1794090Z       |                                    ^~~~~~~~~~~~~

Effect of robotology/yarp#3169. As we announced anyhow that we are dropping ros1 compatibility in 2025.02 in https://github.com/orgs/robotology/discussions/720, I guess we can just drop it.

@traversaro
Copy link
Member Author

#1789 fix some problems, but now we get another list of errors that are probably due to the use in YARP of a public C++20 dependency:

2025-01-31T08:40:36.4495013Z /home/runner/miniconda3/envs/test/include/OGRE/OgreMemorySTLAllocator.h:126:44: error: 'const_pointer' in 'class std::allocator<void>' does not name a type
2025-01-31T08:40:36.4496371Z   126 |             typename std::allocator<void>::const_pointer ptr = 0 )
2025-01-31T08:40:36.4496943Z       |  

and

2025-01-31T08:39:13.4575821Z /home/runner/miniconda3/envs/test/include/gz/transport13/gz/transport/SubscriptionHandler.hh:202:20:   required from here
2025-01-31T08:39:13.4577285Z /home/runner/miniconda3/envs/test/include/google/protobuf/port.h:176:17: error: static assertion failed
2025-01-31T08:39:13.4578171Z   176 |   static_assert(!requires {
2025-01-31T08:39:13.4578820Z       |                 ^~~~~~~~~~~
2025-01-31T08:39:13.4579275Z   177 |     std::derived_from<std::remove_pointer_t<To>,
2025-01-31T08:39:13.4579761Z       |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2025-01-31T08:39:13.4580565Z   178 |                       typename std::remove_pointer_t<To>::MessageLite>;
2025-01-31T08:39:13.4581131Z       |                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2025-01-31T08:39:13.4581585Z   179 |   });
2025-01-31T08:39:13.4581881Z       |   ~              

@traversaro
Copy link
Member Author

traversaro commented Jan 31, 2025

Other failures: robotology/yarp#3169 (comment) . Given the amount of failures, the easiest option for now is to pin YARP in Unstable branches to an earlier version, and address this failures in downstream projects, mainly:

@traversaro
Copy link
Member Author

traversaro commented Jan 31, 2025

One tricky aspect is that YARP switching to requiring C++20 in its headers make it practically impossible to build compilation units that include both YARP (that required C++20) with abseil (that has a different ABI if compiled with C++17 vs C++20, see abseil/abseil-cpp#1280). While we do not use frequently abseil directly, abseil is a public dependency of protobuf that is itself a public dependency of many projects, including the gz-* (gazebo) libraries.

@traversaro traversaro changed the title Unstable CI failure February 2025 Breaking changes in YARP February 2025 (was Unstable CI failure February 2025) Jan 31, 2025
@traversaro
Copy link
Member Author

I updated the title of the issue to reflect more the actual problems, that are:

  • Change of signature in IFrameTransform::canTransform and IFrameTransform::frameExists`
  • Public requirement of C++20 for downstream projects using YARP

@traversaro
Copy link
Member Author

In the meanwhile, I prepare a workaround in #1789 .

@traversaro
Copy link
Member Author

robotology/yarp#3173 may help on this.

@traversaro
Copy link
Member Author

fyi @Nicogene there will probably be a few breaking changes in YARP 3.11.0, we may need to evaluate if we are able to integrate it in 2025.02.0 or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant