I realize that this is a long-shot... but I'm looking for tips or advice on how to prevent or debug this issue.
If I start my app in the iPad simulator (webapp using phonegap), then start Safari and select Develope->iPad Simulator->index.html - Safari immediately crashes. The odd thing is that I'm one of several developers working on this app... and we all have seemingly identical setups - yet this doesn't happen for them. They are able to debug in Safari as expected. I should also mention that the app itself works great in the simulator.
Software involved:
Xcode 4.6.2
Safari 6.0.5
Running simulator for iPad 6.1
Again, I realize that this isn't much to go on. Hoping someone might be able to point me in the right direction to figure it out.
SOLVED!
On a whim I blew away the directory for the app in:
~/Library/Application Support/iPhone Simulator/6.1/Applications/
and Voila - debugging in Safari works again - doesn't just crash-on-load!
For those people finding this with a more recent version of Mac OS and Xcode/iOS Simulator, this fix worked for me as well:
Mac OS version: 10.12.6
iOS Simulator version: 10.0
Open up iOS Simulator.
On the menu bar go to Hardware > Erase All Content and Settings > Reset.
Restart your Mac
Should be back up and running after that.
Related
Arrgghh....I am so fed up with Apple. I have none of the problems with Android that I continually have with Apple.
Went to go load my app onto a local device (iPhone 6s) that had iOS 10.1 on it. Xcode wouldn't play with that so I had to upgrade to Xcode 8.1 and everything broke. I am now just trying to deploy my project to the simulator, it builds fine and deploys - I see my splash screen and then the app goes blank. Zero errors are displayed in the console yet I am not able to see the app in Safari Develop "Simulator" (not even there).
Mac 10.11.6 El Capitan
Xcode 8.1 (8B62)
Cordova 6.4.0
Project platform iOS: 4.2.1 (I even upgraded it to 4.3.0 but still nothing, then rebuilt project with 4.2.1 again)
Project iOS Target: 9.3
Deployment Target: 9.3 (iPhone only)
Simulators: 10.0, 10.1, 9.3
It was deploying just fine to Simulator iPhone 6x with Xcode 8.0 for 9.3 deployments, but upgrading to Xcode 8.1 broke it. I am going to remove the Simulators 10.0/10.1. the biggest issue is it builds just fine but deploys splash screen then goes blank.
Relaunch Safari after Simulator starts running.
#eb1 gets credit for these 'fixes'.
After upgrading to Xcode 8.1 as well as Safari 10.0.1 I was no longer able to see compile, debug or JS errors in either the Xcode console or the Safari Develop Simulator debug/console sections.
After compiling my project, the simulator would show my app splash screen and then go blank. no errors, messages, console output - nothing. In addition, Safari was no longer displaying the "Develop -> Simulator" option to debug my app.
To fix this, I had to shut down Xcode and Safari, and in this order, relaunch Xcode, load the project into Xcode and then start Safari - only then would the Develop->Simulator dropdown show up.
But even after getting #1 to show up, I still wasn't able to see any bugs, or code issues within the Develop->Simulator window after the app had loaded. After it was loaded it would just be blank and i couldn't see what any issues that was causing my app to not be working. Well, after it was loaded i had to press "cmd-R" to reload the console/debug messages and then i was able to see the issues breaking my app. I have to do this every time now...load the app, see nothing, then cmd-R...then able to see the bugs/breaks.
I still don't have a solution for doing the same within Xcode console - prior to upgrading I could see almost all of the same issues in both Xcode and Safari, but now only in Safari (using solution #2 above). Xcode shows everything loaded fine, while Safari cmd-R 'after' loading is now showing the compile issues.
If anyone ever finds a solution for #3, please please add to this thread.
I'm running an app on my iOS device but, in Instruments, that device is greyed out.
This also means I can't attach the process (Cant launch iOS app with Instruments on device). Is it anything to do with my earlier question: Instruments > Profile - Revoke and request
Xcode: 6.1.1
iOS: 7.1.2
Any idea why?
I only had to reboot my phone (not my Mac), and then the error went away
(Xcode 9.2, iPhone X running 11.2.6).
i was having this issue and resolved it by
Unplugging my device
Turning my device off
Rebooted my mac
Turned device back on and plugged into computer after logging back in.
now it shows up in instruments. I tried unplugging device, restarting xcode, but that didn't work. rebooting everything is what did the trick for me.
I met the this problem. Xcode(Version 9.3.1 (9E501)), iphone 7, And I forcely quit the Instrument. It's work
I came across same problem today on xcode7.2.1, iOS 9.2.1, iPhone 6Sp. Resolved by rebooted my mac, my watch and the iPhone.
If your workspace contains several projects and/or several targets, it seems that XCode doesn't know which binary to profile.
Just Edit your scheme -> Profile -> Choose an Executable and it should enable the profiling option.
I had the same problem where Profile was greyed out. It turned out to be I had the device option at the top set to Generic iOS Device
// this will make Profile greyed out
Once I switched it to an actual simulator device or my actual device Profile was no longer greyed out
One other option can be to in Xcode at the top go to Help > search Edit Scheme and select it > on the left side of the screen select Profile > change Executable drop down to your_project's_name.app
I don't know which process helped but I force quit AppleMobileDeviceHelper and DTServiceHub in the Activity Monitor and then it started working again (I was able to select my phone without rebooting).
Recently, I confronted the question again on Xcode Version 10.1 (10B61), iphone 7 and Mac 10.14.1 (18B75). I resolved it by upgrading the deployment from 8.0 to 10.1. In fact, I have meet many strange Xcode bugs caused by the version, liking this one(xcode gpu shader profiler)
It turned out that my iPhone is not trusted my computer.
How to re-trust computers, see:
https://www.wikihow.com/Trust-a-Computer-on-an-iPhone
In short, you should reset Location and Privacy in settings, and then plug-in your iPhone again. And you will see 'Trust this computer' again.
My issue what that it was asking me to trust the computer every time I plugged it in.
To fix it, I had to turn on the Hotspot then turn it back off.
I just downloaded Xcode 6 & played with it a bit.
After switching back to previous version of Xcode and running in simulator, I keep getting this error.
Unable to determine simulator device to boot.
How do we resolve this?
Thanks in advance.
Make sure you have only one iOS Simulator instance running in the Dock.
There was a simple answer to this for me:
Open the simulator via Xcode -> Open Developer Tool -> iOS simulator (even if it can't launch, the app will be open).
With the simulator app open, go to Hardware -> Device -> Manage Devices.
Add any missing simulators with the plus button (all of mine were missing for some reason).
I've faced same issue and solved by below steps:
1) Move xcode6-beta into application folder
2) Restart mac and open xcode6-beta from application folder.
I had the same problem when running from Xcode 6 beta selecting iPhone 5s. If I choose iPhone 5 or "resizable iPhone" then my app launches fine.
You will not see the profiles of simulator without a rebooting of OS X.I added simulator for many times,when the rebooting finished, it shows on the device list under the simulator bar. I think this is a bug of Xcode 6 Beta
I think you have 2 simulator running in the dock. Please close another one simulator and run the project again. It might helpful for you.
In my case I had such a message just because the simulated device was still booting (longer than usually, I guess). Xcode 7.2.
(This is not actually an answer to this specific question, but I came here googling the message in the title, so I am writing my note here for if someone else gets the same case as I did)
My case wasn't about having two simulators open. It was just because having instruments open as well. Closing Instruments resolved the issue
I just fixed the exact same problem by removing the beta version and rebooting the computer.
Having a strange issue with XCode 4.5 on OSX 10.8.2.
When I run an application on the mac, it doesn't launch and I get the following error in console consistently.
10/01/2013 17:26:26.478 Xcode[7884]: ERROR: Failed to create an alert for ID "enabled" based on defaults: 1
When I run an iPad/iPhone app, the simulator launches, but the app just shows a blank screen. I thought there was an issue with my apps (although very unlikely) so attempted to create a vanilla mac app and iOS app. Both experience the same issues. Running/Debugging any iPad project directly on the iPad through Xcode works however.
I've attempted to:
Delete everything in ~/Library/Developer/Xcode/DerivedData/
Delete the Xcode app and download it again from the AppStore
Delete all of my Xcode preferences
Xcode Build and stop buttons also become unresponsive so I have to force quit xcode to try again.
Nothing seems to be working, Xcode works fine however on my mac pro at work and all projects build just fine! Any help would be much appreciated!
Never mind, setting the debugger to GDB instead of LLDB seems to have fixed this. It would however be good to get an answer as to why LLDB doesn't work as the default debugger and what's changed in xcode to make it no longer work as expected.
I have the original iPod touch with iOS 3.1.3 (the last one that can run on the device). When I use Xcode 4.3.2 to debug an application, it always hangs at the launch image screen. However the application runs fine when I disconnect the device and run it without Xcode.
Is there a way to fix this? I've reinstalled iTunes 10.6 and restarted both my Mac and the iPod, with no effect.
This is Xcode's screen when I pressed "pause" on the debugger. Maybe this can be somewhat useful for identifying the issue.
Thanks in advance.
I had a similar problem, I fixed it by editing the project scheme to use the GDB Debugger instead of the LLDB Debugger when running the app.