Skip to content

Declare the missing dependencies that packages use #13207

Description

@xmfcx

Description

195 packages in this repository use a package or a system library that they never declare. The checker found 1061 missing entries: 959 <depend> and 102 <test_depend>.

These packages build today only because another declared dependency re-exports the owner, or because some other package installs the system library. That is luck, not correctness. When an unrelated repository stops re-exporting, the package no longer compiles, and the CI of this repository never sees the change.

How each entry was found

The checker uses three kinds of evidence.

  • An #include of a header, resolved against the package that really ships that header.
  • A qualified name such as rcl_interfaces::msg::ParameterDescriptor in code, where the header arrives through another dependency. An include scan cannot see this kind.
  • A system library such as Boost, Eigen or PCL, resolved through the compiler search paths, dpkg, and the rosdep cache, and named by the rosdep key this workspace already prefers.

Comments do not count. The checker blanks comments and string literals before it scans, because a Doxygen example is not a use.

The tag comes from where the dependency is used.

  • <depend> when the use sits in an installed header or in code compiled into the library. 959 entries.
  • <test_depend> when only test/ reaches the dependency. 102 entries.

The checker refuses an entry that would create a dependency cycle. The measurement ran on 2026-08-15, on main at 4260f35, in a jazzy workspace.

Validation

These counts are raw checker output. The core rounds reviewed every core entry per package, and the reviews corrected the checker five times. The simulator, e2e and map entries are reviewed, and that review added one entry the checker missed: tf2 in tier4_dummy_object_rviz_plugin. The other components are not reviewed yet.

Each component gets the same per-package review before its pull request, so the counts here can change.

The entries by component

The most frequent missing dependencies are libboost-dev (67), lanelet2_core (57), std_msgs (57), geometry_msgs (55), and eigen (54).

Component Packages Entries
planning 57 501
perception 48 260
control 19 77
localization 12 47
visualization 12 38
sensing 11 37
common 10 33
evaluator 6 25
system 13 21
vehicle 4 10
simulator 1 5
e2e 1 4
map 1 3
Total 195 1061

Pull requests

One pull request per component, opened one at a time, after its review, smallest first. The three smallest components share one pull request. planning is large, and it can split into several pull requests.

Definition of done

  • Every reviewed entry is present in the package.xml of its package, with the tag given.
  • A build of the changed packages and their reverse-dependency closure stays clean.

Adding a <depend> cannot break a build, so this work carries no risk to the packages themselves.


Written with Claude Code. The entries come from the checker that produced the core list, and a per-package review runs before each pull request.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

type:bugSoftware flaws or errors.

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions