Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Runner crashes under Xcode 16 #1894

Closed
1 task done
freak4pc opened this issue Aug 6, 2024 · 6 comments
Closed
1 task done

Runner crashes under Xcode 16 #1894

freak4pc opened this issue Aug 6, 2024 · 6 comments
Assignees

Comments

@freak4pc
Copy link

freak4pc commented Aug 6, 2024

Is there an existing issue for this?

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

Steps to reproduce

For me simply having any kind of project with a text input and inputText command reproduces the issue

Actual results

When getting to an input field and trying to use inputText to type, the runner retries a few times and then crashes. This reproduces constantly for us.

image

Expected results

Simply type as it used to in Xcode 15.x

About app

Native. Mix of UIKit and SwiftUI. iOS 16 deployment target.

About environment

Xcode 16.x on any MacBook (macOS Sequoia)

Logs

Logs
Running on iPhone 15 Pro - iOS 17.5 - A5D1F2DB-FE3F-430F-AC14-EB3883AA8A7F

 ║
 ║  > Flow
 ║
 ║    ✅  Launch app "com.monday.monday"
 ║    ⏳  Run ../../actions/login/login.yaml when "Log in" is visible
 ║      ✅  Launch app "com.monday.monday" without stopping app
 ║      ✅  Tap on "Log in"
 ║      ✅  Tap on "Enter your email address"
 ║      ⏳  Input text [email protected]
 ║      🔲 Tap on "Continue with email"
 ║      🔲 Tap on ".*More login options"
 ║      🔲 Tap on "Log in with your password"
 ║      🔲 Tap on "Enter your password"
 ║      🔲 Input text ${MAESTRO_E2E_PASSWORD}
 ║      🔲 Tap on "Log in"
 ║    🔲 Run ../../actions/home/create_new_board.yaml
 ║    🔲 Run ../../actions/board/rename_board.yaml
 ║    🔲 Tap on "item 1"
 ║    🔲 Tap on id: itemMenuButton
 ║    🔲 Tap on "Duplicate.*"
 ║    🔲 Assert that "Item 1 (copy)" is visible
 ║    🔲 Tap on "close"
 ║    🔲 Assert that "Item 1 (copy)" is visible
 ║    🔲 Tap on "item 1"
 ║    🔲 Tap on "item 1"
 ║    🔲 Input text  renamed
 ║    🔲 Tap on "done"
 ║    🔲 Assert that "item 1 renamed" is visible
 ║    🔲 Tap on "close"
 ║    🔲 Assert that "item 1 renamed" is visible
 ║    🔲 Tap on "item 1 renamed"
 ║    🔲 Tap on id: itemMenuButton
 ║    🔲 Tap on "Edit name"
 ║    🔲 Input text  again
 ║    🔲 Tap on "done"
 ║    🔲 Assert that "item 1 renamed again" is visible
 ║    🔲 Tap on "close"
 ║    🔲 Assert that "item 1 renamed again" is visible
 ║    🔲 Tap on id: boardGridActionButton
 ║    🔲 Tap on "New Group"
 ║    🔲 Input text Target group
 ║    🔲 Tap on "Add group"
 ║    🔲 Tap on "item 1 renamed again"
 ║    🔲 Tap on id: itemMenuButton
 ║    🔲 Tap on "Move to group"
 ║    🔲 Tap on "Target group"
 ║    🔲 Tap on "close"
 ║    🔲 Assert that "item 1 renamed again", Below "Target group" is visible
 ║    🔲 Tap on id: navigationAction.back
 ║    🔲 Tap on id: navigationAction.search
 ║    🔲 Input text ${output.boardName.random}
 ║    🔲 Tap on "${output.boardName.random}", Below "${output.boardName.random}"
 ║    🔲 Assert that "item 1 renamed again", Below "Target group" is visible
 ║
ℹ️ Retrying connection to the XCUITest server for 1...
ℹ️ Retrying connection to the XCUITest server for 2...
ℹ️ Retrying connection to the XCUITest server for 3...
ℹ️ Retrying connection to the XCUITest server for 4...
ℹ️ Retrying connection to the XCUITest server for 5...
Error: ⚠️ Error: An unknown network error occurred while communicating with the XCUITest server. If the issue persists, consider raising a GitHub issue with the error message and any available logs for further assistance.
⚠️ Error: An unknown network error occurred while communicating with the XCUITest server. If the issue persists, consider raising a GitHub issue with the error message and any available logs for further assistance.
Error: Request for inputText failed, because of XCUITest server got crashed/exit, body: {"errorMessage":"An unknown network error occurred while communicating with the XCUITest server. If the issue persists, consider raising a GitHub issue with the error message and any available logs for further assistance.","code":"network-error"}
ℹ️ Retrying connection to the XCUITest server for 1...

