Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

XCode no valid compiled storyboard at path

I've got a universal XCode Project (ObjC) for iPad and iPhone with a subproject that contains a storyboard. The subproject is a static library that has been added to the main project. Included in this subproject is a bundle containing bespoken storyboard.

Whenenver I tap a certain button the application, the storyboard needs to be loaded;

[UIStoryboard storyboardWithName:@"UIControls.bundle/Config" bundle:nil];

That works perfectly fine for the iPhone (devices and simulators), but whenever I try to run the project an an iPad (device or simulator), I'm getting the following error;

Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'There doesn't seem to be a valid compiled storyboard at path...

What's the about? The project is a universal project, so why can't the iPad find the storyboard?

like image 452
AlBirdie Avatar asked Apr 10 '15 14:04

AlBirdie


3 Answers

To answer my own question;

This error appears when the bundle target isn't universal. So make sure the Targeted Device Family in the bundle's build settings is set to iPhone AND iPad.

enter image description here

like image 107
AlBirdie Avatar answered Nov 06 '22 11:11

AlBirdie


Just ran into this, after switching a project from a Universal target to iPad only, and the deployment target from iOS 9.0 to iOS 7.1.

The solution was to disable 'Use Size Classes' on the storyboard, and only keep the sizes for iPad.

To get to this checkbox, open the storyboard in the project navigator, then select then show the File Inspector (first icon) and scroll down to Interface Builder Document heading.

like image 28
stephenspann Avatar answered Nov 06 '22 11:11

stephenspann


I was using a Storyboard from a custom Cocoapod and it kept crashing with

There doesn't seem to be a "valid compiled storyboard" at path ...

In the affected storyboard, under Interface Builder Document I switched the "Builds for" value from "iOS 7.0 or later" to "Project Deployment Target" (which was 9.0), this did the trick for me.

like image 2
endowzoner Avatar answered Nov 06 '22 12:11

endowzoner