ionic-framework: bug: BUG can't open ios simulator with xcode 7
Type: <span ionic-type>bug</span>
Platform: <span ionic-platform>ios</span> <span ionic-platform-version>8</span> <span ionic-webview>webview</span>
<span ionic-description>I install cordova and ionic to develop app with ios, my xcode version is 7.1.0, but when i use command
ionic emulate ios
the Simulator opened, but do nothing.
and moment for a while, the terminal show the log, like below:
** BUILD SUCCEEDED **
No target specified for emulator. Deploying to iPhone-6 simulator
An error was encountered processing the command (domain=com.apple.CoreSimulator.SimError, code=159):
Invalid device state
An error was encountered processing the command (domain=com.apple.CoreSimulator.SimError, code=159):
Invalid device state
ENOENT: no such file or directory, stat '/Users/Fernando/Library/Logs/CoreSimulator/3804D671-203A-45F2-A689-1D18D049EC91/system.log'
Error code 1 for command: ios-sim with args: launch,/Users/Fernando/Develop/dev/Javascript/Demos/ionic_demo/platforms/ios/build/emulator/HelloCordova.app,--devicetypeid,com.apple.CoreSimulator.SimDeviceType.iPhone-6,--stderr,/Users/Fernando/Develop/dev/Javascript/Demos/ionic_demo/platforms/ios/cordova/console.log,--stdout,/Users/Fernando/Develop/dev/Javascript/Demos/ionic_demo/platforms/ios/cordova/console.log,--exit
Error: /Users/Fernando/Develop/dev/Javascript/Demos/ionic_demo/platforms/ios/cordova/run: Command failed with exit code 2
I can’t resolve this iuuse. I have reinstall node, and reinstall cordova and ionic. And this issue always in.
ionic info
Your system information:
Cordova CLI: 5.4.0
Gulp version: CLI version 3.9.0
Gulp local:
Ionic Version: 1.1.1
Ionic CLI Version: 1.7.10
Ionic App Lib Version: 0.6.5
ios-deploy version: 1.8.2
ios-sim version: 5.0.3
OS: Mac OS X El Capitan
Node Version: v5.1.0
Xcode version: Xcode 7.1.1 Build version 7B1005
How can I solve this issue?</span>
<span is-issue-template></span>
About this issue
- Original URL
- State: closed
- Created 9 years ago
- Comments: 38 (3 by maintainers)
Solved it with : http://zacvineyard.com/blog/2015/11/ionic-invalid-device-state-error-with-xcode-7-solved
Looks like the command line tools with Xcode weren’t installed. Make sure they’re install by opening Xcode or running
xcode-select --installfrom the command line.hey guys!
I have the same problem when I try to emulate iOS platform
I tried to looking for any solution about this…but I can’t find something good.
Any idea? Thanks!
Ok this is what worked for me.
npm -g install ios-simHaving the same problem, and no solution found after read the whole thread.
¿Any help?
Alright guys, I went through all of these suggestions and none of them helped me. For those unlucky few that still get
Open your Xcode project, then run it on the iPhone 6 emulator. After doing that step, I was able to use
ionic emulate iosandionic emulate ios -lcsಠ_ಠ@BenjaminConant I’m seeing the same issue, the emulator doesn’t start properly. The project seems to build, then starts a blank window, and after a while the console exits with:
Recursive
chowning hasn’t helped, norsudo npm installing ios-sim and ios-deploy. Given it’s a first run for me on ios development, it might be that I’m just missing something, or it could be a real issue for the few of us.thanks @oneboxteam, http://zacvineyard.com/blog/2015/11/ionic-invalid-device-state-error-with-xcode-7-solved it work:)
Hi all,
Have tried everything in this thread and still getting the same issue … I can open up the project in xcode and run the emulator from there and everything works great. I cannot, however, open the emulator from the terminal with
ionic emulate ios… when i do runionic emulate iosi getthe emulator opens but is just a black screen and then after a while the terminal logs
here is my
ionic infoAnyone else seeing behavior like this or have any ideas? Would be much appreciated!
@oneboxteam’s link didn’t work for me. But running “ionic state reset” did.
You should launch the xcode ,and select /platform/ios/xxxx.xcodeproj path and build on ur iphone or launch the simulator , and run the terminal ,then it works