Skip to content

Opening deep links on iOS simulator extremely flaky on GitHub Actions #2610

@winghouchan

Description

@winghouchan

Is there an existing issue for this?

  • I have searched the existing issues and didn't find mine.

Steps to reproduce

Using the reproduction repository

See GitHub Action runs in reproduction repository. Note, some runs have had multiple attempts. Maestro logs/screenshots are saved as artifacts labelled with the Maestro, iOS, and Xcode versions. The artifacts will be retained for 30 days from when the flow was run (which at the time of writing, is the same as when this issue was created). If you need the artifacts and they have expired, drop me a message and I'll trigger re-runs.

Each workflow run executes a test which opens a deep link and asserts the correct screen is opened. The variable between each run is the Maestro version: 1.39.0, 1.39.13, 1.40.0, and 1.41.0 have been tested. iOS versions (18.018.5) and Xcode versions (16.3, 16.4) are controlled variables for all runs.

Self-reproduction

  1. Have a flow which opens a deep link. Ensure the app has not been opened before. The reproduction has the following flow:

    name: Open deep link
    appId: com.winghouchan.maestroiosdeeplinkmcve
    tags:
      - subflow
    ---
    - openLink:
        link: com.winghouchan.maestroiosdeeplinkmcve://foo
    
    - runFlow:
        when:
          visible: ".*Open in.*"
        commands:
          - tapOn:
              text: Open
    
    - assertVisible: /foo
  2. Run the tests on GitHub Actions (environment details listed in a later section or see the linked workflow). The reproduction has this workflow: https://github.com/winghouchan/maestro-ios-deep-link-mcve/blob/7fcf4add9080643c65cb9ab79e41f3f2eaf1ab8a/.github/workflows/reproduction.yaml.

Actual results

For Maestro versions 1.40.0 and 1.41.0, the assertion for the expected screen fails the majority of the time as the app doesn't seem to open after the "Open" button in the "Open in..." dialog is pressed.

For Maestro versions 1.39.13 and 1.39.0 (probably versions <=1.39.13 can be included), all steps run as expected.

Expected results

The app is opened at the correct screen by the runner and the assertion passes.

About app

The MCVE app is a React Native (0.79.5) / Expo (53.0.20) app. Source available in the app directory of the reproduction repository. Binary available in the build directory of the reproduction repository.

About environment

Environment is a GitHub-hosted macOS 15 runner. Full details here.

Summary:

  • macOS version: 15.5
  • Processor architecture: arm64
  • Java version: 21
  • Xcode version(s): 16.3, 16.4

Test flow passes as expected when run locally on macOS 15.5 (arm64), Java 21, Xcode 16.4.

Logs

See GitHub Action run artifacts for logs for all runs. A representative log has been attached.

maestro.log

Maestro version

  • 1.40.0
  • 1.41.0
  • 2.0.x

How did you install Maestro?

install script (https://get.maestro.mobile.dev)

Anything else?

No response

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