Skip to content

A leg read that git half-fails reads as clean, and a declared leg beneath a directory that cannot be searched reads as absent, so lane-end can end a lane with work left in it #272

Open

Description

@brettheap

Found by lane openRepoTools-3's independent review of #255's fix (finding 4, and the ruling on the writer's doubt "a leg whose parent cannot be searched"). Both are read gaps in lane-worktrees, and both end the same way: the sweep reads the leg as clean or as absent, so it holds nothing back and lane-end can end the lane. The review's short form is on #255, comment 6272494888.

What happens

  1. A leg at mode 0100 (searchable, not listable) reads clean.
  2. A declared leg beneath a directory that cannot be searched reads absent in the sweep.

Where

How it was found

The fix the review proposed

  • Mode 0100: treat git's "could not open directory" warning as a failed read, so the leg is unreadable and counted, as every other failed read is.
  • The unsearchable parent: Python can tell it apart, because os.stat raises PermissionError, so probe_leg can ask os.stat of the leg path before it trusts Leg.exists. The shells (lane-handoff and lane-reconcile, which read legs too) can test the nearest existing ancestor's -x.
  • Add a test at mode 0100, and one with a declared leg path beneath a directory at mode 000.

Test gaps in #271's fold-in

Found by lane 3's re-check of the fold-in round (e678c61..a16e534, comment 6277159862 on #271, which calls them NITs for v1.2.0). They are about the same os.stat path (probe_uninitialized), at a16e534:

  • Mutant N8 survives. N8 is new wording for the os.stat branch. tests/test_triad_lane_tooling.py:777 checks only "read through it (", not the "a directory above it cannot be searched" words set at lane-worktrees:2089.
  • The parent test accepts exit 2 or exit 3 (:772). Where git submodule status itself fails under an unsearchable parent, the sweep refuses to list the dependencies (exit 2) and the os.stat path is never reached, so two mutants would survive: N2 (probe_leg without the stat) and N5 (the stat's failure swallowed). Git 2.43 on Eagle prints -, so the test bites there.

Why it is not in v1.1.0

Filed in milestone v1.2.0 on Brett Heap's word (2026-10-19T18:3xZ, "yes, file the v1.2.0 issues"). It is unclaimed.

Lane: openRepoTools-3

🤖 Generated with Claude Code

Activity

  1. added this to the v1.2.0 milestone on Oct 19, 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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions