GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — iOS testbed runner prone to failure when two instances start near the same time · Issue #129200 · python/cpython

iOS testbed runner prone to failure when two instances start near the same time #129200

New issue
Copy link
New issue
Copy link
Closed
python/buildmaster-config
#573
python/buildmaster-config#573
Closed
iOS testbed runner prone to failure when two instances start near the same time#129200
python/buildmaster-config
#573
Copy link
Labels
OS-iostype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error

Description

@freakboy3742
freakboy3742
opened on Jan 22, 2025
Issue body actions

Bug report

Bug description:

The iOS testbed runner starts an iOS simulator; however, the mechanism that starts the simulator doesn't return the ID of the simulator that was started. The runner needs to know the ID of the simulator that was started so that future commands can be directed at that simulator.

The current implementation of the testbed finds this ID by generating a list of know simulators, and then waiting until another entry appears. This works fine until there are 2 test runs started at near the same time, and the runner is unable to identify which simulator this test run has started. This results in test failures like the following:

note: Run script build phase 'Prepare Python Binary Modules' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'iOSTestbed' from project 'iOSTestbed')
note: Run script build phase 'Install Target Specific Python Standard Library' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'iOSTestbed' from project 'iOSTestbed')
Found more than one new device: {'5CAA0336-9CE1-4222-BFE3-ADA405F766DE', 'DD108383-685A-4400-BF30-013AA82C4A61'}
make: *** [testios] Error 1
program finished with exit code 2

A re-run of the same test job will usually fix the problem, but it shouldn't happen in the first place.

This almost never happens locally, because users don't normally start to test runs in parallel. However, it's a set of conditions that is reasonably likely on the CI machine, as it's very easy for a PR and a main CI job to start at the same time (most commonly, when you merge a PR and immediately backport to a previous release).

CPython versions tested on:

3.13

Operating systems tested on:

macOS, Other

Linked PRs

  • gh-129200: Add locking to the iOS testbed startup sequence. #130564
  • [3.13] gh-129200: Add locking to the iOS testbed startup sequence. (GH-130564) #130657

Activity

  1. freakboy3742
    added
    OS-ios
    type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
    on Jan 22, 2025
  2. freakboy3742 commented on Jan 22, 2025

    @freakboy3742
    freakboy3742
    on Jan 22, 2025
    ContributorAuthor
    More actions

    python/buildmaster-config#573 should be an immediate workaround to avoid the error in CI.

  3. vstinner
    closed this as completedin buildmaster-config#573on Jan 23, 2025
  4. freakboy3742 commented on Feb 26, 2025

    @freakboy3742
    freakboy3742
    on Feb 26, 2025
    ContributorAuthor
    More actions

    I'm going to re-open this; it's going to be a problem for other users who want to use the testbed in CI configurations, as it doesn't play nicely with pytest-xdist. Parallelized test runs can cause multiple iOS tests to run, triggering this issue.

    It would also be desirable to increase the parallelization on the iOS worker as well - the CPU is able to handle the load, it's purely the startup ordering sequence that is an issue.

  5. freakboy3742
    reopened this on Feb 26, 2025
  6. freakboy3742
    added a commit that references this issue on Feb 27, 2025

    gh-129200: Add locking to the iOS testbed startup sequence. (#130564)

    9211b3d
  7. miss-islington
    added a commit that references this issue on Feb 27, 2025

    pythongh-129200: Add locking to the iOS testbed startup sequence. (py…

    46e4066
  8. freakboy3742
    added a commit that references this issue on Feb 28, 2025

    [3.13] gh-129200: Add locking to the iOS testbed startup sequence. (G…

    797aac7
  9. freakboy3742
    closed this as completedon Feb 28, 2025
  10. freakboy3742
    added a commit that references this issue on Feb 28, 2025

    Restore use of parallel workers for iOS.

    8799b08
  11. zware
    added a commit that references this issue on Feb 28, 2025

    Restore use of parallel workers for iOS. (#581)

    c1892be
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

    OS-iostype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.