Skip to content

Commit

Permalink
chore: remove EXPERIMENTAL for rfc #917 remote_addr
Browse files Browse the repository at this point in the history
  • Loading branch information
m-schmoock committed Mar 8, 2022
1 parent 4dff537 commit f4ed33f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 9 deletions.
6 changes: 2 additions & 4 deletions connectd/peer_exchange_initmsg.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ static struct io_plan *peer_init_received(struct io_conn *conn,

/* fetch optional tlv `remote_addr` */
remote_addr = NULL;
#if EXPERIMENTAL_FEATURES /* BOLT1 remote_addr #917 */

/* BOLT-remote-address #1:
* The receiving node:
* ...
Expand All @@ -115,7 +115,6 @@ static struct io_plan *peer_init_received(struct io_conn *conn,
break;
}
}
#endif

/* The globalfeatures field is now unused, but there was a
* window where it was: combine the two. */
Expand Down Expand Up @@ -217,7 +216,7 @@ struct io_plan *peer_exchange_initmsg(struct io_conn *conn,

/* set optional tlv `remote_addr` on incoming IP connections */
tlvs->remote_addr = NULL;
#if EXPERIMENTAL_FEATURES /* BOLT1 remote_addr #917 */

/* BOLT-remote-address #1:
* The sending node:
* ...
Expand All @@ -241,7 +240,6 @@ struct io_plan *peer_exchange_initmsg(struct io_conn *conn,
break;
}
}
#endif

/* Initially, there were two sets of feature bits: global and local.
* Local affected peer nodes only, global affected everyone. Both were
Expand Down
6 changes: 2 additions & 4 deletions tests/test_connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,8 @@ def test_connect_basic(node_factory):
assert len(l1.rpc.listpeers()) == 1
assert len(l2.rpc.listpeers()) == 1

if EXPERIMENTAL_FEATURES: # BOLT1 remote_addr #917
if DEVELOPER:
print(l1.daemon.wait_for_log("Peer says it sees our address as: 127.0.0.1:[0-9]{5}"))
if DEVELOPER:
print(l1.daemon.wait_for_log("Peer says it sees our address as: 127.0.0.1:[0-9]{5}"))

# Should get reasonable error if unknown addr for peer.
with pytest.raises(RpcError, match=r'Unable to connect, no address known'):
Expand All @@ -64,7 +63,6 @@ def test_connect_basic(node_factory):


@pytest.mark.developer("needs DEVELOPER=1 for having localhost remote_addr and fast gossip")
@unittest.skipIf(not EXPERIMENTAL_FEATURES, "BOLT1 remote_addr #917")
def test_remote_addr(node_factory, bitcoind):
"""Check address discovery (BOLT1 #917) init remote_addr works as designed:
Expand Down
1 change: 0 additions & 1 deletion tests/test_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,6 @@ def check_disconnect():
assert not l1.daemon.is_in_log(f"peer_connected_logger_b {l3id}")


@unittest.skipIf(not EXPERIMENTAL_FEATURES, "BOLT1 remote_addr #917")
@pytest.mark.developer("localhost remote_addr will be filtered without DEVELOEPR")
def test_peer_connected_remote_addr(node_factory):
"""This tests the optional tlv `remote_addr` being passed to a plugin.
Expand Down

0 comments on commit f4ed33f

Please sign in to comment.