Xcode 4.5故事板崩溃
当我尝试在故事板中编辑UILabels时,Xcode会崩溃。任何想法可能导致这种情况?看起来它与自动布局约束之一有关。这里的错误报告:Xcode 4.5故事板崩溃
Process: Xcode [43938]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 4.5 (1839)
Build Info: IDEApplication-1839000000000000~3
App Item ID: 497799835
App External ID: 10747437
Code Type: X86-64 (Native)
Parent Process: launchd [43283]
Date/Time: 2012-10-01 09:43:36.443 -0400
OS Version: Mac OS X 10.7.4 (11E53)
Report Version: 9
Sleep/Wake UUID: 8C7C93A7-0BEF-42C6-944C-488D8C7896DD
Interval Since Last Report: 152594 sec
Crashes Since Last Report: 6
Per-App Interval Since Last Report: 135715 sec
Per-App Crashes Since Last Report: 5
Anonymous UUID: E745D8FE-362B-4FD2-8594-7EC5C26767B2
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 4G182
ASSERTION FAILURE in /SourceCache/IDEInterfaceBuilderCocoaTouch/IDEInterfaceBuilderCocoaTouch-1926/IBPlugin/Utilities/IBObjectMarshalling.m:651
Details: Failed to start deciding frames for IBNSLayoutConstraint, IBUILabel, IBUITabBarItem, IBUITableView, IBUIView, and IBUIViewController.
Interface Builder encountered an error communicating with the iOS Simulator. If you choose to file a crash report or radar for this issue, please check Console.app for crash reports for "Interface Builder Cocoa Touch Tool" and include their content in your crash report.
Exception name: IBAssertionFailure
Exception reason: ASSERTION FAILURE: realConstraint
Reason: Should have found real constraint for represented constraint <NSLayoutConstraint:0x86a8c30 H:[UIView:0x868a0f0(71)]>
File: /SourceCache/IBAutolayoutFoundationIOS/IBAutolayoutFoundation-1818/Framework/Classes/Arbitration/IBAutolayoutEngine.m:223
Method: __76-[IBAutolayoutEngine realConstraintsFromCollectionOfRepresentedConstraints:]_block_invoke_0
Exception backtrace:
0. CoreFoundation 0x022a4012 __exceptionPreprocess
1. libobjc.A.dylib 0x01703e7e objc_exception_throw
2. CoreFoundation 0x0232cfb1 -[NSException raise]
3. ??? 0x0000beae [IBCocoaTouchTool startAutolayoutFrameDecisionSessionWithRequest:document:]
4. ??? 0x000342a5 [IBMessageReceiveChannel deliverMessage:toTarget:withArguments:result:]
5. ??? 0x00033fa9 [IBMessageReceiveChannel deliverMessage:toTarget:withArguments:result:]
6. ??? 0x00033c47 [IBMessageReceiveChannel runBlockingReceiveLoopNotifyingQueue:notifyingTarget:]
7. libdispatch.dylib 0x04c3d731 _dispatch_barrier_sync_f_slow_invoke
8. libdispatch.dylib 0x04c4c014 _dispatch_client_callout
9. libdispatch.dylib 0x04c3c7d5 _dispatch_main_queue_callback_4CF
10. CoreFoundation 0x0224aaf5 __CFRunLoopRun
11. CoreFoundation 0x02249f44 CFRunLoopRunSpecific
12. CoreFoundation 0x02249e1b CFRunLoopRunInMode
13. Foundation 0x01308c7c -[NSRunLoop(NSRunLoop) runMode:beforeDate:]
14. ??? 0x0000cf06 [IBCocoaTouchTool startServingReceiveChannel:]
15. ??? 0x0000d09f [IBCocoaTouchTool startServingWithSocket:]
16. ??? 0x0000e1b7 [IBCocoaTouchTool .cxx_destruct]
17. ??? 0x00002365 ???
Exception info:{
}
我有同样的问题......当在“Rounded Rect Buttons”故事板工作它崩溃。有时用一个或两个按钮,有时我可以添加十个按钮,然后崩溃。
编辑: 经过一些实验后,我没有选中故事板的“文件检查器”中的“使用Autolayout”,它的工作原理。 也许你会试试看。
感谢您的建议,当我每次添加容器视图时,IB都会崩溃。每当我添加一个,嵌入segue就会指向视图控制器场景,看起来像零宽度(在故事板上非常细小的场景)。取消选中“使用Autolayout”后,创建的场景与容器视图大小相同,因为它应该是。之后您可以重新启用Autolayout。 – Stuart
我遇到同样的问题。不幸的是,取消选中“使用Autolayout”并不能解决问题。 –
解决方法是将&从故事板粘贴到.xib。
*对于我来说,当ContainerView被拖到画布上时,它会在IB中使用.xib崩溃。 Xcode版本8.2.1。
我在使用故事板中的元素时遇到了Xcode崩溃的问题,但在Google搜索后找不到答案。我想添加(如果它帮助任何人找到答案):我只有在Xcode(4.5)的最新更新之后才体会到它,在复制/粘贴故事板中的圆形按钮时以及在调整大小时标签。我正在运行OS X 10.8.2。 – JoeFryer
这里同样的问题。我不知道是什么造成的,但令人难以置信的令人沮丧。 同样,每当我尝试添加另一个圆形按钮时也是如此。 – Robert