Unable to launch ios simulator on xcode 7 and appium 1.4.13

Appium - 1.4.13v
Xcode - 7.1
iOS simulator - 9.1

When I try to launch an iOS simulator. I am getting the following error.

info: [debug] Attempting to run app on iPhone 6 (9.1) [

info: [debug] Spawning instruments with command: /Applications/Xcode.app/Contents/Developer/usr/bin/instruments -t /Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/PlugIns/AutomationInstrument.xrplugin/Contents/Resources/Automation.tracetemplate -D /tmp/appium-instruments/instrumentscli0.trace -w “iPhone 6 (9.1) [” “/var/folders/7g/_4s8f5kx4cs1875_psp3rps00000gn/T/115927-1878-r7masd/QA Beta.app” -e UIASCRIPT “/Users/user/Library/Application Support/appium/bootstrap/bootstrap-f062718992d59810.js” -e UIARESULTSPATH /tmp/appium-instruments
info: [debug] And extra without-delay env: {“DYLD_INSERT_LIBRARIES”:"/Applications/Appium.app/Contents/Resources/node_modules/appium/submodules/appium-instruments/thirdparty/iwd7/InstrumentsShim.dylib",“LIB_PATH”:"/Applications/Appium.app/Contents/Resources/node_modules/appium/submodules/appium-instruments/thirdparty/iwd7"}
info: [debug] And launch timeouts (in ms): {“global”:90000}
info: [debug] [INST STDERR] dyld: could not load inserted library ‘/Applications/Appium.app/Contents/Resources/node_modules/appium/submodules/appium-instruments/thirdparty/iwd7/InstrumentsShim.dylib’ because no suitable image found. Did find:
/Applic
info: [debug] [INST STDERR] ations/Appium.app/Contents/Resources/node_modules/appium/submodules/appium-instruments/thirdparty/iwd7/InstrumentsShim.dylib: mmap() error 1 at address=0x103FC0000, size=0x00001000 segment=__TEXT in Segment::map() mapping /Applications/Appium.app/Contents/Resources/node_modules/appium/submodules/appium-instruments/thirdparty/iwd7/InstrumentsShim.dylib

info: [debug] [INSTSERVER] Instruments exited with code null

info: [debug] Killall instruments
info: [debug] Instruments crashed on startup
info: [debug] Attempting to retry launching instruments, this is retry #2
info: [debug] Killall iOS Simulator

check out the below thread

There is one workaround mention. if you are using GUI, then
go to Developer Settings, check Custom Server Flags and insert --native-instruments-lib.

3 Likes

@sunny_sachdeva, Thanks , its working after ticking the native instrument library option in iOS Advanced settings.

1 Like

Hi! This workaround also worked for me, but it also seems to make my tests run much, much slower. When will this workaround be fixed?

@sunny_sachdeva Thanks a lot! Your post helped me to finally make it work.

Months later and your advice has helped me greatly. Thank you!

thanks a lot it help me a lot with checked the flag in the UI with you advise

Hi selvi, are u able to use Xcode 7.3 with appium-1.4.13 ??

Sorry, Currently I am not using Xcode 7.3.

okay thanks @Selvi_Ranganathan.

1 Like