Skip to content

just check is red at main: pty-gate reports five ungated live-spawn sites (and the gate never runs in CI) #3095

Closed

Description

@Xuepoo

Summary

just check is red at main HEAD (9db82bb9, verified 2026-11-09) because pty-gate (scripts/check-pty-gated-tests.sh) reports five UNGATED live-spawn markers. The gate is part of the check recipe (justfile:626) but is not referenced by any workflow under .github/workflows/, so CI stays green while the documented local pre-push gate cannot be made green — every lane either reports a false red or skips just check.

Evidence

$ cd bitty && bash scripts/check-pty-gated-tests.sh
UNGATED live-spawn marker in crates/bitty-runtime/src/runtime/panes.rs:1511:         rt.spawn_shell_with_args(
UNGATED live-spawn marker in crates/bitty-runtime/tests/spawn_pane_cwd.rs:342:         rt.spawn_shell_with_args(
UNGATED live-spawn marker in crates/bitty-daemon/src/service/dispatch.rs:5812:         std::fs::write(&program, b"#!/bin/sh\nexit 0\n").expect("write the fixture");
UNGATED live-spawn marker in crates/bitty-daemon/src/worker.rs:1378:         std::fs::write(&program, b"#!/bin/sh\nexit 0\n").expect("write the fixture");
UNGATED live-spawn marker in crates/bitty-daemon/tests/service_loop.rs:3486:     std::fs::write(&program, b"#!/bin/sh\nexit 0\n").expect("write the fixture");
FAIL: ungated live-spawn test code (see above).

All five are inside #[test] code and are genuine live-spawn sites, so the gate is not producing false positives:

  • panes.rs:1511 / spawn_pane_cwd.rs:342 spawn a real sh -c child through Runtime::spawn_shell_with_args to pin the child cwd.
  • dispatch.rs:5812, worker.rs:1378, service_loop.rs:3486 write an executable #!/bin/sh fixture program and then drive a worker/session through it.

Why it matters

The owner host rule is "local CI pre-validation is mandatory before any bitty PR push: just ci-local", and just check is the cheap gate lanes run first. A permanently red pty-gate teaches lanes to ignore that step, which is exactly how a real ungated spawn would reach windows-latest.

Fix direction (one of, per site)

  1. require_pty!() at the top of the test (preferred for tests that spawn a real shell), or
  2. #[cfg(unix)] on the test item for POSIX-program tests, or
  3. an audited // pty-gate-exempt: <reason> directive where the fixture is never executed on a non-PTY host.

Also decide whether pty-gate should run in CI (Quality gates): if the gate only runs locally, nothing enforces it, which is how the five sites accumulated.

Activity

  1. added
    fix
    area:runtime
    P2
    on Nov 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2area:runtimefix

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions