Skip to content

CI: run macOS tests on macos-15 (work around Local Network Privacy) - #531

Merged
keepsimple1 merged 1 commit into
mainfrom
fix/macos15-ci-tests
Oct 24, 2026
Merged

keepsimple1 merged 1 commit into
mainfrom
fix/macos15-ci-tests

Conversation

@keepsimple1

@keepsimple1 keepsimple1 commented Oct 24, 2026 •

Copy link
Copy Markdown
Owner

macos-14 runners are retired on 2026-11-02 (actions/runner-images#13518). On macos-15, 10 daemon unit tests fail and test_hostname_resolution_address_removed hangs (seen in #530).

Root cause

macOS 15 Local Network Privacy (Apple TN3179). The cargo test binary is an unsigned, linker-signed a.out with no LNP grant, so macOS blocks its traffic on LAN interfaces:

  • every send on en0 fails with No route to host (os error 65) (EHOSTUNREACH). Sends on lo0 still work.
  • the system log shows Got local network blocked notification ... bundle_id: (null) / found bundle id a.out by PID.

All the failing tests pin a service to the first non-loopback IPv4 address (my_ip_interfaces(false)), so they need multicast on en0. The tests that pass resolve over lo0.

Fix

  • Move the matrix from macos-14 to macos-15. Rust stays at 1.71.0.
  • On the macOS test steps, set CARGO_TARGET_AARCH64_APPLE_DARWIN_RUNNER="sudo -E". Cargo still builds as the runner user but runs the test binaries as root, and root is exempt from LNP. This keeps full test coverage, with no skipping.
  • test_hostname_resolution_address_removed: replace the unbounded recv() with recv_timeout(5s), so the test fails instead of hanging when the hostname is never resolved.

🤖 Generated with Claude Code

macos-14 runners are retired on 2026-11-02. On macos-15, Local Network
Privacy blocks the unsigned test binaries from sending on en0 (sendto
returns EHOSTUNREACH), so every test that pins a service to a LAN address
fails. Processes running as root are exempt, so run the test binaries
through 'sudo -E' via the cargo target runner.

Also bound the initial wait in test_hostname_resolution_address_removed so
it fails instead of hanging when the hostname is never resolved.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@keepsimple1
keepsimple1 marked this pull request as ready for review October 24, 2026 03:45
@keepsimple1
keepsimple1 merged commit 1b84730 into main Oct 24, 2026
4 checks passed
@keepsimple1
keepsimple1 deleted the fix/macos15-ci-tests branch October 24, 2026 03:49
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.

1 participant