Skip to content

gh-69134: Wait until mapped in SimpleDialog keyboard tests#152690

Merged
serhiy-storchaka merged 1 commit into
python:mainfrom
serhiy-storchaka:gh-69134-map-simpledialog-tests
Jul 5, 2026
Merged

gh-69134: Wait until mapped in SimpleDialog keyboard tests#152690
serhiy-storchaka merged 1 commit into
python:mainfrom
serhiy-storchaka:gh-69134-map-simpledialog-tests

Conversation

@serhiy-storchaka

@serhiy-storchaka serhiy-storchaka commented Jun 30, 2026

Copy link
Copy Markdown
Member

The SimpleDialog tests generate key events after focus_force(). On Windows these are only delivered once the toplevel is mapped, so they could be dropped and the test fail intermittently — seen on the AMD64 Windows10 buildbot, where test_return_no_default failed on the first run and passed on the re-run.

Unlike the query dialogs (whose __init__ calls wait_visibility()), SimpleDialog only waits for its window in go(), which these tests bypass. Wait until the window is mapped in the create() helper, as GH-152599 did for the other keyboard tests.

The SimpleDialog keyboard tests generate key events after focus_force(),
which on Windows are dropped until the toplevel is mapped, so they could
fail intermittently (seen on the Windows10 buildbot as
test_return_no_default).  Wait until the window is mapped in each of
these tests, as pythonGH-152599 did for the other keyboard tests.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@serhiy-storchaka serhiy-storchaka force-pushed the gh-69134-map-simpledialog-tests branch from 99cf022 to 1b5a7b2 Compare June 30, 2026 16:06
@serhiy-storchaka serhiy-storchaka added the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Jun 30, 2026
@bedevere-bot

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @serhiy-storchaka for commit 1b5a7b2 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F152690%2Fmerge

If you want to schedule another build, you need to add the 🔨 test-with-buildbots label again.

@bedevere-bot bedevere-bot removed the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Jun 30, 2026
@serhiy-storchaka serhiy-storchaka merged commit 7d619c2 into python:main Jul 5, 2026
140 of 145 checks passed
@serhiy-storchaka serhiy-storchaka deleted the gh-69134-map-simpledialog-tests branch July 5, 2026 10:51
@serhiy-storchaka serhiy-storchaka added needs backport to 3.13 bugs and security fixes needs backport to 3.14 bugs and security fixes needs backport to 3.15 pre-release feature fixes, bugs and security fixes labels Jul 5, 2026
@miss-islington-app

Copy link
Copy Markdown

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.14.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.15.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.13 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 7d619c2fea131722d0bfdad150c081c44cc0abd7 3.13

@miss-islington-app

Copy link
Copy Markdown

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.14 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 7d619c2fea131722d0bfdad150c081c44cc0abd7 3.14

@miss-islington-app

Copy link
Copy Markdown

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.15 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 7d619c2fea131722d0bfdad150c081c44cc0abd7 3.15

@bedevere-app

bedevere-app Bot commented Jul 5, 2026

Copy link
Copy Markdown

GH-153104 is a backport of this pull request to the 3.15 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 pre-release feature fixes, bugs and security fixes label Jul 5, 2026
@bedevere-app

bedevere-app Bot commented Jul 5, 2026

Copy link
Copy Markdown

GH-153105 is a backport of this pull request to the 3.14 branch.

@bedevere-app

bedevere-app Bot commented Jul 5, 2026

Copy link
Copy Markdown

GH-153106 is a backport of this pull request to the 3.13 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.13 bugs and security fixes label Jul 5, 2026
serhiy-storchaka added a commit that referenced this pull request Jul 5, 2026
…-152690) (GH-153106)

The SimpleDialog keyboard tests generate key events after focus_force(),
which on Windows are dropped until the toplevel is mapped, so they could
fail intermittently (seen on the Windows10 buildbot as
test_return_no_default).  Wait until the window is mapped in these tests,
as GH-152599 did for the other keyboard tests.

(cherry picked from commit 7d619c2)

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
serhiy-storchaka added a commit that referenced this pull request Jul 5, 2026
…-152690) (GH-153105)

The SimpleDialog keyboard tests generate key events after focus_force(),
which on Windows are dropped until the toplevel is mapped, so they could
fail intermittently (seen on the Windows10 buildbot as
test_return_no_default).  Wait until the window is mapped in these tests,
as GH-152599 did for the other keyboard tests.

(cherry picked from commit 7d619c2)

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
serhiy-storchaka added a commit that referenced this pull request Jul 5, 2026
…-152690) (GH-153104)

The SimpleDialog keyboard tests generate key events after focus_force(),
which on Windows are dropped until the toplevel is mapped, so they could
fail intermittently (seen on the Windows10 buildbot as
test_return_no_default).  Wait until the window is mapped in these tests,
as GH-152599 did for the other keyboard tests.

(cherry picked from commit 7d619c2)

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip news tests Tests in the Lib/test dir

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants