Ionic run ios not working

“ionic run ios” not working properly. I can not test it on an iPhone…
I think it’s an issue of certificates, but do not be sure
When you run the command I get the following:

Running command: /Users/rteran/Documents/apps/seron/hooks/after_prepare/010_add_platform_class.js /Users/rteran/Documents/apps/seron
add to body class: platform-ios
Running command: /Users/rteran/Documents/apps/seron/platforms/ios/cordova/run
Build settings from command line:
ARCHS = armv7 armv7s arm64
CONFIGURATION_BUILD_DIR = /Users/rteran/Documents/apps/seron/platforms/ios/build/device
SDKROOT = iphoneos8.1
SHARED_PRECOMPS_DIR = /Users/rteran/Documents/apps/seron/platforms/ios/build/sharedpch
VALID_ARCHS = armv7 armv7s arm64

Build settings from configuration file ‘/Users/rteran/Documents/apps/seron/platforms/ios/cordova/build-debug.xcconfig’:
CODE_SIGN_IDENTITY = iPhone Developer
CODE_SIGN_RESOURCE_RULES_PATH = “$(SDKROOT)/ResourceRules.plist”

=== BUILD TARGET CordovaLib OF PROJECT CordovaLib WITH CONFIGURATION Debug ===

Check dependencies

=== BUILD TARGET SeroÃÅn OF PROJECT SeroÃÅn WITH CONFIGURATION Debug ===

Check dependencies
Code Sign warning: Can’t locate the specified Code Signing Resource Rules file (’"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk/ResourceRules.plist"’).

PhaseScriptExecution Copy\ www\ directory build/Serón.build/Debug-iphoneos/Serón.build/Script-304B58A110DAC018002A0835.sh
cd /Users/rteran/Documents/apps/seron/platforms/ios
/bin/sh -c /Users/rteran/Documents/apps/seron/platforms/ios/build/Serón.build/Debug-iphoneos/Serón.build/Script-304B58A110DAC018002A0835.sh

real 0m0.360s
user 0m0.140s
sys 0m0.200s

ProcessInfoPlistFile build/device/Serón.app/Info.plist Serón/Serón-Info.plist
cd /Users/rteran/Documents/apps/seron/platforms/ios
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/rteran/Documents/Development/sdk/platform-tools:/Users/rteran/Documents/Development/sdk/tools:/Users/rteran/Documents/Development/apache-ant-1.9.4/bin:/usr/libexec/java_home/bin:/usr/local/sbin:/Users/rteran:/Users/rteran/.rvm/bin:/usr/local/bin/ionic:/usr/local/lib/node_modules/ionic/bin/ionic:/usr/local/bin/ios-sim:/usr/local/lib/node_modules/ios-sim/build/Release/ios-sim:/Users/rteran/.rvm/bin"
builtin-infoPlistUtility /Users/rteran/Documents/apps/seron/platforms/ios/Serón/Serón-Info.plist -genpkginfo /Users/rteran/Documents/apps/seron/platforms/ios/build/device/Serón.app/PkgInfo -expandbuildsettings -format binary -platform iphoneos -additionalcontentfile /Users/rteran/Documents/apps/seron/platforms/ios/build/Serón.build/Debug-iphoneos/Serón.build/MainViewController-PartialInfo.plist -o /Users/rteran/Documents/apps/seron/platforms/ios/build/device/Serón.app/Info.plist

GenerateDSYMFile build/device/Serón.app.dSYM build/device/Serón.app/Serón
cd /Users/rteran/Documents/apps/seron/platforms/ios
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/rteran/Documents/Development/sdk/platform-tools:/Users/rteran/Documents/Development/sdk/tools:/Users/rteran/Documents/Development/apache-ant-1.9.4/bin:/usr/libexec/java_home/bin:/usr/local/sbin:/Users/rteran:/Users/rteran/.rvm/bin:/usr/local/bin/ionic:/usr/local/lib/node_modules/ionic/bin/ionic:/usr/local/bin/ios-sim:/usr/local/lib/node_modules/ios-sim/build/Release/ios-sim:/Users/rteran/.rvm/bin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/dsymutil /Users/rteran/Documents/apps/seron/platforms/ios/build/device/Serón.app/Serón -o /Users/rteran/Documents/apps/seron/platforms/ios/build/device/Serón.app.dSYM

