mirror of
https://github.com/waku-org/nwaku.git
synced 2025-01-28 07:35:56 +00:00
deploy: d49c95f6a142bde8cd607ca333eade5c405cf59a
This commit is contained in:
parent
e846609ac7
commit
35f3a439c0
@ -63,7 +63,7 @@ procSuite "Waku v2 JSON-RPC API":
|
||||
let response = await client.get_waku_v2_debug_v1_info()
|
||||
|
||||
check:
|
||||
response.listenStr == $node.peerInfo.addrs[^1] & "/p2p/" & $node.peerInfo.peerId
|
||||
response.listenAddresses == @[$node.peerInfo.addrs[^1] & "/p2p/" & $node.peerInfo.peerId]
|
||||
|
||||
server.stop()
|
||||
server.close()
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
# libtool - Provide generalized library-building support services.
|
||||
# Generated automatically by config.status (libbacktrace) version-unused
|
||||
# Libtool was configured on host fv-az190-306:
|
||||
# Libtool was configured on host fv-az196-961:
|
||||
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
|
||||
#
|
||||
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
|
||||
|
@ -68,7 +68,7 @@ type
|
||||
|
||||
WakuInfo* = object
|
||||
# NOTE One for simplicity, can extend later as needed
|
||||
listenStr*: string
|
||||
listenAddresses*: seq[string]
|
||||
#multiaddrStrings*: seq[string]
|
||||
|
||||
# NOTE based on Eth2Node in NBC eth2_network.nim
|
||||
@ -392,10 +392,12 @@ proc info*(node: WakuNode): WakuInfo =
|
||||
## Status: Implemented.
|
||||
##
|
||||
|
||||
# TODO Generalize this for other type of multiaddresses
|
||||
let peerInfo = node.peerInfo
|
||||
let listenStr = $peerInfo.addrs[^1] & "/p2p/" & $peerInfo.peerId
|
||||
let wakuInfo = WakuInfo(listenStr: listenStr)
|
||||
var listenStr : seq[string]
|
||||
for address in node.announcedAddresses:
|
||||
var fulladdr = $address & "/p2p/" & $peerInfo.peerId
|
||||
listenStr &= fulladdr
|
||||
let wakuInfo = WakuInfo(listenAddresses: listenStr)
|
||||
return wakuInfo
|
||||
|
||||
proc mountFilter*(node: WakuNode) {.raises: [Defect, KeyError, LPError]} =
|
||||
|
Loading…
x
Reference in New Issue
Block a user