test: fix intermittent failure in p2p_leak_tx.py #27864

pull mzumsande wants to merge 1 commits into bitcoin:master from mzumsande:202306_fix_p2p_leak changing 1 files +1 −0
  1. mzumsande commented at 6:01 pm on June 12, 2023: contributor

    Fixes #27860

    The problem was that the replacement tx tx_b would sometimes be sent out to the inbound peer after the notfound, so that threre would be an unexpected tx message and the test fails.

    0 node0 2023-06-12T12:48:24.903204Z [msghand] [net.cpp:2856] [PushMessage] [net] sending notfound (73 bytes) peer=1 
    1 node0 2023-06-12T12:48:24.903916Z [msghand] [net.cpp:2856] [PushMessage] [net] sending tx (133 bytes) peer=1 
    2                                     File "/tmp/cirrus-ci-build/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/p2p_leak_tx.py", line 74, in test_notfound_on_replaced_tx
    3                                       assert "tx" not in inbound_peer.last_message
    

    Fix this by letting the peer wait for the initial broadcast of the replacement tx before continuing with the test.

  2. DrahtBot commented at 6:01 pm on June 12, 2023: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK MarcoFalke

    If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

  3. DrahtBot added the label Tests on Jun 12, 2023
  4. mzumsande marked this as a draft on Jun 12, 2023
  5. mzumsande force-pushed on Jun 12, 2023
  6. mzumsande marked this as ready for review on Jun 12, 2023
  7. test: fix intermittent failure in p2p_leak_tx.py ee2417ed61
  8. mzumsande force-pushed on Jun 12, 2023
  9. maflcko commented at 6:53 am on June 13, 2023: member

    Thanks!

    lgtm ACK ee2417ed614d6a298f932ac068702ab2abee3cdf

  10. fanquake merged this on Jun 13, 2023
  11. fanquake closed this on Jun 13, 2023

  12. sidhujag referenced this in commit fb74531908 on Jun 15, 2023
  13. mzumsande deleted the branch on Jun 15, 2023
  14. bitcoin locked this on Jun 14, 2024

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-11-24 15:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me