From 8d74e791dfe74dcc3bfd6e0735a0058e6f783398 Mon Sep 17 00:00:00 2001 From: Aaryamann Challani <43716372+rymnc@users.noreply.github.com> Date: Mon, 16 Jan 2023 13:59:45 +0530 Subject: [PATCH] fix(chat2): warn when rln relay is enabled but not compiled (#1494) --- apps/chat2/chat2.nim | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/apps/chat2/chat2.nim b/apps/chat2/chat2.nim index 024f13756..64da6d221 100644 --- a/apps/chat2/chat2.nim +++ b/apps/chat2/chat2.nim @@ -393,7 +393,7 @@ proc processInput(rfd: AsyncFD) {.async.} = if conf.rlnRelayEthAccountPrivateKey == "" and conf.rlnRelayCredPath == "": raise newException(ConfigurationError, - "Either rln-relay-eth-private-key or rln-relay-cred-path MUST be passed") + "Either rln-relay-eth-account-private-key or rln-relay-cred-path MUST be passed") if conf.relay: await node.mountRelay(conf.topics.split(" ")) @@ -565,7 +565,7 @@ proc processInput(rfd: AsyncFD) {.async.} = rlnRelayCredentialsPassword: conf.rlnRelayCredentialsPassword ) - await node.mountRlnRelay(rlnConf, + await node.mountRlnRelay(rlnConf, spamHandler=some(spamHandler), registrationHandler=some(registrationHandler)) @@ -574,7 +574,10 @@ proc processInput(rfd: AsyncFD) {.async.} = echo "your rln identity nullifier is: ", node.wakuRlnRelay.identityCredential.idNullifier.inHex() echo "your rln identity secret hash is: ", node.wakuRlnRelay.identityCredential.idSecretHash.inHex() echo "your rln identity commitment key is: ", node.wakuRlnRelay.identityCredential.idCommitment.inHex() - + else: + info "WakuRLNRelay is disabled" + if conf.rlnRelay: + echo "WakuRLNRelay is disabled, please enable it by compiling with the RLN/EXPERIMENTAL flag" if conf.metricsLogging: startMetricsLog()