The app crashes after it is installed using Appium

Hi,
I have xamarin native application that can be installed on a real iPhone 13 manually and using the Xcode / ideviceinstaller, and run without a problem.

When I run appium script, with app capability , the application is installed, starts, and crashed immediately.
When I try after the automation to enter the installed app, it crashed.

I don’t understand it, especially since it looks that the application working fine while I’m installing it by myself. The application is start on the iPhone when I’m running the automation without the app path, when I install it manually before running the automation.

Can you help me with it?

Many thanks!

More Details:

Device:
macOS 13

[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]

iPhone: 13
WDA is installed and working on the device.

Logs:
appium-server-logs-1201.txt (10.7 KB)

Appium capabilities (as I explained, with or without the ‘app’ path):
{“appium_server”: "http://localhost:4723/wd/hub",
“platformName”: “iOS”,
“deviceName”: “iPhone”,
“platformVersion”: ‘16.1’,
“app”: ‘/Users/automobile/Downloads/F1MobileiOS-3.ipa’,
“autoAcceptAlerts”: True,
“udid”: ‘00008110-001138182668401E’,
“bundleId”: ‘com.SCR.F1.iOS’,
“xcodeSignId”: ‘iPhone Developer’,
“xcodeOrgId”: ‘com.automob.WebDriverAgentRunner-Runner’
}

iOS 16 indicates you are probably using Xcode 14 or better. I recommend Appium 2 for this scenario:

https://www.headspin.io/blog/installing-appium-2-0-and-the-driver-and-plugins-cli

@wreed Thanks,

I checked the installed appium using the terminal and I got “2.0.0-beta.52”.
I re run the server using the command appium --base-path /wd/hub

The result is the same as before, the application crash immediately after trying to launch.

The new server logs:
appium_2_terminal.txt (13.2 KB)

Update:
I tried this solution- Xcode build works but appium hangs at splash screen
“appium:wdaStartupRetries”: 4,
“appium:wdaLaunchTimeout”: 120000

It’s not help to solve the issue.
Thanks

Maybe the application itself is not compatible with accessibility services? Have you tried to run a basic UI xctest on it? Does it work with, for example, VoiceOver?

Also, consider checking device logs. They might contain more info about possible issues

1 Like

Yeah, I would get my dev team to tell me why the app is crashing first. You might have found an environmental issue your app has that could bite your users later on. You can also try using ideviceinstaller library as a way to eliminate appium install logic being the cause?

@mykola-mokhnach yes, it works. I also tried with Simulator and it works.
@Conrad_Braam we open the console logs with the developers, it also looks like the app was installed successfully.
As I mentioned, ideviceinstaller install it and the app is open, so probably is something with the appium install.

waiting for reply
thanks both

there is appium:appInstallStrategy capability, which allows to use an alternative installer. You may check if it changes anything.

Also, have you tried to check device logs?

1 Like

I investigate this solution, the key with the value ios-deploy helped to solve it.
Now I will try to see if it worth it, because the installation takes a lot of time using that way (parallel option is also lead to the crashes).

Many thanks!