Skip to content

Commit 7c97da7

Browse files
committed
fix(cbf): default required_peers to 1
The previous default of 2 caused test failures when only a single bitcoind peer is available. A value of 1 is valid per BIP 157 and sufficient for most setups; users can increase it for stronger filter header cross-validation.
1 parent 528c425 commit 7c97da7

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/config.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -514,7 +514,7 @@ pub struct CbfSyncConfig {
514514
/// of downloading incorrect filter headers. Setting this to 1 means filter headers from a
515515
/// single peer are trusted without cross-validation.
516516
///
517-
/// Defaults to 2.
517+
/// Defaults to 1.
518518
pub required_peers: u8,
519519
}
520520

@@ -524,7 +524,7 @@ impl Default for CbfSyncConfig {
524524
background_sync_config: Some(BackgroundSyncConfig::default()),
525525
timeouts_config: SyncTimeoutsConfig::default(),
526526
response_timeout_secs: 30,
527-
required_peers: 2,
527+
required_peers: 1,
528528
}
529529
}
530530
}

0 commit comments

Comments
 (0)