test: Fix intermittent timeout waiting for ibd_wtxid getdata #36599

Manually merged
maflcko merged 1 commit from 2610-test-race-fix-ibd_wtxid into master 2026-10-22 10:50:59 +00:00 AGit
maflcko commented 2026-10-22 07:06:53 +00:00 (Migrated from github.com)

Fix https://github.com/bitcoin/bitcoin/issues/36595

diff to repro:

diff --git a/src/validationinterface.cpp b/src/validationinterface.cpp
index 128f14a6d5..92e1fad22e 100644
--- a/src/validationinterface.cpp
+++ b/src/validationinterface.cpp
@@ -168,2 +168,3 @@ void ValidationSignals::SyncWithValidationInterfaceQueue()
             LOG_EVENT("%s", local_log_msg);                                                                      \
+            UninterruptibleSleep(99ms);\
             local_event();                                                                                       \
Fix https://github.com/bitcoin/bitcoin/issues/36595 diff to repro: ```diff diff --git a/src/validationinterface.cpp b/src/validationinterface.cpp index 128f14a6d5..92e1fad22e 100644 --- a/src/validationinterface.cpp +++ b/src/validationinterface.cpp @@ -168,2 +168,3 @@ void ValidationSignals::SyncWithValidationInterfaceQueue() LOG_EVENT("%s", local_log_msg); \ + UninterruptibleSleep(99ms);\ local_event(); \ ```
DrahtBot commented 2026-10-22 07:07:02 +00:00 (Migrated from github.com)

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

External sites

Reviews

See the guideline and AI policy for information on the review process.

Type Reviewers
ACK Naomi-Gift, mercie-ux

If your review is incorrectly listed, please copy-paste <!--meta-tag:bot-skip--> into the comment that the bot should ignore.

<!--e57a25ab6845829454e8d69fc972939a--> The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. <!--006a51241073e994b41acfe9ec718e94--> ### External sites * Code coverage & benchmarks: https://corecheck.dev/bitcoin/bitcoin/pulls/36599 * Ralph review <img src=https://review.fish.foo/assets/bitcoin/bitcoin/36599.png alt="Ralph review status"> https://git.fish.foo/bitcoin/bitcoin/pulls/36599#author-ralph <!--021abf342d371248e50ceaed478a90ca--> ### Reviews See [the guideline](https://github.com/bitcoin/bitcoin/blob/master/CONTRIBUTING.md#code-review) and [AI policy](https://github.com/bitcoin/bitcoin/blob/master/doc/AI_POLICY.md) for information on the review process. | Type | Reviewers | | ---- | --------- | | ACK | [Naomi-Gift](https://github.com/bitcoin/bitcoin/pull/36599#issuecomment-6336159651), [mercie-ux](https://github.com/bitcoin/bitcoin/pull/36599#issuecomment-6337223638) | If your review is incorrectly listed, please copy-paste <code>&lt;!--meta-tag:bot-skip--&gt;</code> into the comment that the bot should ignore. <!--5faf32d7da4f0f540f40219e4f7537a3-->
First-time contributor

Base: de96f3ae6d163e97a2cf29bbd7c2bf2d56e11019
Head: 7777598f87ea524721cf7dcc61517ca988df61aa

I found no actionable issues in this static review.

Full review report

<!-- forgejo-review-bot:bitcoin/bitcoin --> <!-- ralph-engine:current:0c398e5fd579cb8b00b6b62f2903ad741ac3f867996353a69082cd6ac57373b5:9d9e25a7349f2e108262b6ed44577d47304e975faf1917f1972defa0a828ae3d --> Base: `de96f3ae6d163e97a2cf29bbd7c2bf2d56e11019` Head: `7777598f87ea524721cf7dcc61517ca988df61aa` I found no actionable issues in this static review. [Full review report](<https://review.fish.foo/traces/36599-7777598f87ea524721cf7dcc61517ca988df61aa-1048-1.html>)
Naomi-Gift commented 2026-10-22 08:19:37 +00:00 (Migrated from github.com)

tACK 7777598f87
I applied the 99ms sleep from the description, the old test times out at wait_for_getdata([ibd_wtxid]), the new one passes
Without the sleep, the test passes normally

tACK 7777598f87ea524721cf7dcc61517ca988df61aa I applied the 99ms sleep from the description, the old test times out at wait_for_getdata([ibd_wtxid]), the new one passes Without the sleep, the test passes normally
mercie-ux commented 2026-10-22 09:17:10 +00:00 (Migrated from github.com)
ACK 7777598f87ea524721cf7dcc61517ca988df61aa
fanquake commented 2026-10-22 10:56:48 +00:00 (Migrated from github.com)

Backported to 32.x in #36596.

Backported to `32.x` in #36596.
fanquake commented 2026-10-22 11:00:15 +00:00 (Migrated from github.com)

Backported to 31.x in #36319.

Backported to `31.x` in #36319.
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
bitcoin/bitcoin!36599
No description provided.