mirror of
https://relay.ngit.dev/npub15qydau2hjma6ngxkl2cyar74wzyjshvl65za5k5rl69264ar2exs5cyejr/ngit-grasp.git
synced 2026-10-05 15:08:24 +00:00
fix(sync): schedule auxiliary coverage for full repositories
Priority demotion moved q-tagged and other non-essential repository references out of core live filters, but descendant maintenance selected only relays that already had root events. A full repository with no accepted roots therefore never installed its auxiliary repository coverage, breaking bounded-REQ and adaptive regrouping delivery. Include relays with full repositories in the bounded maintenance frontier. Update the constrained-REQ regression to wait for the observable auxiliary generation before using a q-tagged event as its live-delivery probe. State-only repositories remain excluded, and maintenance still advances only one selected relay per tick. Validated with the bounded-REQ and filter-count-refusal integration tests.
This commit is contained in:
+1
-1
@@ -4450,7 +4450,7 @@ impl SyncManager {
|
||||
let mut relay_urls: Vec<String> = targets
|
||||
.iter()
|
||||
.filter(|(relay_url, needs)| {
|
||||
!needs.root_events.is_empty()
|
||||
(!needs.repos.is_empty() || !needs.root_events.is_empty())
|
||||
&& states.get(*relay_url).is_some_and(|state| {
|
||||
matches!(
|
||||
state.connection_status,
|
||||
|
||||
@@ -150,6 +150,7 @@ async fn test_live_sync_batches_repo_filters_below_source_req_limit() {
|
||||
wait_for_sync_connection(syncing.url(), 1, Duration::from_secs(5))
|
||||
.await
|
||||
.expect("syncing relay should connect to constrained source");
|
||||
wait_for_new_descendant_live_generation(&syncing, 0, Duration::from_secs(20)).await;
|
||||
|
||||
// Observe one q-tagged event completing the round trip before testing a
|
||||
// second live event. This proves the relevant subscription is installed
|
||||
|
||||
Reference in New Issue
Block a user