From 5a0c14cf61efaa0cd30880a7e5667b4ac2c96a4f Mon Sep 17 00:00:00 2001 From: Fintan Halpenny Date: Thu, 29 May 2025 16:57:29 +0200 Subject: [PATCH] radicle: ensure preferred seeds are announced to Ensure that the preferred seeds that are not in the synced set are announced to. --- radicle/src/node/sync/announce.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/radicle/src/node/sync/announce.rs b/radicle/src/node/sync/announce.rs index 6b0b396b..2e4d41ca 100644 --- a/radicle/src/node/sync/announce.rs +++ b/radicle/src/node/sync/announce.rs @@ -51,6 +51,12 @@ impl Announcer { .into()); } + // N.b extend the unsynced set with any preferred seeds that are not yet + // synced + config + .unsynced + .extend(config.preferred_seeds.difference(&config.synced).copied()); + let replicas = config.replicas.min(config.unsynced.len()); let announcer = Self { local_node: config.local_node,