Disable the custom distance functions for Portal Protocol (#832)

The Portal Network tests fail with the custom functions,
on one part due to the fact that the portal tests still
uses the xor functions, but also because the
`neighboursAtDistances` call appears to filter them out.
The reverse calculation might be off.
This commit is contained in:
Kim De Mey 2021-09-20 12:55:03 +02:00 committed by GitHub
parent be91bb349b
commit 7a42d037f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -11,7 +11,7 @@ import
std/[sequtils, sets, algorithm],
stew/[results, byteutils], chronicles, chronos, nimcrypto/hash,
eth/rlp, eth/p2p/discoveryv5/[protocol, node, enr, routing_table, random2, nodes_verification],
./messages, ./custom_distance
./messages
export messages
@ -180,7 +180,7 @@ proc new*(T: type PortalProtocol, baseProtocol: protocol.Protocol,
dataRadius = UInt256.high()): T =
let proto = PortalProtocol(
routingTable: RoutingTable.init(baseProtocol.localNode, DefaultBitsPerHop,
DefaultTableIpLimits, baseProtocol.rng, customDistanceCalculator),
DefaultTableIpLimits, baseProtocol.rng),
protocolHandler: messageHandler,
baseProtocol: baseProtocol,
dataRadius: dataRadius,