Skip to content

Testing: two suites at once break the shell suite, and the guard every brief used never waited — document the serialization and ship a wrapper that takes a lock #51

Closed

Description

@brettheap

Measured 2026-09-14T20:4xZ on Eagle (lane openRepoTools-3). Four python3 -m pytest tests -q runs were live at once in four worktrees, every one past a guard that read:

while pgrep -af 'python3 -m pytest' | grep -v pgrep >/dev/null; do sleep 20; done

It never waits under Claude Code: grep there is a shell function from the harness's zsh snapshot, and with stdout redirected to /dev/null it returns 1 even when it matched (the same pipeline captured into a variable: rc=0, 6 lines). command grep returns 0.

What breaks. AGENTS.md says the shell suite (tests/test_lane_helpers.sh through tests/test_lane_helpers_suite.py) redirects $HOME and $TMPDIR, so the collision is not a shared path; it is time — a suite that takes 18 minutes alone takes far longer four-wide and trips the wrapper's timeouts (the memory rule 'never two pytest suites at once in this repo' came from exactly that).

Ask.

  1. AGENTS.md, 'Testing your changes': say the suite is serialized on this workstation and give the guard that works: pat='^python3 -m pyt'"est"; while [ "$(pgrep -fc "$pat")" -gt 0 ]; do sleep 20; done; flock /tmp/claude-1000/openrepotools-pytest.lock python3 -m pytest tests -q — anchored so only real pytest processes count, split so it cannot match its own command line, then flock so waiters cannot all start together. Note command grep wherever an exit status matters.
  2. A tests/run.sh (or Make target) that takes that lock and runs the suite, so a writer types one thing; the lock path from $TMPDIR//tmp with the uid, portable to macOS (flock is absent there — fall back to mkdir as the lock).
  3. The top block template of Amendment 17 tooling: lane-handoff + /handoff (swap kept as alias), PAUSED gains agent + transcript, lane-start --agent <name> resumes a lane from the handoff with any agent #36 (/ctx, lane-handoff) writes the working guard, never the old one.

Lane: openRepoTools-3.

Activity

  1. brettheap commented on Sep 14, 2026

    @brettheap
    ContributorAuthor

    CLAIMED — lane openRepoTools-3, session 4135b2c9-34a6-47e3-a156-5adebb632fae@Eagle, 2026-09-14T20:38:20Z, for #51

    Logged in lanes/log/openRepoTools-3.md at 3f092bd54387e9dc1f1e604e690547fec59c8844.

    The three reads (lane-collision-protocol Rule 1):

    1. existing `CLAIMED —` comments on opensoft/openRepoTools#51:
       none
    2. `gh pr list --repo opensoft/openRepoTools --state all --search "#51"`, kept where the row or its body names `#51`:
       none
    3. `git ls-remote --heads [email protected]:opensoft/openRepoTools` branches naming `51` as a whole token:
       none
    
  2. added 3 commits that reference this issue on Sep 15, 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

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions