tests: fix spurious addrman test failure #10429

pull theuni wants to merge 1 commits into bitcoin:master from theuni:fix-addrman-test changing 1 files +7 −3
  1. theuni commented at 4:15 am on May 19, 2017: member

    There have been a few PRs lately that have failed checks due to a bug introduced in #10287. The first check happened to work already because the chosen addresses didn’t collide. The addrman.Clear() after that check causes addrman’s salt to be reset, making all future tests non-deterministic.

    When inserting two addresses of the same class, from the same source, there’s a 1/64 chance that their hashes will collide. So it’s faulty logic to be checking for an exact size. @sipa, mind verifying that?

    I’d like to fix this properly by ensuring determinism in the test as a next step, but I’d rather fix the spurious failures asap.

  2. tests: fix spurious addrman test failure
    When inserting two addresses of the same class, from the same source, they have
    a 1/64 chance of colliding.
    6b51b0a076
  3. fanquake added the label Tests on May 19, 2017
  4. laanwj commented at 1:51 pm on May 19, 2017: member
    utACK 6b51b0a, had noticed this one as well, thanks for fixing
  5. laanwj merged this on May 19, 2017
  6. laanwj closed this on May 19, 2017

  7. laanwj referenced this in commit 6b99dafe42 on May 19, 2017
  8. PastaPastaPasta referenced this in commit 790f444272 on Jun 10, 2019
  9. PastaPastaPasta referenced this in commit d1253dd022 on Jun 11, 2019
  10. PastaPastaPasta referenced this in commit 50784f8867 on Jun 11, 2019
  11. PastaPastaPasta referenced this in commit 8a21ccc77b on Jun 15, 2019
  12. PastaPastaPasta referenced this in commit 6321e02bf7 on Jun 19, 2019
  13. PastaPastaPasta referenced this in commit 209f087f74 on Jun 19, 2019
  14. PastaPastaPasta referenced this in commit 04562186ac on Jun 19, 2019
  15. PastaPastaPasta referenced this in commit b1e6a1e2e3 on Jun 19, 2019
  16. PastaPastaPasta referenced this in commit 5e564513c3 on Jun 19, 2019
  17. PastaPastaPasta referenced this in commit 28bdbcca1a on Jun 20, 2019
  18. PastaPastaPasta referenced this in commit 5842adbb7e on Jun 22, 2019
  19. PastaPastaPasta referenced this in commit 3da4e395d0 on Jun 22, 2019
  20. PastaPastaPasta referenced this in commit d3d97c6b3e on Jun 22, 2019
  21. PastaPastaPasta referenced this in commit fe08077036 on Jun 22, 2019
  22. PastaPastaPasta referenced this in commit 70a7d493c3 on Jun 22, 2019
  23. PastaPastaPasta referenced this in commit 1f81ce12be on Jun 24, 2019
  24. barrystyle referenced this in commit 4c3424de4b on Jan 22, 2020
  25. DrahtBot locked this on Sep 8, 2021


theuni laanwj

Labels
Tests


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-22 03:12 UTC

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