Context : Xcode 9.0 (9A235)
When I try to edit my storyboard label's note for localizers (inserting Barty Crouch tag #bc-ignore!), XCode 9 crashes.
Also, trying to edit the font does nothing.
Seems like a corrupted storyboard to me, certainly after a merge.
Does anyone face the same issue ?
EDIT, non-ambiguous question :
Is there a fix to avoid the crash or do I have to edit the storyboard by hand?
Process: Xcode [66619]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 9.0 (13247)
Build Info: IDEFrameworks-13247000000000000~26
App Item ID: 497799835
App External ID: 823595305
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: Xcode [66619]
User ID: 501
Date/Time: 2017-10-03 15:59:00.562 +0200
OS Version: Mac OS X 10.12.6 (16G29)
Report Version: 12
Anonymous UUID: 3A288ABF-30D0-A9E7-A02E-4BBD3B1BABB5
Sleep/Wake UUID: 22E57F41-2180-4AB1-AA1D-B1DCF99E683E
Time Awake Since Boot: 320000 seconds
Time Since Wake: 26000 seconds
System Integrity Protection: enabled
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Application Specific Information:
ProductBuildVersion: 9A235
ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEInterfaceBuilder/IDEInterfaceBuilder-13196/InterfaceBuilderKit/Utilities/IBAppKitSupport.m:388
Details: Unknown systemFontType: 132
Object: <NSFont: 0x7fc74354c640>
Method: -metaFont
Thread: <NSThread: 0x7fc73a40f910>{number = 1, name = main}
Hints:
Backtrace:
0 -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in IDEKit)
1 _DVTAssertionHandler (in DVTFoundation)
2 _DVTAssertionFailureHandler (in DVTFoundation)
3 -[NSFont(MethodsBasedOnPrivateState) metaFont] (in IDEInterfaceBuilderKit)
4 -[NSFont(IBDocumentArchiving) archiveWithDocumentArchiver:] (in IDEInterfaceBuilderKit)
5 __51-[IBDocumentArchiver archiveObject:forOptionalKey:]_block_invoke (in IDEInterfaceBuilderKit)
6 -[IBDocumentArchiver recurseWithArchiveToken:usingBlock:] (in IDEInterfaceBuilderKit)
7 -[IBDocumentArchiver recurseWithElementNamed:forObject:kind:invokingBlock:] (in IDEInterfaceBuilderKit)
Even with a brand new empty project, it craches when editing Comment For Localizer. It is an Xcode 9 issue.
As a workaround you can edit the .storyboard file manually by adding this kind of block (directly inside your <label> block for example):
<attributedString key="userComments">
<fragment content="Here goes your comment...">
<attributes>
<font key="NSFont" metaFont="smallSystem"/>
<paragraphStyle key="NSParagraphStyle" alignment="natural" lineBreakMode="wordWrapping" baseWritingDirection="natural" tighteningFactorForTruncation="0.0"/>
</attributes>
</fragment>
</attributedString>
Clean Xcode DerivedData folder.
Re-run Xcode.
Related
When trying to use the new Xcode 7 UI Testing feature on a physical iOS device by pressing the record button having the caret inside a test method, Xcode builds the project but just before starting the app on the device, the IDE crashes. I tested this with different projects (even a freshly created template one without writing a single line of code) and different devices (iPhone 6s Plus, iPad Pro, iPad mini 2 and iPhone 5, all running iOS 9.2). Does anyone have the same problem and already found a solution? Here is the complete crash log:
Process: Xcode [48959]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 7.2 (9548)
Build Info: IDEFrameworks-9548000000000000~7
App Item ID: 497799835
App External ID: 814662604
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: Xcode [48959]
User ID: 501
Date/Time: 2015-12-16 20:52:24.497 +0100
OS Version: Mac OS X 10.11.2 (15C50)
Report Version: 11
Anonymous UUID: DF96274B-998D-3102-7E2F-CECD011B3D38
Sleep/Wake UUID: 613A68D1-4541-4DB7-B1C5-BC255278457F
Time Awake Since Boot: 25000 seconds
Time Since Wake: 19000 seconds
System Integrity Protection: disabled
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Application Specific Information:
ProductBuildVersion: 7C68
ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEFrameworks/IDEFrameworks-9548/IDEKit/Testing/IDEUIRecordingManager.m:429
Details: (result) should not be nil.
Object: <IDEUIRecordingManager: 0x7fa128e011a0>
Method: -_workspaceTabController
Thread: <NSThread: 0x7fa119504010>{number = 1, name = main}
Hints: None
Backtrace:
0 0x0000000102f861fa -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in IDEKit)
1 0x0000000101b12761 _DVTAssertionHandler (in DVTFoundation)
2 0x0000000101b12978 _DVTAssertionFailureHandler (in DVTFoundation)
3 0x000000010306456b -[IDEUIRecordingManager _workspaceTabController] (in IDEKit)
4 0x0000000103065433 __94-[IDEUIRecordingManager _startRecordingWithLaunchSession:alwaysAskForAPIAccess:reservedNames:]_block_invoke_2 (in IDEKit)
5 0x0000000101b4ea04 __DVTDispatchAsync_block_invoke (in DVTFoundation)
6 0x00007fff9545c871 _dispatch_call_block_and_release (in libdispatch.dylib)
7 0x00007fff9545133f _dispatch_client_callout (in libdispatch.dylib)
8 0x00007fff95464c1d _dispatch_main_queue_callback_4CF (in libdispatch.dylib)
9 0x00007fff8b1d0cd9 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ (in CoreFoundation)
10 0x00007fff8b18bd3d __CFRunLoopRun (in CoreFoundation)
11 0x00007fff8b18b338 CFRunLoopRunSpecific (in CoreFoundation)
12 0x00007fff846ce935 RunCurrentEventLoopInMode (in HIToolbox)
13 0x00007fff846ce76f ReceiveNextEventCommon (in HIToolbox)
14 0x00007fff846ce5af _BlockUntilNextEventMatchingListInModeWithFilter (in HIToolbox)
15 0x00007fff899610ee _DPSNextEvent (in AppKit)
16 0x00007fff89d2d943 -[NSApplication _nextEventMatchingEventMask:untilDate:inMode:dequeue:] (in AppKit)
17 0x00000001020ef0c2 -[DVTApplication nextEventMatchingMask:untilDate:inMode:dequeue:] (in DVTKit)
18 0x00007fff89956fc8 -[NSApplication run] (in AppKit)
19 0x00007fff898d9520 NSApplicationMain (in AppKit)
20 0x00007fff8589a5ad start (in libdyld.dylib)
abort() called
HandleCommand(command = "process plugin packet send 'QSetEnableAsyncProfiling;enable:0;'")
I run into the same problem. I even tried cleaning the cache (rm -r ~/Library/Developer/Xcode/DerivedData), without success.
I found a way around it:
Start running the application in the device of your choice (Command-R)
Once the app is ready and running in the device, hit on the red "Record UI Test" button in the Debug toolbar.
Hopefully this works for you.
EDIT. To make things more strange, this works for an iPhone 6 physically connected to my computer and for an iPhone 5s run in the Simulator. Attempts to record UI tests on an iPhone 6 Plus were not successful.
I need to localize my plist files and string files for my project. However, when I try to select other languages in file inspector for .plist files, the Xcode will crash.
Parent Process: ??? [1]
Responsible: Xcode [1981]
User ID: 501
Date/Time: 2015-09-24 11:47:52.069 +1000
OS Version: Mac OS X 10.10.4 (14E46)
Report Version: 11
Anonymous UUID: XXXXXXXXXXX
Time Awake Since Boot: 7500 seconds
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 7A220
UNCAUGHT EXCEPTION (NSInvalidArgumentException): *** -[NSPathStore2 stringByAppendingPathExtension:]: nil argument
UserInfo: (null)
Hints: None
Backtrace:
0 0x00007fff89f71024 __exceptionPreprocess (in CoreFoundation)
1 0x0000000102627744 DVTFailureHintExceptionPreprocessor (in DVTFoundation)
2 0x00007fff87bc376e objc_exception_throw (in libobjc.A.dylib)
3 0x00007fff89f70eed +[NSException raise:format:] (in CoreFoundation)
4 0x00007fff90f257e3 -[NSPathStore2 stringByAppendingPathExtension:] (in Foundation)
5 0x000000010c5ae87c -[Xcode3VariantGroup proposedFilePathForLocalization:fileType:] (in DevToolsCore)
6 0x000000011281dc8c -[Xcode3LocalizationCommands
Anyone has same issue with Xcode7??
PS: localizing .string file works fine with same approach.
Having the same issue. Xcode 7.1 beta 2 seems to have it fixed.
It was working fine when i was copying and paste uitableview cells inside interface builder. But on next day when i start Xcode it crashed with report,
Encountered an error communicating with Interface Builder Cocoa Touch Tool. 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: containingTableView
Reason: Any table view cell being added to a layout engine should be contained in a table view in order to get the correct metrics
I tried to empty cache by following link https://stackoverflow.com/a/6247073/1556386. I also tried to fresh reinstall Xcode 6.1.1 but nothing sort out the problem.
Exception details are,
Process: Xcode [3408]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 6.1.1 (6611)
Build Info: IDEFrameworks-6611000000000000~4
App Item ID: 497799835
App External ID: 810788292
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: Xcode [3408]
User ID: 501
Date/Time: 2015-01-30 12:26:14.681 +0500
OS Version: Mac OS X 10.10 (14A389)
Report Version: 11
Anonymous UUID: 835265AB-3F12-806B-3EAE-821EB008717D
Time Awake Since Boot: 3800 seconds
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 6A2008a
ASSERTION FAILURE in /SourceCache/IDEInterfaceBuilder/IDEInterfaceBuilder-6254/InterfaceBuilderKit/Utilities/IBAbstractMessageChannelInterfaceBuilderToolProxy.m:40
Details: Failed to compute auto layout status IBLayoutConstraint, IBUILabel, IBUITableViewCell, and IBUITableViewCellContentView.
Encountered an error communicating with Interface Builder Cocoa Touch Tool. 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: containingTableView
Reason: Any table view cell being added to a layout engine should be contained in a table view in order to get the correct metrics
File: /SourceCache/IBSimulatorComponents/IDEInterfaceBuilderCocoaTouch-6247/SimulatorComponents/IBCocoaTouchTool/WidgetIntegration/IBCTTUITableViewCellIntegration.m:227
Method: -[UITableViewCell(IBCocoaTouchToolIntegration) ibEffectiveViewToPlaceInLayoutEngineWindow]
Exception backtrace:
0. CoreFoundation 0x000000010a6baf1d __exceptionPreprocess
1. libobjc.A.dylib 0x00000001093a1bb7 objc_exception_throw
2. CoreFoundation 0x000000010a6bab79 -[NSException raise]
3. ??? 0x0000000106e94e73 [UITableViewCell ibEffectiveViewToPlaceInLayoutEngineWindow]
4. ??? 0x0000000106e9bc88 [UIView ibWindowForUpdatingConstraints:]
5. ??? 0x0000000106e909db [NSObject ibPlaceInWindowPositioningAndSizingIfNeeded:during:]
6. ??? 0x0000000106e9caae [UIView ibPlaceInWindowPositioningAndSizingIfNeeded:during:]
7. ??? 0x0000000106e7b697 [IBCocoaTouchToolArbitrationUnit _ensureRootObjectIsInWindowDuring:]
8. ??? 0x0000000106e7ba60 [IBCocoaTouchToolArbitrationUnit computeStatusFromEngine:]
9. IBAutolayoutFoundation 0x0000000108a4f82b -[IBAutolayoutArbitrationUnit computeStatus]
10. ??? 0x0000000106e797a5 [IBCocoaTouchTool computeAutolayoutStatusForRequest:document:]
11. IBFoundation 0x0000000108bc18ef __80-[IBMessageReceiveChannel deliverMessage:toTarget:withArguments:context:result:]_block_invoke
12. IBFoundation 0x0000000108bc1686 -[IBMessageReceiveChannel deliverMessage:toTarget:withArguments:context:result:]
13. IBFoundation 0x0000000108bc1350 __88-[IBMessageReceiveChannel runBlockingReceiveLoopNotifyingQueue:notifyingTarget:context:]_block_invoke
14. libdispatch.dylib 0x000000010dcb6af4 _dispatch_client_callout
15. libdispatch.dylib 0x000000010dca3e95 _dispatch_barrier_sync_f_slow_invoke
16. libdispatch.dylib 0x000000010dcb6af4 _dispatch_client_callout
17. libdispatch.dylib 0x000000010dca2265 _dispatch_main_queue_callback_4CF
18. CoreFoundation 0x000000010a622fe9 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__
19. CoreFoundation 0x000000010a5e5eeb __CFRunLoopRun
20. CoreFoundation 0x000000010a5e5486 CFRunLoopRunSpecific
21. Foundation 0x0000000108f5eb42 -[NSRunLoop(NSRunLoop) runMode:beforeDate:]
22. IBFoundation 0x0000000108ba0955 -[IBAbstractPlatformTool startServingReceiveChannel:]
23. IBFoundation 0x0000000108ba0a2f -[IBAbstractPlatformTool startServingSocket:]
24. IBFoundation 0x0000000108ba0cf2 +[IBAbstractPlatformTool main]
25. ??? 0x0000000106eabe90 [IBViewRenderer .cxx_destruct]
26. libdyld.dylib 0x000000010dce7145 start
There was error in Storyboard file , i simply delete the Main.Storyboard file from Finder and than open Xcode. Xcode was than running normally.
I have an xcdatamodel file in a static library. To reference the file in my main app, I dragged the file into the main app through xcode. This worked great. I added a version to the xcdatamodel file. This created an xcdatamodelid file. If I try to drag the xcdatamodelid to my main project, xcode crashes. I can't drag the xcdatamodel files anymore.
How can I add a reference to my data model?
I'm using xcode 4.6.3.
The top of the xcode stack trace:
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 4H1503
ASSERTION FAILURE in /SourceCache/DVTFoundation/DVTFoundation-2091/Framework/Classes/FilePaths/DVTFilePath.m:461
Details: str should be an instance inheriting from NSString, but it is nil
Object: <DVTFilePath>
Method: +filePathForPathString:
Thread: <NSThread: 0x40030a220>{name = (null), num = 1}
Hints: None
Backtrace:
0 0x0000000106670a2a -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:messageFormat:arguments:] (in IDEKit)
1 0x000000010591f4e4 _DVTAssertionFailureHandler (in DVTFoundation)
2 0x00000001058a1c9f +[DVTFilePath filePathForPathString:] (in DVTFoundation)
3 0x0000000109a5b8d5 -[XCVersionGroup saveCurrentVersion] (in DevToolsCore)
4 0x0000000109935b53 -[PBXGroup insertItems:atIndex:] (in DevToolsCore)
5 0x0000000109ab2b83 -[Xcode3Group insertGroupSubitems:atIndexes:] (in DevToolsCore)
I upgraded to xcode 5 and I it works fine now. As an aside, when I dragged the file to my project, the window didn't give me the option to copy or add reference. I think this is was a bug with xcode 4. Now that xcode 5 is out, this is no longer relevant.
Very often when I try to edit UILabels in storyboard, Xcode is crashing. Any ideas what could be causing this? It looks like it has something to do with one of the autolayout constraints. Here's the error report:
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:{
}
I have the same problem… when working in a storyboard with "Rounded Rect Buttons" it crashes. Sometimes with one or two buttons, sometimes I can add ten buttons and then it crashes.
Edit:
After some experiments I have unchecked "Use Autolayout" in the "File Inspector" of the Storyboard and it works.
Maybe you'll give it a try.
A work around is to cut & paste from a Storyboard to the .xib.
* For me, it crashes in IB with .xib when ContainerView is dragged to the canvas. Xcode Version 8.2.1.