Skip to content

ci: run the real fzf-tab preview case on macOS - #7

Merged
FridrichMethod merged 3 commits into
mainfrom
ci/fzf-tab-preview
Oct 21, 2026
Merged

FridrichMethod merged 3 commits into
mainfrom
ci/fzf-tab-preview

Conversation

@FridrichMethod

@FridrichMethod FridrichMethod commented Oct 21, 2026 •

Copy link
Copy Markdown
Owner

What

#5's real fzf-tab preview case (test_real_fzf_tab_previews_accounts_through_the_kit) skipped in every CI job, because no job had an fzf-tab checkout. The ubuntu-24.04 runner has no zsh, so the hermetic preview case skips there too; macOS runs it.

  • The macOS job clones fzf-tab from its config/bootstrap/git-clones.tsv row (URL and default branch, as the bootstrap clones it) into the runner's temp directory and exports FZF_TAB_TEST_DIR.
  • The real case now keeps the caller's PATH behind the launchers, as every other case does. It used to pin /usr/bin:/bin, and a macOS runner's /usr/bin/python3 is older than the 3.11 the kit launchers need.
  • docs/testing.md and COVERAGE say where each preview case runs.

A macOS hang, fixed in commit 2

The first CI run of this PR timed out after 20 minutes on macOS inside the real case, and a Python process of its session was left over. Linux never hangs there.

The test used to kill zsh and wait for it before closing the pty master. On macOS and the BSDs, the last close of a terminal with unread output can wait for that output to drain, and nothing was left to read it. That is the likely cause; I could not confirm it without a Mac.

test: end the real fzf-tab case's terminal session without blocking:

  • kills the session's process group, closes the terminal, then waits;
  • a SIGALRM bound turns any remaining hang into a TimeoutError with its traceback. It is an alarm, not a watchdog thread, because forking a multi-threaded process can deadlock the child;
  • a failure message shows what the terminal printed.

The second run is green on all three OSes, and the macOS job reports test_real_fzf_tab_previews_accounts_through_the_kit ... ok.

Verified

  • The step's script under /bin/bash -eo pipefail cloned fzf-tab master (24105b1) and wrote the variable.
  • In the lab, the real case passes against that clone and against this machine's cbdc582.
  • tests/run.sh --ci, the pwsh suites (except the lab's known long-TMPDIR case) and pre-commit run --all-files pass.
  • macOS is not available here: this PR's macOS job is the first run of the case on macOS.

Tradeoff

CI follows fzf-tab's default branch, as every host does, rather than a pinned commit. An upstream change that breaks the preview would turn macOS CI red, and it would be breaking hosts at the same time.

The macOS job clones fzf-tab from its config/bootstrap/git-clones.tsv row,
as the bootstrap does, and sets FZF_TAB_TEST_DIR, so the real fzf-tab
preview case of test_ai_integration runs there instead of skipping; the
ubuntu-24.04 runner has no zsh. The case now keeps the caller's PATH behind
the launchers, as every other case does: /usr/bin has no Python 3.11 on a
macOS runner.
On macOS CI the real fzf-tab case hung until the job's 20-minute timeout,
with a Python process of the session left over; Linux never hangs here.
The test killed zsh and waited for it before closing the terminal, so a
last close that waits for unread output to drain, as on macOS and the
BSDs, would wait on a reader that never comes. It now kills the session's
process group, closes the terminal, then waits. An alarm (not a watchdog
thread, since forking a multi-threaded process can deadlock the child)
turns any remaining hang into a TimeoutError with its traceback, and a
failure shows what the terminal printed.
@FridrichMethod
FridrichMethod marked this pull request as ready for review October 21, 2026 18:30
Copilot AI balanced review requested due to automatic review settings October 21, 2026 18:30
@FridrichMethod
FridrichMethod merged commit c8e59c0 into main Oct 21, 2026
3 checks passed
@FridrichMethod
FridrichMethod deleted the ci/fzf-tab-preview branch October 21, 2026 18:30

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants