[qa] Fix race conditions in p2p-compactblocks.py and sendheaders.py #8882

pull sdaftuar wants to merge 2 commits into bitcoin:master from sdaftuar:fix-race-again changing 2 files +48 −44
  1. sdaftuar commented at 7:56 pm on October 4, 2016: member

    Sorry for the code churn in this test; this is another attempt to resolve the test failure reported in #8842.

    In #8854 I added a sync_with_ping() with the idea of making sure that we’d processed all the block announcements from the node before continuing in the test; however that is insufficient for making sure that the node had actually tried sending all the block announcements it’s going to eventually send. My guess is that the test failures are happening in situations where the block announcements from the generate(101) call don’t finish arriving until after the sync_with_ping(), throwing off the later tests.

    So I replaced the sync_with_ping with an explicit check that the node’s tip has been announced, before continuing on with the test. Hopefully this resolves the lingering issues.

  2. [qa] Another attempt to fix race condition in p2p-compactblocks.py
    sync_with_ping() only guarantees that the node has processed messages
    it's received from the peer, not that block announcements from the node have
    made it back to the peer.  Replace sync_with_ping() with an explicit check that
    the node's tip has been announced.
    6976db2f46
  3. fanquake added the label Tests on Oct 5, 2016
  4. MarcoFalke commented at 7:43 am on October 5, 2016: member
    utACK 6976db2
  5. MarcoFalke added the label Needs backport on Oct 5, 2016
  6. MarcoFalke added this to the milestone 0.13.1 on Oct 5, 2016
  7. MarcoFalke referenced this in commit b73f0653f3 on Oct 5, 2016
  8. sdaftuar commented at 1:20 pm on October 6, 2016: member
    I suspect the failure in sendheaders may have the same underlying cause:a generate() call where the block announcements might be arriving later than expected. I’ll try to fix that up in this PR as well.
  9. [qa] Fix race condition in sendheaders.py
    Also de-duplicates code that has been moved to mininode
    b55d9411e7
  10. sdaftuar renamed this:
    [qa] Another attempt to fix race condition in p2p-compactblocks.py
    [qa] Fix race conditions in p2p-compactblocks.py and sendheaders.py
    on Oct 6, 2016
  11. sdaftuar commented at 6:42 pm on October 6, 2016: member
    I believe I’ve addressed the occasional test failure in sendheaders.py as well now.
  12. MarcoFalke referenced this in commit d6c83b95cf on Oct 6, 2016
  13. MarcoFalke commented at 7:33 pm on October 8, 2016: member
    utACK b55d941
  14. instagibbs commented at 8:46 am on October 10, 2016: member
    utACK b55d9411e7e1aa36ddabba3b942f2e1c736c1bd9
  15. btcdrak commented at 5:39 pm on October 10, 2016: contributor
    utACK d6c83b95cff2ff290533593719d6501ecf128f13
  16. MarcoFalke merged this on Oct 11, 2016
  17. MarcoFalke closed this on Oct 11, 2016

  18. MarcoFalke referenced this in commit d075479969 on Oct 11, 2016
  19. MarcoFalke removed the label Needs backport on Oct 13, 2016
  20. ryanofsky referenced this in commit 186bd1de8e on Oct 25, 2016
  21. ryanofsky referenced this in commit d05cfd9d2c on Nov 1, 2016
  22. ryanofsky referenced this in commit 47e9659ecf on Nov 3, 2016
  23. MarcoFalke referenced this in commit 2ba5d78427 on Nov 20, 2016
  24. gladcow referenced this in commit f15b41f746 on Mar 2, 2018
  25. gladcow referenced this in commit dd85a5ed46 on Mar 13, 2018
  26. gladcow referenced this in commit 282ea81f59 on Mar 14, 2018
  27. gladcow referenced this in commit bf70ade22a on Mar 15, 2018
  28. gladcow referenced this in commit 0027f189a6 on Mar 15, 2018
  29. gladcow referenced this in commit 4ed8cc9425 on Mar 15, 2018
  30. gladcow referenced this in commit 77737a714f on Mar 24, 2018
  31. gladcow referenced this in commit 50858ef9e7 on Apr 4, 2018
  32. UdjinM6 referenced this in commit bc45a2f87a on Apr 11, 2018
  33. lateminer referenced this in commit 531d15ea84 on Oct 21, 2018
  34. andvgal referenced this in commit fd5c50bc2b on Jan 6, 2019
  35. CryptoCentric referenced this in commit dd3fd51204 on Feb 28, 2019
  36. MarcoFalke locked this on Sep 8, 2021

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-10-05 04:12 UTC

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