New M1 shared runner frequently gets stuck when using Fastlane
Summary
We've been using the Gitlab CI shared runners for a few months now, and it was working perfectly before deprecating the intel MacOS runners. Since we migrated to the M1 runners, Fastlane's unit testing action started randomly getting stuck.
Steps to reproduce
It's a bit random, and happens approximately 1 in 5 times the job is run. If the job is restarted, most of the times it works fine. This happens when using Fastlane's run_tests action.
This is the line that gets stuck:
Running Tests: ▸ Touching Tests.xctest (in target 'Tests' from project 'Project')
.gitlab-ci.yml
unit_tests:
stage: test
extends:
- .macos_saas_runners
rules:
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
when: never
- if: '$CI_COMMIT_BRANCH != "main"'
script:
- fastlane unit_tests
interruptible: true
Actual behavior
The job frequently gets stuck in this line:
Running Tests: ▸ Touching Tests.xctest (in target 'Tests' from project 'Project')
Expected behavior
It should start testing as it used to, and should be reliable.
Environment description
M1 MacOS Shared runner (saas-macos-medium-m1
)
Used GitLab Runner version
Running with gitlab-runner 16.2.0~beta.68.gbc92e485 (bc92e485)
on blue-1.saas-macos-medium-m1.runners-manager.gitlab.com/default yixBWUVo, system ID: s_609aff5a2d25
feature flags: FF_USE_IMPROVED_URL_MASKING:true
Possible fixes
This might be related to the simulator not launching properly, or a UI dialog that's blocking the experience.