diff options
author | fanquake <fanquake@gmail.com> | 2023-07-19 12:26:48 +0100 |
---|---|---|
committer | fanquake <fanquake@gmail.com> | 2023-07-19 12:32:30 +0100 |
commit | 0be2f5481cc3bdfd1a570ecf61e36906f3344664 (patch) | |
tree | 1737e8b05d2656400b2158ef0685f45439ac373e /test/functional/feature_anchors.py | |
parent | 3648a9b4f714b49a152f2bf0f9d5f4c8e1089add (diff) | |
parent | 20b49460b35268db59f7efcb02736b0e31191a74 (diff) | |
download | bitcoin-0be2f5481cc3bdfd1a570ecf61e36906f3344664.tar.xz |
Merge bitcoin/bitcoin#27986: test: remove race in the user-agent reception check
20b49460b35268db59f7efcb02736b0e31191a74 test: remove race in the user-agent reception check (Vasil Dimov)
Pull request description:
In `add_p2p_connection()` we connect to `bitcoind` from the Python client and check that it has received our version string.
This check looked up the last/newest entry from `getpeerinfo` RPC, assuming that it must be the connection we have just opened. But this will not be the case if a new inbound or outbound connection is made to/from `bitcoind` in the meantime.
Instead of the last entry in `getpeerinfo`, check all and find the one which corresponds to our connection using our outgoing address:port tuple which is unique.
ACKs for top commit:
jonatack:
re-ACK 20b49460b35268db59f7efcb02736b0e31191a74
MarcoFalke:
Concept ACK 20b49460b35268db59f7efcb02736b0e31191a74
Tree-SHA512: 61fd3359ef11ea830021ede0e745497a7b60690c32d21c47cd12ff79f78907bb45e922c9d01e5d7ff614a8cd5e4560d39a3fc86b01b200429773a23ace3917e4
Diffstat (limited to 'test/functional/feature_anchors.py')
0 files changed, 0 insertions, 0 deletions