❌ Error: BlockingCoroutine is cancelling
kotlinx.coroutines.JobCancellationException: BlockingCoroutine is cancelling; job=BlockingCoroutine{Cancelling}@7c0692f4
Caused by: NetworkError(errorResponse=Request for inputText failed, because of XCUITest server got crashed/exit, body: {"errorMessage":"An unknown network error occurred while communicating with the XCUITest server. If the issue persists, consider raising a GitHub issue with the error message and any available logs for further assistance.","code":"network-error"})
	at xcuitest.XCTestDriverClient.handleExceptions(XCTestDriverClient.kt:280)
	at xcuitest.XCTestDriverClient.processResponse(XCTestDriverClient.kt:258)
	at xcuitest.XCTestDriverClient.executeJsonRequest(XCTestDriverClient.kt:240)
	at xcuitest.XCTestDriverClient.inputText(XCTestDriverClient.kt:152)
	at ios.xctest.XCTestIOSDevice$input$1.invoke(XCTestIOSDevice.kt:119)
	at ios.xctest.XCTestIOSDevice$input$1.invoke(XCTestIOSDevice.kt:117)
	at ios.xctest.XCTestIOSDevice.execute(XCTestIOSDevice.kt:227)
	at ios.xctest.XCTestIOSDevice.input(XCTestIOSDevice.kt:117)
	at ios.LocalIOSDevice.input(LocalIOSDevice.kt:82)
	at maestro.drivers.IOSDriver$inputText$1.invoke(IOSDriver.kt:388)
	at maestro.drivers.IOSDriver$inputText$1.invoke(IOSDriver.kt:388)
	at maestro.drivers.IOSDriver.runDeviceCall(IOSDriver.kt:499)
	at maestro.drivers.IOSDriver.inputText(IOSDriver.kt:388)
	at maestro.Maestro.inputText(Maestro.kt:480)
	at maestro.orchestra.Orchestra.inputTextCommand(Orchestra.kt:752)
	at maestro.orchestra.Orchestra.executeCommand(Orchestra.kt:259)
	at maestro.orchestra.Orchestra.executeSubflowCommands(Orchestra.kt:605)
	at maestro.orchestra.Orchestra.runSubFlow(Orchestra.kt:646)
	at maestro.orchestra.Orchestra.runFlowCommand(Orchestra.kt:514)
	at maestro.orchestra.Orchestra.executeCommand(Orchestra.kt:270)
	at maestro.orchestra.Orchestra.executeCommands(Orchestra.kt:201)
	at maestro.orchestra.Orchestra.runFlow(Orchestra.kt:111)
	at maestro.orchestra.Orchestra.runFlow$default(Orchestra.kt:75)
	at maestro.cli.runner.MaestroCommandRunner.runCommands(MaestroCommandRunner.kt:185)
	at maestro.cli.runner.TestRunner$runSingle$result$1.invoke(TestRunner.kt:54)
	at maestro.cli.runner.TestRunner$runSingle$result$1.invoke(TestRunner.kt:51)
	at maestro.cli.runner.TestRunner.runCatching(TestRunner.kt:145)
	at maestro.cli.runner.TestRunner.runSingle(TestRunner.kt:51)
	at maestro.cli.command.TestCommand$handleSessions$1$1$results$1$1$1.invoke(TestCommand.kt:291)
	at maestro.cli.command.TestCommand$handleSessions$1$1$results$1$1$1.invoke(TestCommand.kt:249)
	at maestro.cli.session.MaestroSessionManager.newSession(MaestroSessionManager.kt:106)
	at maestro.cli.session.MaestroSessionManager.newSession$default(MaestroSessionManager.kt:58)
	at maestro.cli.command.TestCommand$handleSessions$1$1$results$1$1.invokeSuspend(TestCommand.kt:249)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
	at kotlinx.coroutines.internal.LimitedDispatcher$Worker.run(LimitedDispatcher.kt:115)
	at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:100)
	at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:584)
	at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:793)
	at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:697)
	at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:684)

Maestro version

1.37.7

How did you install Maestro?

other (please specify in the text area below)

Anything else?

Installed using asdf / mise

@bartekpacia bartekpacia added P1 Important, valid issues at the top of the work list bug Something isn't working platform: ios Testing iOS apps is affected maestro cli Related to the command-line Maestro tool tech debt Corners cut, candidates for refactoring, etc. labels Aug 15, 2024
@yobelioekaharja
Copy link

I also got the exactly the same error using Xcode 13.x

@gagtic
Copy link

gagtic commented Aug 23, 2024

Getting same issue in XCode 15.1

Maestro version: 1.37.9

Log dump

[INFO ] MAESTRO - ---- System Info ----
[INFO ] MAESTRO - Maestro Version: 1.37.9
[INFO ] MAESTRO - CI: Undefined
[INFO ] MAESTRO - OS Name: Mac OS X
[INFO ] MAESTRO - OS Version: 14.1
[INFO ] MAESTRO - Architecture: aarch64
[INFO ] MAESTRO - Java Version: 0
[INFO ] MAESTRO - Xcode Version: 15.1
[INFO ] MAESTRO - Flutter Version: Undefined
[INFO ] MAESTRO - Flutter Channel: Undefined
[INFO ] MAESTRO - ---------------------
[INFO ] xcuitest.XCTestDriverClient - [Start] Uninstalling xctest ui runner app
[INFO ] x.installer.LocalXCTestInstaller - [Start] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Done] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Start] Uninstall XCUITest runner
[INFO ] util.CommandLineUtils - Running command line operation: [xcrun, simctl, uninstall, 866D3CE2-D726-45DF-8FD0-A9284C0A18C0, dev.mobile.maestro-driver-iosUITests.xctrunner]
[INFO ] x.installer.LocalXCTestInstaller - [Done] Uninstall XCUITest runner
[INFO ] xcuitest.XCTestDriverClient - [Done] Uninstalling xctest ui runner app
[INFO ] xcuitest.XCTestDriverClient - [Start] Installing xctest ui runner app
[INFO ] x.installer.LocalXCTestInstaller - [Start] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Done] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Start] Uninstall XCUITest runner
[INFO ] util.CommandLineUtils - Running command line operation: [xcrun, simctl, uninstall, 866D3CE2-D726-45DF-8FD0-A9284C0A18C0, dev.mobile.maestro-driver-iosUITests.xctrunner]
[INFO ] x.installer.LocalXCTestInstaller - [Done] Uninstall XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Start] Install XCUITest runner on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Start] Writing xctest run file
[INFO ] x.installer.LocalXCTestInstaller - [Done] Writing xctest run file
[INFO ] x.installer.LocalXCTestInstaller - Not able to find ui test runner app running, going to install now
[INFO ] x.installer.LocalXCTestInstaller - [Start] Writing maestro-driver-iosUITests-Runner app
[INFO ] x.installer.LocalXCTestInstaller - [Done] Writing maestro-driver-iosUITests-Runner app
[INFO ] x.installer.LocalXCTestInstaller - [Start] Writing maestro-driver-ios app
[INFO ] x.installer.LocalXCTestInstaller - [Done] Writing maestro-driver-ios app
[INFO ] x.installer.LocalXCTestInstaller - [Start] Running XcUITest with xcode build command
[INFO ] util.CommandLineUtils - Running command line operation: [xcodebuild, test-without-building, -xctestrun, /var/folders/2w/rx0jd6x90nd9bqsxwbxmvwww0000gn/T/866D3CE2-D726-45DF-8FD0-A9284C0A18C0/maestro-driver-ios-config.xctestrun, -destination, id=866D3CE2-D726-45DF-8FD0-A9284C0A18C0, -derivedDataPath, /var/folders/2w/rx0jd6x90nd9bqsxwbxmvwww0000gn/T/maestro_xctestrunner_xcodebuild_output3452217944125802786]
[INFO ] x.installer.LocalXCTestInstaller - [Done] Running XcUITest with xcode build command
[INFO ] x.installer.LocalXCTestInstaller - [Done] Install XCUITest runner on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Start] Ensure XCUITest runner is running on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Start] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Done] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Start] Uninstall XCUITest runner
[INFO ] util.CommandLineUtils - Running command line operation: [xcrun, simctl, uninstall, 866D3CE2-D726-45DF-8FD0-A9284C0A18C0, dev.mobile.maestro-driver-iosUITests.xctrunner]
[INFO ] x.installer.LocalXCTestInstaller - [Done] Uninstall XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Failed] Ensure XCUITest runner is running on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Retry] Retrying setup() 0th time
[INFO ] x.installer.LocalXCTestInstaller - [Start] Install XCUITest runner on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Start] Writing xctest run file
[INFO ] x.installer.LocalXCTestInstaller - [Done] Writing xctest run file
[INFO ] x.installer.LocalXCTestInstaller - Not able to find ui test runner app running, going to install now
[INFO ] x.installer.LocalXCTestInstaller - [Start] Writing maestro-driver-iosUITests-Runner app
[INFO ] x.installer.LocalXCTestInstaller - [Done] Writing maestro-driver-iosUITests-Runner app
[INFO ] x.installer.LocalXCTestInstaller - [Start] Writing maestro-driver-ios app
[INFO ] x.installer.LocalXCTestInstaller - [Done] Writing maestro-driver-ios app
[INFO ] x.installer.LocalXCTestInstaller - [Start] Running XcUITest with xcode build command
[INFO ] util.CommandLineUtils - Running command line operation: [xcodebuild, test-without-building, -xctestrun, /var/folders/2w/rx0jd6x90nd9bqsxwbxmvwww0000gn/T/866D3CE2-D726-45DF-8FD0-A9284C0A18C0/maestro-driver-ios-config.xctestrun, -destination, id=866D3CE2-D726-45DF-8FD0-A9284C0A18C0, -derivedDataPath, /var/folders/2w/rx0jd6x90nd9bqsxwbxmvwww0000gn/T/maestro_xctestrunner_xcodebuild_output3399633977470757523]
[INFO ] x.installer.LocalXCTestInstaller - [Done] Running XcUITest with xcode build command
[INFO ] x.installer.LocalXCTestInstaller - [Done] Install XCUITest runner on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Start] Ensure XCUITest runner is running on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Start] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Done] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Start] Uninstall XCUITest runner
[INFO ] util.CommandLineUtils - Running command line operation: [xcrun, simctl, uninstall, 866D3CE2-D726-45DF-8FD0-A9284C0A18C0, dev.mobile.maestro-driver-iosUITests.xctrunner]
[INFO ] x.installer.LocalXCTestInstaller - [Done] Uninstall XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Failed] Ensure XCUITest runner is running on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Retry] Retrying setup() 1th time
[INFO ] x.installer.LocalXCTestInstaller - [Start] Install XCUITest runner on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Start] Writing xctest run file
[INFO ] x.installer.LocalXCTestInstaller - [Done] Writing xctest run file
[INFO ] x.installer.LocalXCTestInstaller - Not able to find ui test runner app running, going to install now
[INFO ] x.installer.LocalXCTestInstaller - [Start] Writing maestro-driver-iosUITests-Runner app
[INFO ] x.installer.LocalXCTestInstaller - [Done] Writing maestro-driver-iosUITests-Runner app
[INFO ] x.installer.LocalXCTestInstaller - [Start] Writing maestro-driver-ios app
[INFO ] x.installer.LocalXCTestInstaller - [Done] Writing maestro-driver-ios app
[INFO ] x.installer.LocalXCTestInstaller - [Start] Running XcUITest with xcode build command
[INFO ] util.CommandLineUtils - Running command line operation: [xcodebuild, test-without-building, -xctestrun, /var/folders/2w/rx0jd6x90nd9bqsxwbxmvwww0000gn/T/866D3CE2-D726-45DF-8FD0-A9284C0A18C0/maestro-driver-ios-config.xctestrun, -destination, id=866D3CE2-D726-45DF-8FD0-A9284C0A18C0, -derivedDataPath, /var/folders/2w/rx0jd6x90nd9bqsxwbxmvwww0000gn/T/maestro_xctestrunner_xcodebuild_output5620819362246648276]
[INFO ] x.installer.LocalXCTestInstaller - [Done] Running XcUITest with xcode build command
[INFO ] x.installer.LocalXCTestInstaller - [Done] Install XCUITest runner on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Start] Ensure XCUITest runner is running on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Start] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Done] Stop XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Start] Uninstall XCUITest runner
[INFO ] util.CommandLineUtils - Running command line operation: [xcrun, simctl, uninstall, 866D3CE2-D726-45DF-8FD0-A9284C0A18C0, dev.mobile.maestro-driver-iosUITests.xctrunner]
[INFO ] x.installer.LocalXCTestInstaller - [Done] Uninstall XCUITest runner
[INFO ] x.installer.LocalXCTestInstaller - [Failed] Ensure XCUITest runner is running on 866D3CE2-D726-45DF-8FD0-A9284C0A18C0
[INFO ] x.installer.LocalXCTestInstaller - [Retry] Retrying setup() 2th time

@bartekpacia
Copy link
Member

Hey, I tried to reproduce this on Xcode 16 Beta 6 and iOS simulator with iOS 18, and didn't manage to.

I ran: maestro test e2e/workspaces/demo_app/fill_form.yaml.

Please share more information so we can reproduce the issue.

@bartekpacia bartekpacia added waiting for customer response More information is needed from the customer before we can progress on the issue and removed bug Something isn't working platform: ios Testing iOS apps is affected maestro cli Related to the command-line Maestro tool P1 Important, valid issues at the top of the work list tech debt Corners cut, candidates for refactoring, etc. labels Sep 2, 2024
@freak4pc
Copy link
Author

freak4pc commented Sep 2, 2024

This seems solved for us in beta 6.
Thanks !

@github-actions github-actions bot removed the waiting for customer response More information is needed from the customer before we can progress on the issue label Sep 2, 2024
@freak4pc freak4pc closed this as completed Sep 2, 2024
@bartekpacia
Copy link
Member

That's great to hear, thanks!

Copy link

github-actions bot commented Sep 9, 2024

This issue has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar problem, please file a new issue. Make sure to follow the template and provide all the information necessary to reproduce the issue.
Thank you for helping keep us our issue tracker clean!

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 9, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants