Skip to content

test(tiers): XdistSubprocessTests checks for a leftover probe before taking the lock #1758

Closed

Description

@JarryShaw

Describe the bug
tests/test_tier_guard_xdist.py: XdistSubprocessTests.setUp checks probe_path.exists() at lines 176-179 before it takes the exclusive _tier_guard_lock at line 189.

Under --dist load, the class's two tests can land on different workers. One of them can then see the other's live probe and fail with "already exists — a previous run did not clean up", even though nothing went wrong.

#1757 adds a third writer of the same probe file, ProbeWorkerCrashTests. That class checks only after taking the lock.

Expected behavior
The existence check runs under the lock, so a concurrent probe is waited for, not reported as a leftover.

Additional context

Activity

  1. added
    testPull requests that add or correct tests (test: subject prefix)
    pendingAccepted and unstarted - nobody is on it and nothing blocks it
    on Oct 15, 2026
  2. moved this to Pending in PyPCAPKiton Oct 15, 2026
  3. JarryShaw commented on Oct 15, 2026

    @JarryShaw
    OwnerAuthor

    A worker is on this, stacked on #1757's branch because both edit tests/test_tier_guard_xdist.py. Its PR opens once #1757 merges.

  4. added
    wipWork in flight - a covering PR is open or an agent is actively on it
    and removed
    pendingAccepted and unstarted - nobody is on it and nothing blocks it
    on Oct 15, 2026
  5. moved this from Pending to WIP in PyPCAPKiton Oct 15, 2026
  6. removed
    wipWork in flight - a covering PR is open or an agent is actively on it
    on Oct 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

    testPull requests that add or correct tests (test: subject prefix)

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions