Xcode 4.5.2 gives me the following warning:
Unsupported Configuration
Scene is unreachable due to lack of entry points and does not have an identifier
for runtime access via -instantiateViewControllerWithIdentifier:.
Unfortunately I can't identify the incriminated scene. Selecting the warning in the Issue Navigator doesn't highlight anything in the Storyboard. I have a fairly complicated storyboard (30+ scenes).
Any suggestions?
For me, it wasn't because of a
Storyboard ID
or aSegue
. I was receiving this warning because I had not set theView Controller's Custom Class
.Select the
View Controller
on theStoryboard
, then in theUtilities Pane
, select theIdentity Inspector
icon. UnderCustom Class
, see what value is inside of theClass
field.If it just says
UIViewController
, then you need to type in the class name. This will be the name of your.h
and.m
files that make up your customUIViewController
subclass.I just had this exact error with a simple single-scene Storyboard, and all I had to do to fix it was check the "Is Initial View Controller" checkbox for the 1 view controller in the Storyboard. I suspect Xcode used to check this box for you by default in this situation, but no longer does.
Check the box for exactly one of the view controllers in your storyboard and you should be good.
With Xcode 7 this can be handled easily. There is no need to manually go through all the scenes to find a problematic one. First go to the Report navigator, where you can get more detail info about known issues. Issue description can look like this:
Base.lproj/Main.storyboard:fPh-fe-F5F: warning: Scene is unreachable due to lack of entry points and does not have an identifier for runtime access via -instantiateViewControllerWithIdentifier:.
With this info, you can copy object id, in this case it was fPh-fe-F5F, and search workspace for the occurrence of this string. String will be found in Main.storyboard file. Double click on search result and it will be opened Main.storyboard with selected scene. Once you know a problematic scene you can easily fix the issue, by setting storyboard ID or setting "Is Initial View Controller"
The easiest way to see which controller, or scene, is causing this problem is by:
.storyboard
in the Project Navigator and selectingOpen As > Source Code
. This will bring up the underlying XML of the Storyboard.Now, in my case, the warning was particularly annoying because the "offending scene" had an identifier and a segue! I was able to remedy the problem by deleting the scene and then undoing the deletion. Not elegant, but worked. I saved my Storyboard before doing this. In retrospect, I should have made a copy and
diff
'd the before-after.This issue can happen in one the following scenarios:
Case I: If none of the scene in the storyboard is marked as "isInitialViewController".
Fix: Identify the root view controller and mark it as "isInitialViewController" in your SB. In this case storyboard id is is not mandatory.
Case II
There can be situations where you do not need to have a initialViewController in a storyboard. For eg: when using Multiple storyboards.
Fix: In such cases make sure the "storyboard id" is correctly given and you refer to the first scene to used in the storyboard using this id. For eg:
In this case "storyboard id" is mandatory.
Case III
You have your initialViewController connected. But still you get this warning. This is because some of the scenes in the storyboard may not be connected with a "segue" and also they do not have a "storyboard id". Scan your storyboard, see if a "segue" is needed. Connect the segue if that is missing. If a segue is not needed make sure you need to give a "storyboard id" since it is the only way to refer the scene from your code, as shown in the example code above.
Hope this helps
I had the same issue,but i realized that i was using container view and instead of deleting default view controller i deleted its segue.So view controller remained in storyboard and so was the warning. So this is one of the case where warning pops up if default view controller of container view is not deleted properly when you don't need it.