ProcessProductPackaging /Users/rteran/Library/MobileDevice/Provisioning\ Profiles/06310ca0-858c-4dfa-9580-565e559bec51.mobileprovision build/device/Serón.app/embedded.mobileprovision
cd /Users/rteran/Documents/apps/seron/platforms/ios
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/rteran/Documents/Development/sdk/platform-tools:/Users/rteran/Documents/Development/sdk/tools:/Users/rteran/Documents/Development/apache-ant-1.9.4/bin:/usr/libexec/java_home/bin:/usr/local/sbin:/Users/rteran:/Users/rteran/.rvm/bin:/usr/local/bin/ionic:/usr/local/lib/node_modules/ionic/bin/ionic:/usr/local/bin/ios-sim:/usr/local/lib/node_modules/ios-sim/build/Release/ios-sim:/Users/rteran/.rvm/bin"
builtin-productPackagingUtility /Users/rteran/Library/MobileDevice/Provisioning\ Profiles/06310ca0-858c-4dfa-9580-565e559bec51.mobileprovision -o /Users/rteran/Documents/apps/seron/platforms/ios/build/device/Serón.app/embedded.mobileprovision

Touch build/device/Serón.app
cd /Users/rteran/Documents/apps/seron/platforms/ios
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/rteran/Documents/Development/sdk/platform-tools:/Users/rteran/Documents/Development/sdk/tools:/Users/rteran/Documents/Development/apache-ant-1.9.4/bin:/usr/libexec/java_home/bin:/usr/local/sbin:/Users/rteran:/Users/rteran/.rvm/bin:/usr/local/bin/ionic:/usr/local/lib/node_modules/ionic/bin/ionic:/usr/local/bin/ios-sim:/usr/local/lib/node_modules/ios-sim/build/Release/ios-sim:/Users/rteran/.rvm/bin"
/usr/bin/touch -c /Users/rteran/Documents/apps/seron/platforms/ios/build/device/Serón.app

ProcessProductPackaging /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk/Entitlements.plist build/Serón.build/Debug-iphoneos/Serón.build/Serón.app.xcent
cd /Users/rteran/Documents/apps/seron/platforms/ios
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/rteran/Documents/Development/sdk/platform-tools:/Users/rteran/Documents/Development/sdk/tools:/Users/rteran/Documents/Development/apache-ant-1.9.4/bin:/usr/libexec/java_home/bin:/usr/local/sbin:/Users/rteran:/Users/rteran/.rvm/bin:/usr/local/bin/ionic:/usr/local/lib/node_modules/ionic/bin/ionic:/usr/local/bin/ios-sim:/usr/local/lib/node_modules/ios-sim/build/Release/ios-sim:/Users/rteran/.rvm/bin"
builtin-productPackagingUtility /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk/Entitlements.plist -entitlements -format xml -o /Users/rteran/Documents/apps/seron/platforms/ios/build/Serón.build/Debug-iphoneos/Serón.build/Serón.app.xcent

CodeSign build/device/Serón.app
cd /Users/rteran/Documents/apps/seron/platforms/ios
export CODESIGN_ALLOCATE=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/rteran/Documents/Development/sdk/platform-tools:/Users/rteran/Documents/Development/sdk/tools:/Users/rteran/Documents/Development/apache-ant-1.9.4/bin:/usr/libexec/java_home/bin:/usr/local/sbin:/Users/rteran:/Users/rteran/.rvm/bin:/usr/local/bin/ionic:/usr/local/lib/node_modules/ionic/bin/ionic:/usr/local/bin/ios-sim:/usr/local/lib/node_modules/ios-sim/build/Release/ios-sim:/Users/rteran/.rvm/bin"

