Xcode 6.1 crashing when running the project - crash

I searched StackOverflow and it doesn't look like many people are having this problem, but for me, this happens very, very frequently. Maybe not every time, but perhaps every other time.
Once I try to build and run the app, Xcode crashes, and in a strange way: it just disappears with no error messages, no suggestion to report the problem, nothing at all. This happened with Xcode 6.0 as well. It doesn't matter whether I am running the app on a device or on an emulator.
To prevent the crash, I need to Product > Clean. If I do this clean each time before running the app, crashes do not happen, but once I forget to do that, Xcode can crash any moment.
I don't think I ever had this crash with an old project, but it keeps happening with the project that I started in Xcode 6.0.
Because of that, iOS development is becoming for me quite a painful exercise, similar to pre-Android-Studio Android development.
Is it just my problem, or maybe someone else is having it? Maybe someone has a solution?

I just started running into the same issue and found a workaround for it. Found it to be an issue with building when Xcode is full screen. Seems silly, but so far exiting full screen mode has worked for me. I've been able to re-introduce the issue after building full screen a few times, and then instantly fix it again by exiting full screen.

Yeah, it's not that the app is crashing, it's just that the click is triggering the red close window button behind the red button (yeah, seriously). You'll notice, Xcode is still open, it's just that the window has closed. You might also notice that sometimes when you click "stop" in full screen mode, it switches to non full screen. Again, the tap is passing through the run/stop buttons to the underlying window controls.
So dumb.

I solved it using 'cmd + R' instead of clicking the run button

Related

SwiftUI navigationLink not working after dismissing destination from the stack

I haven't noticed this before, so it may be a bug with the new release.
When I click on a NavigationLink, everything works as expected. Then I can click the back button (which I have done with the default back button as well as a custom back button) and it still works. If I try to click the same NavigationLink again, it does not trigger the destination. I can click on a different NavigationLink, and it will work, and when I go back the first link is functional again. Only the last link is unavailable.
This seems to be the case in lists, forms, and free navigation links.
Has anyone encountered this functionality? Is there a fix for it?
Working on Xcode Version 11.3 (11C29)
Thank you for your help.
After a lot of searching and testing, this appears to be a bug specific to the simulator in the new release. When running the app on my phone it works perfectly. Hopefully it is fixed soon, but for now I can run testing on the phone.

XCode crashes on start up

Yes, this happens to people. Yes, I've looked at all the solutions.
This is different.
XCode starts and there is no error message, it just freezes. This is the screen I get:
That's it. No errors. I can't interact with it, I can't close it. The only thing I can do is use Show All Windows. There are five and yes I don't need them all (never did! don't know why I have them) but I can't close any of them. To get rid of it I need to do a hard reset.
I've tried deleting the library file in Finder as this was one of the solutions.
Nope.
Anyone any ideas?
I think it's XCode 6 (the latest) but I can't tell because I can't access the menu.
I ended up scouring Stackoverflow for ways to clear the startup process.
You hold cmd+shift when you start XCode - ONLY from the task bar, this does NOT work if you go into the Applications folder - and it will load blank.
Then you can load your project.

Xcode Interface Builder Click + Drag Sticking

I am attempting to use Xcode on Mavericks, but I am having a very peculiar problem. It seems as though my click locations are getting stuck and causing every click to be recognized at a click + drag. It's very strange and therefore somewhat hard to explain so I captured the problem within a QuickCast:
http://quick.as/a0jVc20J
I have tried using another mouse and I still have the problem. I have tried reinstalling Xcode and the problem persists. The mouse works fine elsewhere, and I do not have any other problems akin to this in any other app. Does anyone have any suggestions? I am desperate: as you can see, it is impossible to build an interface with this mouse situation.
Thanks!

changed product name in build settings, now app won't launch in simulator

I wanted a different title to be displayed in the sub-title under my iPad app's icon and changed the Product Name for my app under Build Settings.
This worked but has had a strange side effect. Whilst the app continued to work perfectly on a connected iPad, on the emulator it now behaves in a similar way to that described in [this question].1
Namely, it says it has finished running <my app> on iPad 6.0 Simulator
I tried changing the Product Name back but the problem persists.
I also tried some of the suggestions on the other question (e.g. removing armv7 frfom Required Device Capabilities) but nothing worked.
This isn't a showstopper at the moment as I have a real iPad to test on but I'd still like to understand what is going on, if anyone knows.
Sounds like time for a reboot of the Mac. Restarting Xcode might suffice. One other thing to try is to delete the app from the simulator.
I have seen this on iPhone simulator 6. Many a times, when you click "Run" again - it runs without problem.
However if that doesn't work, you may try one of the following:
Project->Command+Alt+Shift+K - a choice will appear saying something like clean folders. Do it.
In organizer, go to derived data folder (finder) using tiny arrow just at the right of your project. Try deleting your project from finder. If it doesnt delete at once, try it often.
Try resetting iPhone or iPad simulator.
Exit XCode and reopen project. Do the same with iPhone / iPad simulator.
If you are wondering why this is happening, no one really knows! It's just some flags gone bad, restored once you re-do everything for it to work, that's it.
Have you tried switching off the Debugger?
So Edit Schemes -> Debugger -> None
Also restarting the Simulator and Xcode and cleaning the project may help
Use another way: click on the azure icon of your project, keep the trackpad pressed until you see it allows to edit the name. Choose the name that you want, then a sheet like this will appear:
Click "rename" and you're done with it.

I comment out code in my iPad app, but it still gets executed...how is this possible?

I have a calendar program that I am trying to convert to iPad (using XCode4, no storyboards, but running on the Simulator).
It currently is not behaving correctly when I move to a previous month (I get a blank screen before the view is re-drawn). So I commented out the code that does the actual creating and drawing of the screen, and the screen is still re-drawn! I comment out other code, and the same thing happens... it's as if it is ignoring the commented statements!
I am dumbfounded as to why this is happening... I have done multiple cleans, straight builds then run... same thing happens.
Any ideas?
Have you tried clearing the cache of the simulator?
From the simulator menu:
IOS Simulator > Reset contents & settings
Try cutting out the code from Xcode. If it still runs then something is seriously wrong. Also try duplicating the project folder in finder and run the new project, it has solved some weird xCode behavior for me.
An unmatched brace, parenthesis or other syntax error can cause both the problems you describe.