Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial


Jared Watkins
Jared Watkins
10,756 Points

iOS Simulator isn't running my app

It was running on the simulator before now. However, when I run the app now, the simulator goes black, then just shows the home screen. the built in apps work.

Other projects still load and run as expected. I don't believe there's a problem with the actual code in the project that won't load..

Does anyone know how to get this one app to run in the simulator again?

Add an exception breakpoint in xCode - most likely you have a problem in your code or you have removed the view entry point.

Jared Watkins
Jared Watkins
10,756 Points

Thanks Jayden,

The exception breakpoint didn't catch anything. What's strange is that I have restored the project to a previously known-to-be-working state.

Is the view entry point the arrow on the main.storyboard? I checked and that entry point is still there.

Thanks again for your help.

Yes thats the one. If you bring up 'Console' on your mac you will see some output from the sim there (it uses stdout I believe to log).

For example if I remove my view entry point I get an error like this pop up in my console: ' Apr 23 23:06:25 Jaydens-iMac.local Scroll Views[5175]: Failed to instantiate the default view controller for UIMainStoryboardFile 'Main' - perhaps the designated entry point is not set? '

Once your app runs you can search by its name (eg the one I ran was Scroll Views) - if you cant find something post it here and I will have a read through!

Jared Watkins
Jared Watkins
10,756 Points

OK, I removed the entry point, but the build still succeeded. There's no difference in how the simulator behaves, and that doesn't seem right at all.

Here is what the output to the console is when I run the app:

4/23/15 6:18:45.464 PM Xcode[3459]: [MT] DVTAssertions: Warning in /SourceCache/IDEFrameworks/IDEFrameworks-7703/IDEFoundation/Execution/Schemes/IDELaunchSchemeAction.m:816 Details: Failed to expand $(CONFIGURATION_BUILD_DIR), no extensions located for debugging! Object: <IDELaunchSchemeAction: 0x7fbba983aec0> Method: -filePathsForContainersAndExtensionsForBuildParameters: Thread: <NSThread: 0x7fbba2d39530>{number = 1, name = main} Please file a bug at http://bugreport.apple.com with this warning message and any useful information you can provide.

4/23/15 6:18:47.325 PM launchd_sim[3795]: assertion failed: 14D136: libxpc.dylib + 29265 [23DBFC52-1ABE-3A33-8FE2-637C3B0EA394]: 0x8d

1 Answer

It sounds like a deployment error, I haven't seen that message before to be honest!

Try deleting the app from the sim, or reset the simulator from one of the menu items in the toolbar on OSX. Then clean the project and rebuild.

It's complaining about the build directory - the only other thing I could think of to check (on my phone at the moment) is under Xcode preferences and the locations and make sure the build directory is set to the recommended option - but since you said other projects compile and run fine I wouldn't have thought it is that!

Fingers crossed a clean and build will work

Jared Watkins
Jared Watkins
10,756 Points

Thank you for your help so far! I deleted the app from the simulator, and reset and hit clean. It's still not working, and doing the same thing.

Any change you could archive up the project and post it here so I can take a look? If its a proper development project no need, the only other thing I would advise is to make sure is you are calling super.viewDidLoad() in any view controller and returning true as this may cause it to go black.

One other thing to check actually which I forgot to mention yesterday, click on the project in the navigation gutter and on the summary page make sure the default storyboard is set to your main.storyboard - this may be causing the problem as well!

Best, JS