https://github.com/bitcoin/bitcoin/pull/19178/commits/edae6075aa3b1169c84b65e76fd48d68242a294e
[tests] Only acquire lock once in p2p_compactblocks.py
https://github.com/bitcoin/bitcoin/pull/19178/commits/9d80762fa0931fe553fad241e95bcc1515ef0e95
[tests] Don't acquire mininode_lock twice in wait_for_broadcast()
https://github.com/bitcoin/bitcoin/pull/19178/commits/c67c1f2c032a8efa141d776a7e5be58f052159ea
[tests] Make mininode_lock non-reentrant
This is a backport of core#19178