Skip to content

Add build for rmf-dev package #298

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

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Add build for rmf-dev package #298

wants to merge 3 commits into from

Conversation

Ac31415
Copy link

@Ac31415 Ac31415 commented May 21, 2025

No description provided.

@traversaro
Copy link
Member

There are a few transitive dependency of rmf-dev, and so a few packages are built that are failing on all platforms. Let us know if you are interested in working on this and if you would like some tips on how to debug.

@Ac31415
Copy link
Author

Ac31415 commented May 23, 2025

There are a few transitive dependency of rmf-dev, and so a few packages are built that are failing on all platforms. Let us know if you are interested in working on this and if you would like some tips on how to debug.

Hi! Yeah I'm interested in working in this. But my main focus will be on osx-arm64 for now. I've been getting errors mainly from the 'rmf_traffics' module. Copilot has been telling me it's due to scripts such as 'Database.cpp' having the 'final' tag at the end of some methods. But I'm not sure if what it's saying is exactly true. So I'd really appreciate some tips on debugging!

@traversaro
Copy link
Member

Ok! First of all, you can always start by copying the error you want to tackle in an comment, so the error on osx-arm64 :

2025-05-21T20:05:00.2469210Z  │ │ In file included from $SRC_DIR/ros-humble-rmf-traffic/src/work/src/rmf_traffic/schedule/Database.cpp:22:
2025-05-21T20:05:00.2469920Z  │ │ In file included from $SRC_DIR/ros-humble-rmf-traffic/src/work/src/rmf_traffic/schedule/debug_Database.hpp:21:
2025-05-21T20:05:00.2470680Z  │ │ $SRC_DIR/ros-humble-rmf-traffic/src/work/include/rmf_traffic/schedule/Database.hpp:116:39: error: non-virtual member function marked 'final' hides virtual 
2025-05-21T20:05:00.2471260Z  │ │ member function
2025-05-21T20:05:00.2472890Z  │ │   116 |     std::size_t participant_id) const final;
2025-05-21T20:05:00.2475770Z  │ │       |                                       ^
2025-05-21T20:05:00.2476580Z  │ │ $SRC_DIR/ros-humble-rmf-traffic/src/work/include/rmf_traffic/schedule/Viewer.hpp:104:57: note: hidden overloaded virtual function 'rmf_traffic::schedule::V
2025-05-21T20:05:00.2477690Z  │ │ iewer::get_participant' declared here: type mismatch at 1st parameter ('ParticipantId' (aka 'unsigned long long') vs 'std::size_t' (aka 'unsigned long'))
2025-05-21T20:05:00.2597340Z  │ │   104 |   virtual std::shared_ptr<const ParticipantDescription> get_participant(
2025-05-21T20:05:00.2702790Z  │ │       |                                                         ^
2025-05-21T20:05:00.2838060Z  │ │ In file included from $SRC_DIR/ros-humble-rmf-traffic/src/work/src/rmf_traffic/schedule/Database.cpp:22:
2025-05-21T20:05:00.2954040Z  │ │ In file included from $SRC_DIR/ros-humble-rmf-traffic/src/work/src/rmf_traffic/schedule/debug_Database.hpp:21:
2025-05-21T20:05:00.3057280Z  │ │ $SRC_DIR/ros-humble-rmf-traffic/src/work/include/rmf_traffic/schedule/Database.hpp:128:39: error: non-virtual member function marked 'final' hides virtual 
2025-05-21T20:05:00.3177090Z  │ │ member function
2025-05-21T20:05:00.3279810Z  │ │   128 |     std::size_t participant_id) const final;
2025-05-21T20:05:00.3391260Z  │ │       |                                       ^
2025-05-21T20:05:00.3528720Z  │ │ $SRC_DIR/ros-humble-rmf-traffic/src/work/include/rmf_traffic/schedule/Viewer.hpp:134:40: note: hidden overloaded virtual function 'rmf_traffic::schedule::I
2025-05-21T20:05:00.3642610Z  │ │ tineraryViewer::get_itinerary' declared here: type mismatch at 1st parameter ('ParticipantId' (aka 'unsigned long long') vs 'std::size_t' (aka 'unsigned lo
2025-05-21T20:05:00.3749400Z  │ │ ng'))
2025-05-21T20:05:00.3858190Z  │ │   134 |   virtual std::optional<ItineraryView> get_itinerary(
2025-05-21T20:05:00.3961800Z  │ │       |                                        ^
2025-05-21T20:05:00.4065890Z  │ │ In file included from $SRC_DIR/ros-humble-rmf-traffic/src/work/src/rmf_traffic/schedule/Database.cpp:22:
2025-05-21T20:05:00.4170090Z  │ │ In file included from $SRC_DIR/ros-humble-rmf-traffic/src/work/src/rmf_traffic/schedule/debug_Database.hpp:21:
2025-05-21T20:05:00.4294560Z  │ │ $SRC_DIR/ros-humble-rmf-traffic/src/work/include/rmf_traffic/schedule/Database.hpp:132:39: error: non-virtual member function marked 'final' hides virtual 
2025-05-21T20:05:00.4296110Z  │ │ member function
2025-05-21T20:05:00.4419070Z  │ │   132 |     std::size_t participant_id) const final;
2025-05-21T20:05:00.4527210Z  │ │       |                                       ^
2025-05-21T20:05:00.4631550Z  │ │ $SRC_DIR/ros-humble-rmf-traffic/src/work/include/rmf_traffic/schedule/Viewer.hpp:140:33: note: hidden overloaded virtual function 'rmf_traffic::schedule::I
2025-05-21T20:05:00.4743490Z  │ │ tineraryViewer::get_current_plan_id' declared here: type mismatch at 1st parameter ('ParticipantId' (aka 'unsigned long long') vs 'std::size_t' (aka 'unsig
2025-05-21T20:05:00.4845070Z  │ │ ned long'))
2025-05-21T20:05:00.4948510Z  │ │   140 |   virtual std::optional<PlanId> get_current_plan_id(
2025-05-21T20:05:00.5058110Z  │ │       |                                 ^
2025-05-21T20:05:00.5174220Z  │ │ 1 warning and 3 errors generated.

This is helpful (as long as the test that you copy is not so long) so other users do not need to dig in the log to actually find the error, and also as log over time expire and get deleted, while comments remain and can be found by search engines and llms.

@Ac31415
Copy link
Author

Ac31415 commented May 23, 2025

Great! What if the error log is long? Is there a file where the complete error is logged?

@traversaro
Copy link
Member

Great! What if the error log is long? Is there a file where the complete error is logged?

Not automatically. IF the error log is long and you want to save it permanently, I would suggest to save it to a gist and link it in an issue. Going back to the actual build error, it seems that the problem is a mismatch between PartecipantId (type used in the interface) and std::size_t (type used in the implementation in child classes). It seems all these problems are fixed in the latest version of rmf-traffic, but the humble version is the old 3.0.3 one (see https://github.com/ros/rosdistro/blob/bbc6dd676fa320ac7f0eda7369ce599241997129/humble/distribution.yaml#L8138 and https://github.com/open-rmf/rmf_traffic/blob/3.0.3/rmf_traffic/include/rmf_traffic/schedule/Database.hpp#L116) . It seems that the fix was in the recent PR open-rmf/rmf_traffic#98, probably we can try to add this patch locally and see if this fixes the PR. See https://robostack.github.io/Contributing.html for more info on how to create or add a patch, thanks!

For referece, see also this ChatGPT conversation, that seems to correctly frame the problem, even if it seems that it hallucinated the version that actually contains the fix: https://chatgpt.com/share/6831e6ca-ae34-8006-81bb-e0c40dc2f800 .

@Ac31415
Copy link
Author

Ac31415 commented May 25, 2025

Great! I'll definitely take some time to look at these. Thanks for the resources. Please also excuse me as this is my first time contributing to a public project. And I'm still taking the time familiarizing myself with the tools haha

@Ac31415
Copy link
Author

Ac31415 commented May 25, 2025

Yeah I see it now. I'll definitely try to patch that PR locally and see what I get. Will definitely try that after I'm done with the chores in the morning

@traversaro
Copy link
Member

Great! I'll definitely take some time to look at these. Thanks for the resources. Please also excuse me as this is my first time contributing to a public project. And I'm still taking the time familiarizing myself with the tools haha

Sure, no problem, the learning curve for contributions can be steep, feel free to ask questions if you have doubts.

@Ac31415
Copy link
Author

Ac31415 commented May 26, 2025

Thanks so much!
Will let you know

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

Successfully merging this pull request may close these issues.

2 participants