title: Adding a container causes NSInternalInconsistencyException
body: <p>I am trying to add a container view to my app. However, it keeps crashing with the following error: </p>
  
  <p>'NSInternalInconsistencyException', reason: 'containerView is required.'</p>
  
  <p>I made a fresh project to test when the error occurs. When I add a container view and I assign it the class "viewController" it works fine (linked picture shows this). I then add a new UIPagecontroller class called "MainViewController" and assign this to original viewController in which the container is within - when I run this it crashes with the same error - why is this?</p>
  
  <p>I haven't added any code yet so I have none to link in but heres the console error:</p>
  
  <pre><code>2018-12-18 21:25:38.171283+0000 caca2[19001:1863302] *** Assertion failure in -[UIStoryboardEmbedSegueTemplate newDefaultPerformHandlerForSegue:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKit_Sim/UIKit-3698.54.4/UIStoryboardEmbedSegueTemplate.m:34
  2018-12-18 21:25:38.190027+0000 caca2[19001:1863302] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'containerView is required.'
  *** First throw call stack:
  (
      0   CoreFoundation                      0x0000000107b921e6 __exceptionPreprocess + 294
      1   libobjc.A.dylib                     0x0000000103ff8031 objc_exception_throw + 48
      2   CoreFoundation                      0x0000000107b97472 +[NSException raise:format:arguments:] + 98
      3   Foundation                          0x0000000103a9b652 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 193
      4   UIKit                               0x00000001054cb49e __67-[UIStoryboardEmbedSegueTemplate newDefaultPerformHandlerForSegue:]_block_invoke + 796
      5   UIKit                               0x00000001051b8f47 -[UIStoryboardSegueTemplate _performWithDestinationViewController:sender:] + 276
      6   UIKit                               0x00000001051b8e05 -[UIStoryboardSegueTemplate _perform:] + 82
      7   UIKit                               0x00000001051b90c7 -[UIStoryboardSegueTemplate perform:] + 157
      8   UIKit                               0x0000000104a37f11 -[UIViewController loadViewIfRequired] + 671
      9   UIKit                               0x0000000104a38574 -[UIViewController view] + 27
      10  UIKit                               0x0000000104906123 -[UIWindow addRootViewControllerViewIfPossible] + 122
      11  UIKit                               0x0000000104906834 -[UIWindow _setHidden:forced:] + 294
      12  UIKit                               0x00000001049195cc -[UIWindow makeKeyAndVisible] + 42
      13  UIKit                               0x000000010488d3da -[UIApplication _callInitializationDelegatesForMainScene:transitionContext:] + 4739
      14  UIKit                               0x00000001048925cb -[UIApplication _runWithMainScene:transitionContext:completion:] + 1677
      15  UIKit                               0x0000000104c54f7e __111-[__UICanvasLifecycleMonitor_Compatability _scheduleFirstCommitForScene:transition:firstActivation:completion:]_block_invoke + 866
      16  UIKit                               0x0000000105027a39 +[_UICanvas _enqueuePostSettingUpdateTransactionBlock:] + 153
      17  UIKit                               0x0000000104c54bba -[__UICanvasLifecycleMonitor_Compatability _scheduleFirstCommitForScene:transition:firstActivation:completion:] + 236
      18  UIKit                               0x0000000104c553db -[__UICanvasLifecycleMonitor_Compatability activateEventsOnly:withContext:completion:] + 675
      19  UIKit                               0x00000001055c6614 __82-[_UIApplicationCanvas _transitionLifecycleStateWithTransitionContext:completion:]_block_invoke + 299
      20  UIKit                               0x00000001055c64ae -[_UIApplicationCanvas _transitionLifecycleStateWithTransitionContext:completion:] + 433
      21  UIKit                               0x00000001052aa75d __125-[_UICanvasLifecycleSettingsDiffAction performActionsForCanvas:withUpdatedScene:settingsDiff:fromSettings:transitionContext:]_block_invoke + 221
      22  UIKit                               0x00000001054a54b7 _performActionsWithDelayForTransitionContext + 100
      23  UIKit                               0x00000001052aa627 -[_UICanvasLifecycleSettingsDiffAction performActionsForCanvas:withUpdatedScene:settingsDiff:fromSettings:transitionContext:] + 223
      24  UIKit                               0x00000001050270e0 -[_UICanvas scene:didUpdateWithDiff:transitionContext:completion:] + 392
      25  UIKit                               0x0000000104890eac -[UIApplication workspace:didCreateScene:withTransitionContext:completion:] + 515
      26  UIKit                               0x0000000104e63bcb -[UIApplicationSceneClientAgent scene:didInitializeWithEvent:completion:] + 361
      27  FrontBoardServices                  0x0000000109bc22f3 -[FBSSceneImpl _didCreateWithTransitionContext:completion:] + 331
      28  FrontBoardServices                  0x0000000109bcacfa __56-[FBSWorkspace client:handleCreateScene:withCompletion:]_block_invoke_2 + 225
      29  libdispatch.dylib                   0x0000000108cf67ec _dispatch_client_callout + 8
      30  libdispatch.dylib                   0x0000000108cfbdb8 _dispatch_block_invoke_direct + 592
      31  FrontBoardServices                  0x0000000109bf6470 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 24
      32  FrontBoardServices                  0x0000000109bf612e -[FBSSerialQueue _performNext] + 439
      33  FrontBoardServices                  0x0000000109bf668e -[FBSSerialQueue _performNextFromRunLoopSource] + 45
      34  CoreFoundation                      0x0000000107b34bb1 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
      35  CoreFoundation                      0x0000000107b194af __CFRunLoopDoSources0 + 271
      36  CoreFoundation                      0x0000000107b18a6f __CFRunLoopRun + 1263
      37  CoreFoundation                      0x0000000107b1830b CFRunLoopRunSpecific + 635
      38  GraphicsServices                    0x000000010a48ba73 GSEventRunModal + 62
      39  UIKit                               0x0000000104894057 UIApplicationMain + 159
      40  caca2                               0x00000001036edd37 main + 55
      41  libdyld.dylib                       0x0000000108d73955 start + 1
  )
  libc++abi.dylib: terminating with uncaught exception of type NSException
  (lldb) 
  </code></pre>
  
  <p>Any help or advice on how to sort this issue will be most appreciated!
  Thanks</p>
  
  <p>Image of simulator and xcode workspace: </p>
  
  <p><a href="https://i.stack.imgur.com/wVxZN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/wVxZN.png" alt="enter image description here"></a></p>