Zyshan Noor
Zyshan Noor

Reputation: 43

Y appium restarts application in a loop in ios simulator?

I tried to run test ipa. But appium restarts the app in a loop and produces this error.

[INST STDERR] Instruments Trace Error : Target failed to run: Failed looking up pid of launched process

What should I do to diagnose the root cause and solve the issue?

Upvotes: 4

Views: 2274

Answers (3)

firebear
firebear

Reputation: 774

I got the same error message in the simulator because I had not build the project with arguments for simulator. I solved my problem by building as following


xcodebuild -sdk iphonesimulator8.4 \
    -workspace MyApp.xcworkspace \
    -scheme Dobby \
    ONLY_ACTIVE_ARCH=NO \
    TARGETED_DEVICE_FAMILY=1 \
    DEPLOYMENT_LOCATION=YES \
    DSTROOT=$(WorkPath)/appium

Upvotes: 0

Kaey
Kaey

Reputation: 4645

Inside your Xcode>Derived Date>build>products, You will have folders as shown. Each will have the respective builds generated. Build for the device might not work for a simulator.

Be very choosy here ;)

enter image description here

Upvotes: 4

Acludia
Acludia

Reputation: 344

The specific build of the app you are trying to run on the simulator is not built for x86 arch. iOS on device runs on ArmV7, so when a build that is intended for a physical device tries to run on the simulator it will fail. You can see evidence of this in one of the errors printed out in your log

info: [IOS_SYSLOG_ROW ] Mar  9 10:21:51 Arslans-Mac-mini  
com.apple.CoreSimulator.SimDevice.BFF4C60D-DF35-4ACB-B989-
A8CA8F43139E.launchd_sim[6333 
(UIKitApplication:com.vizteck.Testing123[0x1249][6382]): Program specied by
service does not contain one of the requested architectures:

Upvotes: 2

Related Questions