Following up on the BIP155 addrv2 changes, and starting with 7be6ff6 in #19845, RPC getnetworkinfo began returning networks with empty names.
0 "networks": [
1 {
2 "name": "ipv4",
3 "limited": false,
4 "reachable": true,
5 "proxy": "",
6 "proxy_randomize_credentials": false
7 },
8 {
9 "name": "ipv6",
10 "limited": false,
11 "reachable": true,
12 "proxy": "",
13 "proxy_randomize_credentials": false
14 },
15 {
16 "name": "onion",
17 "limited": false,
18 "reachable": true,
19 "proxy": "127.0.0.1:9050",
20 "proxy_randomize_credentials": true
21 },
22 {
23 "name": "",
24 "limited": false,
25 "reachable": true,
26 "proxy": "",
27 "proxy_randomize_credentials": false
28 },
29 {
30 "name": "",
31 "limited": false,
32 "reachable": true,
33 "proxy": "",
34 "proxy_randomize_credentials": false
35 }
36 ],
0 "networks": [
1 {
2 "name": "ipv4",
3 "limited": false,
4 "reachable": true,
5 "proxy": "",
6 "proxy_randomize_credentials": false
7 },
8 {
9 "name": "ipv6",
10 "limited": false,
11 "reachable": true,
12 "proxy": "",
13 "proxy_randomize_credentials": false
14 },
15 {
16 "name": "onion",
17 "limited": false,
18 "reachable": true,
19 "proxy": "127.0.0.1:9050",
20 "proxy_randomize_credentials": true
21 }
22 ],
This patch:
- updates
GetNetworkName()
to the current Network enum - updates
getNetworksInfo()
to ignore as-yet unsupported networks - adds regression tests