Skip to content
Snippets Groups Projects
Commit e62e6706 authored by Bastian Köcher's avatar Bastian Köcher Committed by GitHub
Browse files

Print bootnode mismatch message as `warning` (#12075)

* Print bootnode mismatch message as `warning`

* Fix test :thinking:

* Remove wrong warning
parent 16842c3d
No related merge requests found
......@@ -160,18 +160,7 @@ where
.network_config
.boot_nodes
.into_iter()
.filter(|boot_node| {
if boot_node.peer_id == local_peer_id {
warn!(
target: "sub-libp2p",
"Local peer ID used in bootnode, ignoring: {}",
boot_node,
);
false
} else {
true
}
})
.filter(|boot_node| boot_node.peer_id != local_peer_id)
.collect();
params.network_config.default_peers_set.reserved_nodes = params
.network_config
......@@ -1825,7 +1814,7 @@ where
if let ConnectedPoint::Dialer { address, role_override: _ } =
endpoint
{
error!(
warn!(
"💔 The bootnode you want to connect to at `{}` provided a different peer ID `{}` than the one you expect `{}`.",
address,
obtained,
......
......@@ -631,7 +631,7 @@ mod tests {
let mut cache = local_cache.as_trie_db_cache(root);
let trie = TrieDBBuilder::<Layout>::new(&db, &root).with_cache(&mut cache).build();
for (k, _) in TEST_DATA.iter().take(2) {
for (k, _) in TEST_DATA.iter().skip(2) {
trie.get(k).unwrap().unwrap();
}
}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment