From b9a3b5e46d1cfe955fbec32adce02abd608d9550 Mon Sep 17 00:00:00 2001 From: Gabriel mermelstein Date: Mon, 19 Aug 2024 11:41:06 +0200 Subject: [PATCH] fixing rebase compilation errors --- tests/wakunode2/test_validators.nim | 6 +++--- waku/factory/external_config.nim | 2 +- waku/factory/validator_signed.nim | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/wakunode2/test_validators.nim b/tests/wakunode2/test_validators.nim index cc44304fb1..058d2bedf4 100644 --- a/tests/wakunode2/test_validators.nim +++ b/tests/wakunode2/test_validators.nim @@ -32,7 +32,7 @@ suite "WakuNode2 - Validators": ) # Protected shard and key to sign - let spamProtectedShard = NsPubsubTopic(clusterId: 0, shardId: 7) + let spamProtectedShard = RelayShard(clusterId: 0, shardId: 7) let secretKey = SkSecretKey .fromHex("5526a8990317c9b7b58d07843d270f9cd1d9aaee129294c1c478abf7261dd9e6") .expect("valid key") @@ -117,7 +117,7 @@ suite "WakuNode2 - Validators": ) # Protected shard and key to sign - let spamProtectedShard = NsPubsubTopic(clusterId: 0, shardId: 7) + let spamProtectedShard = RelayShard(clusterId: 0, shardId: 7) let secretKey = SkSecretKey .fromHex("5526a8990317c9b7b58d07843d270f9cd1d9aaee129294c1c478abf7261dd9e6") .expect("valid key") @@ -267,7 +267,7 @@ suite "WakuNode2 - Validators": ) # Protected shard and key to sign - let spamProtectedShard = NsPubsubTopic(clusterId: 0, shardId: 7) + let spamProtectedShard = RelayShard(clusterId: 0, shardId: 7) let secretKey = SkSecretKey .fromHex("5526a8990317c9b7b58d07843d270f9cd1d9aaee129294c1c478abf7261dd9e6") .expect("valid key") diff --git a/waku/factory/external_config.nim b/waku/factory/external_config.nim index f8c4187994..22214999a8 100644 --- a/waku/factory/external_config.nim +++ b/waku/factory/external_config.nim @@ -725,7 +725,7 @@ proc parseCmdArg*(T: type ProtectedShard, p: string): T = return ProtectedShard(shard: uint16.parseCmdArg(elements[0]), key: publicKey.get()) # TO DO: Remove when removing protected-topic configuration - let shard = NsPubsubTopic.parse(elements[0]).valueOr: + let shard = RelayShard.parse(elements[0]).valueOr: raise newException( ValueError, "Invalid pubsub topic. Pubsub topics must be in the format /waku/2/rs//", diff --git a/waku/factory/validator_signed.nim b/waku/factory/validator_signed.nim index fa76e43ea9..25a6f5b882 100644 --- a/waku/factory/validator_signed.nim +++ b/waku/factory/validator_signed.nim @@ -62,7 +62,7 @@ proc addSignedShardsValidator*( for protectedShard in protectedShards: let topicString = - $NsPubsubTopic(clusterId: clusterId, shardId: uint16(protectedShard.shard)) + $RelayShard(clusterId: clusterId, shardId: uint16(protectedShard.shard)) if (topicString == topic): if msg.timestamp != 0: if msg.withinTimeWindow():