From 36e8cf1fe442af3beee043d8a296eb41c4c7cd9b Mon Sep 17 00:00:00 2001 From: Pratik Mankawde <3397372+pratikmankawde@users.noreply.github.com> Date: Tue, 28 Jul 2026 13:03:39 +0100 Subject: [PATCH] fix(peerfinder): include the header that declares SlotCensus The phase-10 merge relocated PeerFinder's Manager interface from src/xrpld/peerfinder/ to include/xrpl/peerfinder/, and SlotCensus moved with it so libxrpl could see it. Logic.h uses SlotCensus as the return type of getSlotCensus() but was never given the include, so every build failed: build/modules/xrpl.libxrpl.peerfinder/xrpl/peerfinder/detail/Logic.h:192:5: error: unknown type name 'SlotCensus' ...:197:16: error: use of undeclared identifier 'SlotCensus'; did you mean 'getSlotCensus'? That single missing declaration was the whole failure. The 34 further errors in the log were cascade: PeerFinderTest could not compile, so every TEST() in src/tests/libxrpl/peerfinder/PeerFinder.cpp failed to instantiate against gtest-internal.h. All four platforms (ubuntu-clang, ubuntu-gcc, macos-arm64, windows-amd64) and clang-tidy reported the same root cause. No include cycle: PeerfinderManager.h does not include detail/Logic.h, directly or transitively. Levelization is unchanged because both headers are already in xrpl.libxrpl.peerfinder, so generate.py produces no diff. This is the risk called out when the merge landed -- moving SlotCensus into the public header was the one resolution a static check could not confirm, and only a compile would prove it. CI is that compile, and it found this. Co-Authored-By: Claude Opus 5 (1M context) --- include/xrpl/peerfinder/detail/Logic.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/xrpl/peerfinder/detail/Logic.h b/include/xrpl/peerfinder/detail/Logic.h index ea4706372c..84c7e94a3e 100644 --- a/include/xrpl/peerfinder/detail/Logic.h +++ b/include/xrpl/peerfinder/detail/Logic.h @@ -11,6 +11,7 @@ #include #include #include +#include #include #include #include