Skip to content

Fix the macOS CI flake in TwoCellsTest by setting a short TMPDIR - #75

Merged
flavorjones merged 1 commit into
masterfrom
issue-27-twocells-sun-path
Sep 29, 2026
Merged

flavorjones merged 1 commit into
masterfrom
issue-27-twocells-sun-path

Conversation

@flavorjones

@flavorjones flavorjones commented Sep 28, 2026 •

Copy link
Copy Markdown
Member

Motivation

TwoCellsTest failed intermittently on the macOS CI job:

RuntimeError: the cell did not boot: HotCell::ConfigurationError:
/var/folders/df/djsxfhc17x95674wsm_g8s980000gn/T/hotcell-test20260824-13358-d0nrot/documents/control.sock
is 105 bytes and a Unix socket path on this platform holds 104. Choose a shorter directory.

HotCell::TestCell creates its directory under Dir.tmpdir (test_cell.rb), and the supervisor refuses to boot when a socket path is longer than the platform allows (supervisor.rb). On macOS, the per-user TMPDIR is 48 bytes, so the path crossed 104 bytes whenever the test process's pid had five digits.

Fixes #27

Details

  • The macOS job sets TMPDIR to /tmp. The socket path above becomes 61 bytes.
  • The HotCell::TestCell comment says a macOS suite needs a short TMPDIR, for applications that use it in their own tests.

Copilot AI balanced review requested due to automatic review settings September 28, 2026 21:28

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.

`TwoCellsTest` flaked on the macOS job. The per-user `TMPDIR` is about
48 bytes, and a `HotCell::TestCell` socket path beneath it reached 105
bytes, over macOS's 104, whenever the test process's pid had five
digits.

Set `TMPDIR` to `/tmp` on the macOS job, and say in the `TestCell`
comment that a macOS suite needs a short `TMPDIR`.

[Fix #27]
@flavorjones
flavorjones force-pushed the issue-27-twocells-sun-path branch from 948b9a3 to c32c4f4 Compare September 29, 2026 14:44
@flavorjones flavorjones changed the title Fix HotCell::TestCell failing to boot on macOS when the temp path is long Fix the macOS CI flake in TwoCellsTest by setting a short TMPDIR Sep 29, 2026
@flavorjones
flavorjones merged commit 715602b into master Sep 29, 2026
16 checks passed
@flavorjones
flavorjones deleted the issue-27-twocells-sun-path branch September 29, 2026 14:59
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.

TwoCellsTest flakes on macOS when the temp path crosses SUN_PATH_MAX

2 participants