Signing Identity: "iPhone Developer: Rafael Teran Torralbo (YGUPNP7RLZ)"
Provisioning Profile: “Seron Development”
(06310ca0-858c-4dfa-9580-565e559bec51)

/usr/bin/codesign --force --sign 1A3C1ABE51243879805C7C22C96A7D93253B8E3F --entitlements /Users/rteran/Documents/apps/seron/platforms/ios/build/Serón.build/Debug-iphoneos/Serón.build/Serón.app.xcent /Users/rteran/Documents/apps/seron/platforms/ios/build/device/Serón.app

/Users/rteran/Documents/apps/seron/platforms/ios/build/device/Serón.app: replacing existing signature

** BUILD SUCCEEDED **

Assertion failed: (AMDeviceSecureTransferPath(0, device, url, options, transfer_callback, 0)==0), function handle_device, file ios-deploy.c, line 1532.
[…] Waiting for iOS device to be connected
[…] Using (null) (88f659bcfe4222d309f71822f7803af463fdc7da).
------ Install phase ------
[ 0%] Found (null) connected through USB, beginning install
/Users/rteran/Documents/apps/seron/platforms/ios/cordova/run: line 116: 10313 Abort trap: 6 ios-deploy -d -b “$DEVICE_APP_PATH”

It seems like your iPhone isn’t recognized correctly. Have you tried to run it iPhone via XCode?

with xcode works perfectly, but with Ionic CLI not

which version of ios-deploy are you using? (ios-deploy -V)

The version is 1.3.2

Lets see if it is an issue with ionic-cli or cordova.

Can you run cordova run ios and see if it will run on the device.

the suggestion in this thread helped me: Error when doing 'ionic run ios'

tl;dr:
ps -ef | grep lldb
pkill lldb

1 Like

I tried

ps -ef | grep lldb
pkill lldb

and

cordova run ios

and appears the same problem…

Hi there,

Just confirming that I’m have exactly the same problem. I’m also seeing that code signing warning when running “ionic ios run”:

Code Sign warning: Can’t locate the specified Code Signing Resource Rules file (’"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk/ResourceRules.plist"’).

The ResourcesRules.plist file definitely exists.

Shortly afterwards, I get a dialog box pop up saying “ios-deploy quit unexpectedly”, while the terminal window shows:

/Users/erik/Development/mm-ionic/platforms/ios/cordova/run: line 116: 79783 Segmentation fault: 11 ios-deploy -d -b “$DEVICE_APP_PATH”

and lldb is hung on a line saying “connect”.

Let me know if I can do any more digging to help figure this out.

Thanks,

~ Erik.

PS: I’m also running ios-deploy version 1.3.2.

Exactly the same issue here. Highly annoying and completely unusable.

Same issue here. Appears after installing org.apache.cordova.dialogs plugin using ionic plugin add org.apache.cordova.dialogs.

ionic build and ionic emulate work, but ionic run fails with following errors:

Check dependencies
Code Sign warning: Can't locate the specified Code Signing Resource Rules file ('"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk/ResourceRules.plist"').

...

/usr/bin/codesign --force --sign XXXXXXXXXX --entitlements /Users/Tobias/Documents/Development/my_app/my_app/platforms/ios/build/my_app.build/Debug-iphoneos/my_app.build/my_app.app.xcent /Users/Tobias/Documents/Development/my_app/my_app/platforms/ios/build/device/my_app.app
/Users/Tobias/Documents/Development/my_app/my_app/platforms/ios/build/device/my_app.app: bundle format unrecognized, invalid, or unsuitable
In subcomponent: /Users/Tobias/Documents/Development/my_app/my_app/platforms/ios/build/device/my_app.app/CDVNotification.bundle
Command /usr/bin/codesign failed with exit code 1

** BUILD FAILED **

If anyone else is having this issue (like I am), you may want to subscribe to notifications on these two github issues for ios-deploy: