Popover button: put its tooltip away even before it has shown #1025

Merged
tiagoagueda merged 1 commit from 1015-escape-race into main 2026-10-20 10:59:18 +00:00
Owner

Refs #917 (follow-up to #1015).

What changed

  • app.js: when a [data-popover] opens, the place of the button that opens it (popovertarget) is marked spent even if its tooltip is not open yet. Before, only a tooltip already open was put away.

Why

The tooltip is placed a frame after the focus arrives. On a loaded runner the Enter that opens the panel came first, so the tooltip showed after the panel and took the first Escape. test_the_keyboard_opens_it_and_escape_closes_it_and_returns_the_focus failed in CI on the browser job (Locator expected to be hidden, popover still visible).

Tests

tests/e2e/test_company_names_popover.py passes locally (3 passed). I could not reproduce the race locally, so only CI under load will show it holds.

Library check

None needed.

🤖 Generated with Claude Code

Refs #917 (follow-up to #1015). ## What changed - `app.js`: when a `[data-popover]` opens, the place of the button that opens it (`popovertarget`) is marked spent even if its tooltip is not open yet. Before, only a tooltip already open was put away. ## Why The tooltip is placed a frame after the focus arrives. On a loaded runner the Enter that opens the panel came first, so the tooltip showed after the panel and took the first Escape. `test_the_keyboard_opens_it_and_escape_closes_it_and_returns_the_focus` failed in CI on the browser job (`Locator expected to be hidden`, popover still visible). ## Tests `tests/e2e/test_company_names_popover.py` passes locally (3 passed). I could not reproduce the race locally, so only CI under load will show it holds. ## Library check None needed. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Put the opening button's tooltip away even when it has not shown yet (#917)
All checks were successful
CI / Unit tests and coverage (Python 3.14) (push) Successful in 12m30s
CI / Database tests on PostgreSQL (push) Successful in 3m43s
CI / Browser tests (Chromium) (push) Successful in 29m16s
CI / Checks: lint, migrations, catalogues, settings, built files (push) Successful in 2m36s
CI / Security audit (push) Successful in 49s
CI / Unit tests and coverage (Python 3.14) (pull_request) Successful in 12m33s
CI / Checks: lint, migrations, catalogues, settings, built files (pull_request) Successful in 2m38s
CI / Database tests on PostgreSQL (pull_request) Successful in 3m46s
CI / Security audit (pull_request) Successful in 59s
CI / Browser tests (Chromium) (pull_request) Successful in 29m16s
Every Python / Unit tests (Python 3.12) (push) Successful in 12m33s
Every Python / Unit tests (Python 3.13) (push) Successful in 12m4s
d4fb70d73d
The tooltip is placed a frame after the focus arrives. A press that follows the focus at
once opens the panel before the tooltip is open, so it showed after the panel and took the
first Escape: the popover test on the company page failed on a loaded runner. The opening
button's place is now spent whether or not its tooltip has shown.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
tiagoagueda deleted branch 1015-escape-race 2026-10-20 10:59:18 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
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
Postulo/postulo!1025
No description provided.