test: fix intermittent failure in ChainStateManager tests #27348

pull mzumsande wants to merge 1 commits into bitcoin:master from mzumsande:202303_testfix_assumeutxo changing 1 files +4 −1
  1. mzumsande commented at 7:28 PM on March 27, 2023: contributor

    Before wiping a ChainStateManager and creating a new one, the validationinterface queue should be emptied to avoid the possibility of accessing deleted memory. This could lead to very rare CI failures reported in #26613 and #27320 (see here for a more detailed explanation).

    Fixes #27320

  2. DrahtBot commented at 7:28 PM on March 27, 2023: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

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

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK jamesob, 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 Mar 27, 2023
  4. mzumsande force-pushed on Mar 27, 2023
  5. test: Fix intermittent failure in ChainStateManager tests
    Before wiping the ChainStateManager, the validationinterface
    queue must be drained to avoid accessing deleted memory.
    f8abcb3e3b
  6. mzumsande force-pushed on Mar 27, 2023
  7. jamesob commented at 7:49 PM on March 27, 2023: member

    crACK https://github.com/bitcoin/bitcoin/pull/27348/commits/f8abcb3e3b2e731c002ec88f7559c21e26a2c079

    Thank you for fixing this! During actual node restart (which this unittest is trying to model) the validationinterface queue will of course have been flushed, so this change makes the test affected more realistic.

  8. maflcko commented at 7:47 AM on March 28, 2023: member

    lgtm ACK f8abcb3e3b2e731c002ec88f7559c21e26a2c079

  9. fanquake merged this on Mar 28, 2023
  10. fanquake closed this on Mar 28, 2023

  11. sidhujag referenced this in commit 6aa17fe6c3 on Mar 28, 2023
  12. mzumsande deleted the branch on May 4, 2023
  13. Fabcien referenced this in commit 540195703a on Dec 14, 2023
  14. bitcoin locked this on May 3, 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: 2026-04-17 03:13 UTC

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