Cannot open storyboard (com.apple.InterfaceBuilder error -1.) - xcode

After several developers were working on the storyboard in one of our apps, we are now getting this error when trying to open the storyboard in Xcode Interface Builder:
The document "MainStoryboard_iPhone.storyboard" could not be opened.
The operation couldn’t be completed. (com.apple.InterfaceBuilder error
-1.)
Check the console log for additional information.
We are all running the latest version of Xcode (4.6.2 4H1003) and all changes were made to the storyboard in Interface Builder. There is no additional information showing in the console log. I'm assuming the error is referring to the same console log where log and debug statements appear, which is completely empty.
One of the developers receives this same error when trying to open the storyboard in another of our apps I was working on. This storyboard opens fine for me in Xcode on my computer however, so we never bothered to look into the error more at the time (this first occurred a few months ago). But this time, we all get the same error (4 of us have tested opening it on our own computers).
We are using GitHub to manage our source control on both projects, using a few different Git clients. Any ideas as to what is causing this error and how to fix it?
UPDATE: This is the output to /var/logs/system.log on my computer after trying to open the storyboard:
Jun 5 16:38:44 my-computer-host-name Xcode[271]: Exception raised while unarchiving document objects - *** -[__NSArrayM insertObject:atIndex:]: object cannot be nil
Jun 5 16:38:45 my-computer-host-name Xcode[271]: [MT] DVTAssertions: Warning in /SourceCache/IDEKit/IDEKit-2113/Framework/Classes/Editor/IDEEditorDocument.m:1364
Details: Message sent to invalidated IBStoryboardDocument instance <IBStoryboardDocument: 0x40ecc34c0>. Backtrace for invalidation:
0 0x000000010d814f86 -[IDEEditorDocument _invalidate] (in IDEKit)
1 0x000000010d883291 -[IDEEditorDocument initForURL:withContentsOfURL:ofType:error:] (in IDEKit)
2 0x00000001103005d0 -[IBDocument initForURL:withContentsOfURL:ofType:error:] (in IDEInterfaceBuilderKit)
3 0x000000010d882efd +[IDEDocumentController _newEditorDocumentWithClass:forURL:withContentsOfURL:ofType:extension:error:] (in IDEKit)
4 0x000000010d882dba -[IDEEditorContext _newEditorDocumentWithClass:forURL:withContentsOfURL:ofType:extension:error:] (in IDEKit)
5 0x000000010d88290c -[IDEEditorContext _openNavigableItem:withContentsOfURL:documentExtension:shouldInstallEditorBlock:] (in IDEKit)
6 0x000000010d991628 -[IDEEditorContext _notifyDelegateAndOpenNavigableItem:withContentsURL:documentExtensionIdentifier:locationToSelect:annotationRepresentedObject:stateDictionary:annotationWantsIndicatorAnimation:exploreAnnotationRepresentedObject:highlightSelection:] (in IDEKit)
7 0x000000010d8bfe7b -[IDEEditorContext _notifyDelegateAndOpenEditorOpenSpecifier:updateHistory:] (in IDEKit)
8 0x000000010d8bf99c -[IDEEditorContext _openEditorOpenSpecifier:updateHistory:] (in IDEKit)
9 0x000000010d8bf8ba -[IDEEditorContext openEditorOpenSpecifier:] (in IDEKit)
10 0x000000010d8cbf40 -[IDEEditorGeniusMode openEditorOpenSpecifier:editorContext:] (in IDEKit)
11 0x000000010d8bf76e -[IDEEditorArea _openEditorOpenSpecifier:editorContext:takeFocus:] (in IDEKit)
12 0x000000010d9a3174 __108+[IDEEditorCoordinator _doOpenEditorOpenSpecifier:forWorkspaceTabController:editorContext:target:takeFocus:]_block_invoke (in IDEKit)
13 0x000000010d8bf6cc +[IDEEditorCoordinator _doOpenWithWorkspaceTabController:editorContext:target:allowFallback:documentURL:usingBlock:] (in IDEKit)
14 0x000000010d8bf12d +[IDEEditorCoordinator _doOpenEditorOpenSpecifier:forWorkspaceTabController:editorContext:target:takeFocus:] (in IDEKit)
15 0x000000010d8bed45 -[_IDEOpenRequest _runIfNecessary] (in IDEKit)
16 0x00007fff8bfde395 __NSFireDelayedPerform (in Foundation)
17 0x00007fff8b169804 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ (in CoreFoundation)
18 0x00007fff8b16931d __CFRunLoopDoTimer (in CoreFoundation)
19 0x00007fff8b14ead9 __CFRunLoopRun (in CoreFoundation)
20 0x00007fff8b14e0e2 CFRunLoopRunSpecific (in CoreFoundation)
21 0x00007fff8ac57eb4 RunCurrentEventLoopInMode (in HIToolbox)
22 0x00007fff8ac57c52 ReceiveNextEventCommon (in HIToolbox)
23 0x00007fff8ac57ae3 BlockUntilNextEventMatchingListInMode (in HIToolbox)
24 0x00007fff85f5d563 _DPSNextEvent (in AppKit)
25 0x00007fff85f5ce22 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] (in AppKit)
26 0x00007fff85f541d3 -[NSApplication run] (in AppKit)
27 0x00007fff85ef8c06 NSApplicationMain (in AppKit)
28 0x000000010cbc9b6f (in Xcode)
29 0x000000010cbc9b00 (in Xcode)
30 0x0000000000000002
Object: <IBStoryboardDocument: 0x40ecc34c0>
Method: -updateChangeCount:
Thread: <NSThread: 0x40030a220>{name = (null), num = 1}
Please file a bug at http://bugreport.apple.com with this warning message and any useful information you can provide.
And this is the log output on the other dev's computer after trying to open the storyboard in the other project that we get this same error on (this is the storyboard that opens fine on my computer):
Jun 5 17:20:13 other-dev-computer-host-name Xcode[157]: Exception raised while unarchiving document objects - *** -[__NSArrayM insertObject:atIndex:]: object cannot be nil
Jun 5 17:20:13 other-dev-computer-host-name Xcode[157]: [MT] DVTAssertions: Warning in /SourceCache/IDEKit/IDEKit-2113/Framework/Classes/Editor/IDEEditorDocument.m:1364
Details: Message sent to invalidated IBStoryboardDocument instance <IBStoryboardDocument: 0x409ec3340>. Backtrace for invalidation:
0 0x000000010d746f86 -[IDEEditorDocument _invalidate] (in IDEKit)
1 0x000000010d7b5291 -[IDEEditorDocument initForURL:withContentsOfURL:ofType:error:] (in IDEKit)
2 0x00000001102755d0 -[IBDocument initForURL:withContentsOfURL:ofType:error:] (in IDEInterfaceBuilderKit)
3 0x000000010d7b4efd +[IDEDocumentController _newEditorDocumentWithClass:forURL:withContentsOfURL:ofType:extension:error:] (in IDEKit)
4 0x000000010d7b4dba -[IDEEditorContext _newEditorDocumentWithClass:forURL:withContentsOfURL:ofType:extension:error:] (in IDEKit)
5 0x000000010d7b490c -[IDEEditorContext _openNavigableItem:withContentsOfURL:documentExtension:shouldInstallEditorBlock:] (in IDEKit)
6 0x000000010d7d9c96 -[IDEEditorContext _openNavigableItem:withContentsOfURL:shouldInstallEditorBlock:] (in IDEKit)
7 0x000000010d8c3667 -[IDEEditorContext _notifyDelegateAndOpenNavigableItem:withContentsURL:documentExtensionIdentifier:locationToSelect:annotationRepresentedObject:stateDictionary:annotationWantsIndicatorAnimation:exploreAnnotationRepresentedObject:highlightSelection:] (in IDEKit)
8 0x000000010d7f1e7b -[IDEEditorContext _notifyDelegateAndOpenEditorOpenSpecifier:updateHistory:] (in IDEKit)
9 0x000000010d7f199c -[IDEEditorContext _openEditorOpenSpecifier:updateHistory:] (in IDEKit)
10 0x000000010d7f18ba -[IDEEditorContext openEditorOpenSpecifier:] (in IDEKit)
11 0x000000010d7f189f -[IDEEditorModeViewController openEditorOpenSpecifier:editorContext:] (in IDEKit)
12 0x000000010d7f176e -[IDEEditorArea _openEditorOpenSpecifier:editorContext:takeFocus:] (in IDEKit)
13 0x000000010d8d5174 __108+[IDEEditorCoordinator _doOpenEditorOpenSpecifier:forWorkspaceTabController:editorContext:target:takeFocus:]_block_invoke (in IDEKit)
14 0x000000010d7f16cc +[IDEEditorCoordinator _doOpenWithWorkspaceTabController:editorContext:target:allowFallback:documentURL:usingBlock:] (in IDEKit)
15 0x000000010d7f112d +[IDEEditorCoordinator _doOpenEditorOpenSpecifier:forWorkspaceTabController:editorContext:target:takeFocus:] (in IDEKit)
16 0x000000010d7f0d45 -[_IDEOpenRequest _runIfNecessary] (in IDEKit)
17 0x00007fff98955395 __NSFireDelayedPerform (in Foundation)
18 0x00007fff909bd804 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ (in CoreFoundation)
19 0x00007fff909bd31d __CFRunLoopDoTimer (in CoreFoundation)
20 0x00007fff909a2ad9 __CFRunLoopRun (in CoreFoundation)
21 0x00007fff909a20e2 CFRunLoopRunSpecific (in CoreFoundation)
22 0x00007fff92e5eeb4 RunCurrentEventLoopInMode (in HIToolbox)
23 0x00007fff92e5ec52 ReceiveNextEventCommon (in HIToolbox)
24 0x00007fff92e5eae3 BlockUntilNextEventMatchingListInMode (in HIToolbox)
25 0x00007fff96036563 _DPSNextEvent (in AppKit)
26 0x00007fff96035e22 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] (in AppKit)
27 0x00007fff9602d1d3 -[NSApplication run] (in AppKit)
28 0x00007fff95fd1c06 NSApplicationMain (in AppKit)
29 0x000000010caf9b6f (in Xcode)
30 0x000000010caf9b00 (in Xcode)
31 0x0000000000000002
Object: <IBStoryboardDocument: 0x409ec3340>
Method: -updateChangeCount:
Thread: <NSThread: 0x40030a1a0>{name = (null), num = 1}
Please file a bug at http://bugreport.apple.com with this warning message and any useful information you can provide.
Both log outputs are very similar. There is an additional line in the call stack of the 2nd output at line 6: [IDEEditorContext _openNavigableItem:withContentsOfURL:shouldInstallEditorBlock:] (in IDEKit). And line 11 (10 on the 1st) references the method IDEEditorModeViewController instead of IDEEditorGeniusMode. Otherwise the log outputs are identical.
Note, this 2nd storyboard that we originally received this error on would not have had a problem with Git merge conflicts as I am the only developer to have worked on this storyboard. I've never needed to merge commits to this repository at all as I'm the sole contributing developer on it.

As Marcel states: this sometimes occurs on a merge. But his answer does not point to anything specific, so let me give a hint what we had to deal with a few times. We had some unreadable storyboards after a merge on a file that was changed locally.
We could fix them by opening the storyboard in text-mode and checking every segue reference in the end of the storyboard file:
<inferredMetricsTieBreakers>
<segue reference="gJw-Ph-JeV"/>
<segue reference="Olp-GN-hLL"/>
<segue reference="aFq-vB-ngK"/>
</inferredMetricsTieBreakers>
Search the storyboard for the quoted values. If you cannot find a second match for this string, comment out this line with <!-- -->. After removing all invalid segue references, Xcode was able to open the storyboards again.

Is the project using any custom fonts?
I just spent all day long dealing with the exact same issue (tried multiple computers with multiple XCode versions), and immediately after I installed the two custom fonts we had in the project the Storyboards were able to open.
I received a mix of both the "invalidate" exception as well as an array exception. And the array exception led a fellow developer to a similar StackOverflow question where he realized we had custom fonts.

This problem is being caused by merging each others storyboard changes. The storyboard format is XML based. When you make changes, these changes are being saved in the project file. Xcode seems to be non-deterministic in the way it saves the structure of this file, things can be sorted differently, objects can appear in different places in the structure. This doesn't matter when you are working on your own, but when two or more people make a change to the storyboard, merges can get very ugly. Even though git seems to be able to merge the files fine, the structure of the file gets corrupted and you won't be able to open your storyboards.
Commit your changes to storyboards early and push. Allways pull before making changes to the storyboard. Don't merge, pick one version and continue.
You are probably better off treating your xcode project files as binary files in your git repository. See http://robots.thoughtbot.com/post/33796217972/xcode-and-git-bridging-the-gap for a good reading on this.
As for your situation, you probably have to checkout a know good version of your project file and rebuild your changes in the storyboard from there.

This worked for me:
in environment with error delete .storyboard file (move to trash).
copy .storyboard from environment that works and send it (solo file) to the environment that does not work (email, thumb drive, Skype, however).
drag and drop the .storyboard back into the broken environment (copy and save)
fixed.

Related

Xcode crashes due to 'There can only be one document registered with a given URL.'

I am not able to start up XCode. Whenever it starts it just crashes with this error:
Application Specific Information:
ProductBuildVersion: 8E3004b
ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEFrameworks/IDEFrameworks-12175.1/IDEKit/Application/IDEDocumentController.m:2136
Details: There can only be one document registered with a given URL. newDocument:<IDEWorkspaceDocument: 0x7ff6612d6cd0>( 0 -[IDEWorkspaceDocument init] (in IDEKit)
1 -[NSDocument initForURL:withContentsOfURL:ofType:error:] (in AppKit)
2 -[IDEWorkspaceDocument initForURL:withContentsOfURL:ofType:error:] (in IDEKit)
3 -[NSDocumentController makeDocumentForURL:withContentsOfURL:ofType:error:] (in AppKit)
4 __104-[NSDocumentController makeDocumentForURL:withContentsOfURL:alternateContents:ofType:completionHandler:]_block_invoke (in AppKit)
5 -[NSDocumentController makeDocumentForURL:withContentsOfURL:alternateContents:ofType:completionHandler:] (in AppKit)
6 __89-[NSDocumentController reopenDocumentForURL:withContentsOfURL:display:completionHandler:]_block_invoke (in AppKit)
How can I get Xcode start again?
EDIT:
Version of the xcode is 8.3.3
For me, the solution was to remove all custom color pickers in:
~/Library/ColorPickers/
Remove this folder
/Users/<your user name>/Library/Saved\ Application\ State/com.apple.dt.Xcode.savedState

Xcode 6 crashes on submitting Archive

Today I uploaded my first build of first app successfully to App Store for beta testing. After making a few changes, when I tried to submit the new archive again Xcode crashed, and still crashes.
It's the log:
Process: Xcode [36810]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 6.3.2 (7718)
Build Info: IDEFrameworks-7718000000000000~2
App Item ID: 497799835
App External ID: 812404257
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: Xcode [36810]
User ID: 501
Date/Time: 2015-06-17 21:59:26.432 +0430
OS Version: Mac OS X 10.10.3 (14D136)
Report Version: 11
Anonymous UUID: A70B5585-6ADF-B647-C184-94420293DB9F
Sleep/Wake UUID: 536542A5-38C8-405F-8A5E-28DBE775C033
Time Awake Since Boot: 110000 seconds
Time Since Wake: 18000 seconds
Crashed Thread: 14 Dispatch queue: NSOperationQueue 0x7fdb9771af00 :: NSOperation 0x7fdb97679160 (QOS: USER_INITIATED)
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 6D2105
ASSERTION FAILURE in /SourceCache/IDEFrameworks/IDEFrameworks-7718/IDEFoundation/Issues/IDEIssueManager.m:457
Details: This method must only be called on the main thread
Object: <IDEIssueManager>
Method: +_issueProviderInfo
Thread: <NSThread: 0x7fdb971db920>{number = 80, name = (null)}
Hints: None
Backtrace:
0 0x0000000102e28b6a -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in IDEKit)
1 0x0000000101b765df _DVTAssertionHandler (in DVTFoundation)
2 0x0000000101b768ce _DVTAssertionFailureHandler (in DVTFoundation)
3 0x00000001024f248e +[IDEIssueManager _issueProviderInfo] (in IDEFoundation)
4 0x00000001024f1b0d -[IDEIssueManager _updateIssueProviders] (in IDEFoundation)
5 0x0000000101b893de __73-[DVTObservingBlockToken observeValueForKeyPath:ofObject:change:context:]_block_invoke (in DVTFoundation)
6 0x0000000101afed5c DVTInvokeWithStrongOwnership (in DVTFoundation)
7 0x00000001019b03e4 -[DVTObservingBlockToken observeValueForKeyPath:ofObject:change:context:] (in DVTFoundation)
8 0x00007fff8a8af0f3 NSKeyValueNotifyObserver (in Foundation)
9 0x00007fff8a8bbd68 NSKeyValueDidChange (in Foundation)
10 0x00007fff8a87497d -[NSObject(NSKeyValueObserverNotification) didChangeValueForKey:] (in Foundation)
11 0x00007fff8befddaf doSetValuesInSourceWithKVO (in CoreFoundation)
12 0x00007fff8befdc46 _CFXPreferencesReplaceValuesInNamedVolatileSource (in CoreFoundation)
13 0x00007fff8aa4b027 -[NSUserDefaults(NSUserDefaults) setVolatileDomain:forName:] (in Foundation)
14 0x0000000119e34a13 -[NSUserDefaults(ITunesConnectFoundationExtensions) REPLACEMENT_setVolatileDomain:forName:] (in ITunesConnectFoundation)
15 0x0000000119e34f87 -[NSUserDefaults(ITunesConnectFoundationExtensions) synchronizeRegistrationDomains] (in ITunesConnectFoundation)
16 0x0000000119e34d5d -[NSUserDefaults(ITunesConnectFoundationExtensions) registerPriorityDefaults:] (in ITunesConnectFoundation)
17 0x0000000119e2669e -[MZJSONServiceClient processApplicationSettings:] (in ITunesConnectFoundation)
18 0x0000000119e26d7d -[MZJSONServiceClient connectionDidFinishLoading:] (in ITunesConnectFoundation)
19 0x00007fff8846d24d __65-[NSURLConnectionInternal _withConnectionAndDelegate:onlyActive:]_block_invoke (in CFNetwork)
20 0x00007fff8846d0b1 -[NSURLConnectionInternal _withConnectionAndDelegate:onlyActive:] (in CFNetwork)
21 0x00007fff8846cfb7 -[NSURLConnectionInternal _withActiveConnectionAndDelegate:] (in CFNetwork)
22 0x00007fff8846df74 ___ZN27URLConnectionClient_Classic26_delegate_didFinishLoadingEU13block_pointerFvvE_block_invoke (in CFNetwork)
23 0x00007fff88521703 ___ZN27URLConnectionClient_Classic18_withDelegateAsyncEPKcU13block_pointerFvP16_CFURLConnectionPK33CFURLConnectionClientCurrent_VMaxE_block_invoke_2 (in CFNetwork)
24 0x00007fff883c2cec RunloopBlockContext::_invoke_block(void const*, void*) (in CFNetwork)
25 0x00007fff8bf0e664 CFArrayApplyFunction (in CoreFoundation)
26 0x00007fff883c2bad RunloopBlockContext::perform() (in CFNetwork)
27 0x00007fff883c2998 MultiplexerSource::perform() (in CFNetwork)
28 0x00007fff883c27ba MultiplexerSource::_perform(void*) (in CFNetwork)
29 0x00007fff8bf42a01 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ (in CoreFoundation)
30 0x00007fff8bf34b8d __CFRunLoopDoSources0 (in CoreFoundation)
31 0x00007fff8bf341bf __CFRunLoopRun (in CoreFoundation)
32 0x00007fff8bf33bd8 CFRunLoopRunSpecific (in CoreFoundation)
33 0x00007fff8a8fda59 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] (in Foundation)
34 0x00007fff8a91bcce -[NSRunLoop(NSRunLoop) runUntilDate:] (in Foundation)
35 0x0000000119e25d00 -[MZJSONServiceClient getResultDictionary] (in ITunesConnectFoundation)
36 0x0000000119e28eb3 -[MZLabelServiceClient invokeSOAPCall] (in ITunesConnectFoundation)
37 0x0000000119e3097d -[MZWebServiceOperationWorker execute] (in ITunesConnectFoundation)
38 0x0000000119e30e11 -[MZWebServiceWorker run] (in ITunesConnectFoundation)
39 0x0000000119df854d -[MZWorkItem main] (in ITunesConnectFoundation)
40 0x00007fff8a8c6a6c -[__NSOperationInternal _start:] (in Foundation)
41 0x00007fff8a8c6543 __NSOQSchedule_f (in Foundation)
42 0x00007fff89468c13 _dispatch_client_callout (in libdispatch.dylib)
43 0x00007fff8946c365 _dispatch_queue_drain (in libdispatch.dylib)
44 0x00007fff8946decc _dispatch_queue_invoke (in libdispatch.dylib)
45 0x00007fff8946b6b7 _dispatch_root_queue_drain (in libdispatch.dylib)
46 0x00007fff89479fe4 _dispatch_worker_thread3 (in libdispatch.dylib)
47 0x00007fff86f91637 _pthread_wqthread (in libsystem_pthread.dylib)
48 0x00007fff86f8f40d start_wqthread (in libsystem_pthread.dylib)
Note: I can validate the Archive without error.
Will re-installing XCode help me to fix it?
Close any projects or workspace windows you have open in Xcode but leave Organizer window open and re-submit worked for me.
Just got this problem. Seems to work if you close all other Xcode windows but keep the organizer window open.
Had the same problem - uploaded my .ipa through the Application Loader.
The original question is: "Will re-installing XCode help me to fix it?"
The answer is: "No." Re-installation does not help the problem. The bug is pretty serious though, since submitting an app is central to app development. A fix should be in the App Store asap. Hence updating later may help.
Following steps worked for me:
Archive the project.
Open Organizer
Press the top-left cross button of XCode which will close all projects without quiting XCode and Organiser will be opened
Now resubmit the archive from organiser.
Had this problem today. I was only able to successfully upload the Archive when the organizer window was open and all Xcode projects were closed.
I created an .ipa file using the Export utility in Organizer, then ran Application Loader. Selected the 'Deliver Your App' button. Choose the new created ipa file and the file appeared in iTuneConnect under the pre-release tab as expected for TestFlight distribution.
Had the same problem today. Problem turned out I still had the Reveal Framework included in my project. Make sure you don't have any non-public API usage in your archive.
I encountered similar situation. However, my solution was somehow different.
Noticing that you are trying to submit next build, please make sure your previous build is excluded from App Store submit form before uploading new build.
I'm not sure why this has to be an issue, but it seems like that the submit form should be cleared before receiving new build.
You might need to accept some new user agreements, try going to Apple Developer Member Center and see if they're any new agreements you need to accept.
If that doesn't work try this: open Xcode and go to [ Preferences ] -> [ Accounts ], select your Apple ID and click on [ View Details... ]. Once you do that click on the refresh icon at the bottom left. If you're missing anything it will let you know.
If both of those don't work go back to the archive window in XCode and click on export on the right-hand side underneath the submit button. Save it where ever you want but remember the location. Once exported go back to XCode and go to [ Open Developer Tools ] -> [ Application Loader ]. You can submit your new version of your app through that.
If none of those work then I have no idea, maybe someone else knows.
I had the same issue at June 17 night. I reinstalled my Xcode, and had the same issue. Looks like Apple updated something at that day, since I noticed the website of Member Center, the MAC certificate is also there. (YES!!! apple only charge once for iPhone and Mac)
If that doesn't work, than it could also be that the used Certificate has expired. So check if your Certificate is still valid.
Archive using Xcode 6.4, submit using Xcode 7. Submission successful

Xcode crashes when putting submitting my app to the App Store Why? [duplicate]

Today I uploaded my first build of first app successfully to App Store for beta testing. After making a few changes, when I tried to submit the new archive again Xcode crashed, and still crashes.
It's the log:
Process: Xcode [36810]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 6.3.2 (7718)
Build Info: IDEFrameworks-7718000000000000~2
App Item ID: 497799835
App External ID: 812404257
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: Xcode [36810]
User ID: 501
Date/Time: 2015-06-17 21:59:26.432 +0430
OS Version: Mac OS X 10.10.3 (14D136)
Report Version: 11
Anonymous UUID: A70B5585-6ADF-B647-C184-94420293DB9F
Sleep/Wake UUID: 536542A5-38C8-405F-8A5E-28DBE775C033
Time Awake Since Boot: 110000 seconds
Time Since Wake: 18000 seconds
Crashed Thread: 14 Dispatch queue: NSOperationQueue 0x7fdb9771af00 :: NSOperation 0x7fdb97679160 (QOS: USER_INITIATED)
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 6D2105
ASSERTION FAILURE in /SourceCache/IDEFrameworks/IDEFrameworks-7718/IDEFoundation/Issues/IDEIssueManager.m:457
Details: This method must only be called on the main thread
Object: <IDEIssueManager>
Method: +_issueProviderInfo
Thread: <NSThread: 0x7fdb971db920>{number = 80, name = (null)}
Hints: None
Backtrace:
0 0x0000000102e28b6a -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in IDEKit)
1 0x0000000101b765df _DVTAssertionHandler (in DVTFoundation)
2 0x0000000101b768ce _DVTAssertionFailureHandler (in DVTFoundation)
3 0x00000001024f248e +[IDEIssueManager _issueProviderInfo] (in IDEFoundation)
4 0x00000001024f1b0d -[IDEIssueManager _updateIssueProviders] (in IDEFoundation)
5 0x0000000101b893de __73-[DVTObservingBlockToken observeValueForKeyPath:ofObject:change:context:]_block_invoke (in DVTFoundation)
6 0x0000000101afed5c DVTInvokeWithStrongOwnership (in DVTFoundation)
7 0x00000001019b03e4 -[DVTObservingBlockToken observeValueForKeyPath:ofObject:change:context:] (in DVTFoundation)
8 0x00007fff8a8af0f3 NSKeyValueNotifyObserver (in Foundation)
9 0x00007fff8a8bbd68 NSKeyValueDidChange (in Foundation)
10 0x00007fff8a87497d -[NSObject(NSKeyValueObserverNotification) didChangeValueForKey:] (in Foundation)
11 0x00007fff8befddaf doSetValuesInSourceWithKVO (in CoreFoundation)
12 0x00007fff8befdc46 _CFXPreferencesReplaceValuesInNamedVolatileSource (in CoreFoundation)
13 0x00007fff8aa4b027 -[NSUserDefaults(NSUserDefaults) setVolatileDomain:forName:] (in Foundation)
14 0x0000000119e34a13 -[NSUserDefaults(ITunesConnectFoundationExtensions) REPLACEMENT_setVolatileDomain:forName:] (in ITunesConnectFoundation)
15 0x0000000119e34f87 -[NSUserDefaults(ITunesConnectFoundationExtensions) synchronizeRegistrationDomains] (in ITunesConnectFoundation)
16 0x0000000119e34d5d -[NSUserDefaults(ITunesConnectFoundationExtensions) registerPriorityDefaults:] (in ITunesConnectFoundation)
17 0x0000000119e2669e -[MZJSONServiceClient processApplicationSettings:] (in ITunesConnectFoundation)
18 0x0000000119e26d7d -[MZJSONServiceClient connectionDidFinishLoading:] (in ITunesConnectFoundation)
19 0x00007fff8846d24d __65-[NSURLConnectionInternal _withConnectionAndDelegate:onlyActive:]_block_invoke (in CFNetwork)
20 0x00007fff8846d0b1 -[NSURLConnectionInternal _withConnectionAndDelegate:onlyActive:] (in CFNetwork)
21 0x00007fff8846cfb7 -[NSURLConnectionInternal _withActiveConnectionAndDelegate:] (in CFNetwork)
22 0x00007fff8846df74 ___ZN27URLConnectionClient_Classic26_delegate_didFinishLoadingEU13block_pointerFvvE_block_invoke (in CFNetwork)
23 0x00007fff88521703 ___ZN27URLConnectionClient_Classic18_withDelegateAsyncEPKcU13block_pointerFvP16_CFURLConnectionPK33CFURLConnectionClientCurrent_VMaxE_block_invoke_2 (in CFNetwork)
24 0x00007fff883c2cec RunloopBlockContext::_invoke_block(void const*, void*) (in CFNetwork)
25 0x00007fff8bf0e664 CFArrayApplyFunction (in CoreFoundation)
26 0x00007fff883c2bad RunloopBlockContext::perform() (in CFNetwork)
27 0x00007fff883c2998 MultiplexerSource::perform() (in CFNetwork)
28 0x00007fff883c27ba MultiplexerSource::_perform(void*) (in CFNetwork)
29 0x00007fff8bf42a01 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ (in CoreFoundation)
30 0x00007fff8bf34b8d __CFRunLoopDoSources0 (in CoreFoundation)
31 0x00007fff8bf341bf __CFRunLoopRun (in CoreFoundation)
32 0x00007fff8bf33bd8 CFRunLoopRunSpecific (in CoreFoundation)
33 0x00007fff8a8fda59 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] (in Foundation)
34 0x00007fff8a91bcce -[NSRunLoop(NSRunLoop) runUntilDate:] (in Foundation)
35 0x0000000119e25d00 -[MZJSONServiceClient getResultDictionary] (in ITunesConnectFoundation)
36 0x0000000119e28eb3 -[MZLabelServiceClient invokeSOAPCall] (in ITunesConnectFoundation)
37 0x0000000119e3097d -[MZWebServiceOperationWorker execute] (in ITunesConnectFoundation)
38 0x0000000119e30e11 -[MZWebServiceWorker run] (in ITunesConnectFoundation)
39 0x0000000119df854d -[MZWorkItem main] (in ITunesConnectFoundation)
40 0x00007fff8a8c6a6c -[__NSOperationInternal _start:] (in Foundation)
41 0x00007fff8a8c6543 __NSOQSchedule_f (in Foundation)
42 0x00007fff89468c13 _dispatch_client_callout (in libdispatch.dylib)
43 0x00007fff8946c365 _dispatch_queue_drain (in libdispatch.dylib)
44 0x00007fff8946decc _dispatch_queue_invoke (in libdispatch.dylib)
45 0x00007fff8946b6b7 _dispatch_root_queue_drain (in libdispatch.dylib)
46 0x00007fff89479fe4 _dispatch_worker_thread3 (in libdispatch.dylib)
47 0x00007fff86f91637 _pthread_wqthread (in libsystem_pthread.dylib)
48 0x00007fff86f8f40d start_wqthread (in libsystem_pthread.dylib)
Note: I can validate the Archive without error.
Will re-installing XCode help me to fix it?
Close any projects or workspace windows you have open in Xcode but leave Organizer window open and re-submit worked for me.
Just got this problem. Seems to work if you close all other Xcode windows but keep the organizer window open.
Had the same problem - uploaded my .ipa through the Application Loader.
The original question is: "Will re-installing XCode help me to fix it?"
The answer is: "No." Re-installation does not help the problem. The bug is pretty serious though, since submitting an app is central to app development. A fix should be in the App Store asap. Hence updating later may help.
Following steps worked for me:
Archive the project.
Open Organizer
Press the top-left cross button of XCode which will close all projects without quiting XCode and Organiser will be opened
Now resubmit the archive from organiser.
Had this problem today. I was only able to successfully upload the Archive when the organizer window was open and all Xcode projects were closed.
I created an .ipa file using the Export utility in Organizer, then ran Application Loader. Selected the 'Deliver Your App' button. Choose the new created ipa file and the file appeared in iTuneConnect under the pre-release tab as expected for TestFlight distribution.
Had the same problem today. Problem turned out I still had the Reveal Framework included in my project. Make sure you don't have any non-public API usage in your archive.
I encountered similar situation. However, my solution was somehow different.
Noticing that you are trying to submit next build, please make sure your previous build is excluded from App Store submit form before uploading new build.
I'm not sure why this has to be an issue, but it seems like that the submit form should be cleared before receiving new build.
You might need to accept some new user agreements, try going to Apple Developer Member Center and see if they're any new agreements you need to accept.
If that doesn't work try this: open Xcode and go to [ Preferences ] -> [ Accounts ], select your Apple ID and click on [ View Details... ]. Once you do that click on the refresh icon at the bottom left. If you're missing anything it will let you know.
If both of those don't work go back to the archive window in XCode and click on export on the right-hand side underneath the submit button. Save it where ever you want but remember the location. Once exported go back to XCode and go to [ Open Developer Tools ] -> [ Application Loader ]. You can submit your new version of your app through that.
If none of those work then I have no idea, maybe someone else knows.
I had the same issue at June 17 night. I reinstalled my Xcode, and had the same issue. Looks like Apple updated something at that day, since I noticed the website of Member Center, the MAC certificate is also there. (YES!!! apple only charge once for iPhone and Mac)
If that doesn't work, than it could also be that the used Certificate has expired. So check if your Certificate is still valid.
Archive using Xcode 6.4, submit using Xcode 7. Submission successful

Xcode crashing on startup possibly due to too many open projects

I just got a new Mac and downloaded Xcode so everything is fresh. On opening Xcode for the first time I accidentally told it to open my src/ folder instead of /src/myLatestProject so my hunch is Xcode went and tried to open every project in my src/ directory (hundreds). It beachballed for a few seconds and then crashed. The issue now is that Xcode seems to have remembered that I want that multitude of projects opened at app startup or it's trying to parse hundreds of git repos and I'm stuck in open/beachball/crash purgatory. How can I reset Xcode's prefs so it won't try to be so helpful and open every bit of source code on my computer?
EDIT: I've confirmed it's only crashing for my account. If I create a test user and open Xcode, everything is fine.
Application Specific Information:
ProductBuildVersion: 5A3005
ASSERTION FAILURE in /SourceCache/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-3575/Xcode3Sources/XcodeIDE/Frameworks/DevToolsBase/pbxcore/Xcode3Model/Xcode3OCUnitTestableDataSource.m:191
Details: ([_indexableIdsToTestableTokens objectForKey:indexableIdentifier]) should be nil, but it is <Xcode3OCUnitTestableDataSourceToken: 0x7fe73b531ae0>
Object: <Xcode3OCUnitTestableDataSource: 0x7fe7359c79f0>
Method: -setTestableToken:indexableIdentifier:
Thread: <NSThread: 0x7fe732415570>{name = (null), num = 1}
Hints: None
Backtrace:
0 0x0000000109575ea8 -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:messageFormat:arguments:] (in IDEKit)
1 0x00000001082fc7a5 _DVTAssertionHandler (in DVTFoundation)
2 0x00000001082fcad4 _DVTAssertionFailureHandler (in DVTFoundation)
3 0x000000010e8ef3ca -[Xcode3OCUnitTestableDataSource setTestableToken:indexableIdentifier:] (in DevToolsCore)
4 0x000000010e8f2261 -[Xcode3OCUnitTestableDataSourceToken _initWithDataSource:indexableIdentifier:callbackBlock:] (in DevToolsCore)
5 0x000000010e8ef87d +[Xcode3OCUnitTestableDataSource testableDataSourceTokenForWorkspace:indexableIdentifier:callbackBlock:] (in DevToolsCore)
6 0x000000010ea0a464 -[Xcode3OCUnitTestable initWithTarget:] (in DevToolsCore)
7 0x000000010e9d7b69 -[Xcode3Project _updateTestablesForTargetProxies:] (in DevToolsCore)
8 0x000000010e9d074d -[Xcode3Project syncTargetProxiesWithProjectTargets] (in DevToolsCore)
9 0x000000010830e618 -[NSObject(DVTObservingConvenience) _dvt_newObserverForKeyPath:options:owner:withHandlerBlock:] (in DVTFoundation)
10 0x000000010828e5d3 -[NSObject(DVTObservingConvenience) dvt_newObserverForKeyPath:options:withHandlerBlock:] (in DVTFoundation)
11 0x000000010e9d1815 -[Xcode3Project initWithFilePath:extension:workspace:error:] (in DevToolsCore)
12 0x0000000108d899ef __73+[IDEContainer retainedContainerAtFilePath:fileDataType:workspace:error:]_block_invoke_2 (in IDEFoundation)
13 0x00007fff91d9d2ad _dispatch_client_callout (in libdispatch.dylib)
14 0x00007fff91d9e166 _dispatch_barrier_sync_f_invoke (in libdispatch.dylib)
15 0x000000010833a0ec DVTSyncPerformBlock (in DVTFoundation)
16 0x000000010825dfe3 -[DVTDispatchLock performLockedBlock:] (in DVTFoundation)
17 0x0000000108d893f5 __73+[IDEContainer retainedContainerAtFilePath:fileDataType:workspace:error:]_block_invoke (in IDEFoundation)
18 0x000000010830f2ed -[DVTModelObjectGraph performBlockCoalescingModelChanges:] (in DVTFoundation)
19 0x0000000108cc9579 +[IDEContainer retainedContainerAtFilePath:fileDataType:workspace:error:] (in IDEFoundation)
20 0x0000000108d9eb40 -[IDEFileReference _recalculateReferencedContainer] (in IDEFoundation)
21 0x0000000108cdcf48 -[IDEFileReference referencedContainer] (in IDEFoundation)
22 0x0000000108ce4200 -[IDEContainerQuery _traverseContainerGraphObject:forDeletion:checkedContainers:insertedMatches:deletedMatches:] (in IDEFoundation)
23 0x0000000108ce617b -[IDEContainerQuery _traverseContainerGraphObjects:forDeletion:insertedMatches:deletedMatches:] (in IDEFoundation)
24 0x0000000108ce5ec4 -[IDEContainerQuery _objectsDidChange:] (in IDEFoundation)
25 0x00007fff8d6eefcc __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ (in CoreFoundation)
26 0x00007fff8d5e2c5d _CFXNotificationPost (in CoreFoundation)
27 0x00007fff8a3c14aa -[NSNotificationCenter postNotificationName:object:userInfo:] (in Foundation)
28 0x00000001082a7085 -[DVTModelObjectGraph _coalescingTick] (in DVTFoundation)
29 0x0000000108cd1912 -[IDEGroup _setSubitems:] (in IDEFoundation)
30 0x0000000108cdee30 -[IDEFolder _updateSubitemsWithFileNames:] (in IDEFoundation)
31 0x0000000108d8eedb __32-[IDEFolder _filePathDidChange:]_block_invoke94 (in IDEFoundation)
32 0x0000000108339fdc __DVTAsyncPerformBlock_block_invoke (in DVTFoundation)
33 0x00007fff8d6517cc __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ (in CoreFoundation)
34 0x00007fff8d642ee5 __CFRunLoopDoBlocks (in CoreFoundation)
35 0x00007fff8d64282b __CFRunLoopRun (in CoreFoundation)
36 0x00007fff8d642275 CFRunLoopRunSpecific (in CoreFoundation)
37 0x00007fff8b8aef0d RunCurrentEventLoopInMode (in HIToolbox)
38 0x00007fff8b8aecb7 ReceiveNextEventCommon (in HIToolbox)
39 0x00007fff8b8aeabc _BlockUntilNextEventMatchingListInModeWithFilter (in HIToolbox)
40 0x00007fff8ad0e28e _DPSNextEvent (in AppKit)
41 0x00007fff8ad0d8db -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] (in AppKit)
42 0x00007fff8ad019cc -[NSApplication run] (in AppKit)
43 0x00007fff8acec803 NSApplicationMain (in AppKit)
44 0x00007fff89ff25fd start (in libdyld.dylib)
Not sure which one fixed it but I ran the following in terminal and now it works again:
cd ~/Library
sudo rm -rf './Preferences/com.apple.dt.Xcode.plist' './Autosave Information/com.apple.dt.Xcode.plist' './Autosave Information/Unsaved Xcode Document.xcworkspace' './Caches/com.apple.dt.Xcode'
WARNING: Note this may delete other preferences such as key bindings so beware if you have a lot of customization of your xcode environment.
Open finder and go to following path and delete the folders made their, these are the folders made whenever we open any project in xcode temporarily:
/Users/MyMac/Library/Developer/Xcode/DerivedData/
On my Xcode6/Yosemite mac there is no "Autosave Information" folder, so I deleted ~/Library/Saved Application State/com.apple.dt.Xcode.savedState folder instead and it stopped crashing.
If you have any open swift file in a new window (for example when you double click on a .swift file in xCode and it opens in a new window) when xCode opens this might be an issue. I think I had this window opened when closing xCode, then when opening xCode this window opens up again and for some reason crashes xCode. Try to close this open window quickly before it crashes. Strange, but that worked for me.
The scenario to make Xcode crashing was a bit different on my side. Indeed I had the same callstack error:
Application Specific Information:
ProductBuildVersion: 5A3005
ASSERTION FAILURE in /SourceCache/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-3575/Xcode3Sources/XcodeIDE/Frameworks/DevToolsBase/pbxcore/Xcode3Model/Xcode3OCUnitTestableDataSource.m:191
Details: ([_indexableIdsToTestableTokens objectForKey:indexableIdentifier]) should be nil, but it is <Xcode3OCUnitTestableDataSourceToken: 0x7fe73b531ae0>
Object: <Xcode3OCUnitTestableDataSource: 0x7fe7359c79f0>
Method: -setTestableToken:indexableIdentifier:
Thread: <NSThread: 0x7fe732415570>{name = (null), num = 1}
Hints: None
But I had to duplicate an existing project (.xcodeproj file) in order to have in my workspace an app depending on other projects (Target Dependencies in Build Phases) in my workspace (used as a debug app) and an app not depending on anything only linking to the resulting build output of the corresponding projects target (in my case frameworks inside Link Binary With Libraries in Build Phases). The issue was that each time I imported the duplicated project to my workspace it crashed Xcode... As the crash stack trace was talking about test things I just went through the project.pbxproj and removed all occurrences of test string in that file (well I tool care about section to avoid corrupting my file).
Something was going wrong with the duplicated xctest target inside the prject. Once I tried again to import it again in my workspace it worked fine.
Hope it can help
I have removed entirely the folder Library/Developer :
Close XCode
rm -r /Library/Developer
And say yes for every files
No solution worked for me in case you have workspace . But i found out one ..
delete workspace file if you have one . install pod again using "pod install" in terminal (need to move to your project folder).
open workspace again .. and it will solve this issue
You could also do one thing (if you are using pods) :-
Right click on your xcworkspace
click on 'Show Package Contents'
Delete xcuserdata folder
relaunch xcode

xcode crashing when opening the assistant editior

Got the new Retina MacBook and it has not been playing nice with xCode. If i make a new project it works, but if i ty triggering the assistant editor it will freeze. If i save a new project and reopen it, it will freeze. I did install the 4.5 DP and uninstalled it and the latest nonbeta version of xcode and the problem still persists. Anyone know what could be the issue? If i make a new user account xcode is behaving normally. Anyone know of a fix? Crash large too large for me to post.
Date/Time: 2012-06-30 03:10:29 -0700
OS Version: 10.7.4 (Build 11E2620)
Architecture: x86_64
Report Version: 9
Command: Xcode
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Version: 4.3.3 (1178)
Build Version: 3
Project Name: IDEApplication
Source Version: 1178000000000000
App Item ID: 497799835
App External ID: 8553856
Parent: launchd [111]
PID: 234
Event: hang
Duration: 1.76s
Steps: 18 (100ms sampling interval)
Pageins: 44
Pageouts: 0
Process: Xcode [234]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Architecture: x86_64
UID: 501
Thread 0x810 DispatchQueue 1
User stack:
18 ??? (in Xcode) [0x107b73eec]
18 NSApplicationMain + 867 (in AppKit) [0x7fff85edf244]
18 -[NSApplication run] + 555 (in AppKit) [0x7fff85c630c6]
18 -[IDEApplication sendEvent:] + 366 (in IDEKit) [0x1085c2dd1]
18 -[NSApplication sendEvent:] + 4282 (in AppKit) [0x7fff85ccc536]
18 -[NSApplication _handleKeyEquivalent:] + 526 (in AppKit) [0x7fff85dd3175]
18 -[NSMenu performKeyEquivalent:] + 281 (in AppKit) [0x7fff85dd4524]
18 -[NSCarbonMenuImpl performActionWithHighlightingForItemAtIndex:] + 125 (in AppKit) [0x7fff85e56932]
18 -[NSMenuItem _corePerformAction] + 399 (in AppKit) [0x7fff85e56bfb]
18 -[IDEApplication sendAction:to:from:] + 154 (in IDEKit) [0x1085c7096]
18 -[DVTApplication sendAction:to:from:] + 318 (in DVTKit) [0x107e76866]
18 -[NSApplication sendAction:to:from:] + 139 (in AppKit) [0x7fff85d69f7e]
18 -[NSObject performSelector:withObject:] + 61 (in CoreFoundation) [0x7fff8a15270d]
18 -[IDEWorkspaceTabController _changeToEditorMode:] + 361 (in IDEKit) [0x108728088]
18 _NSSetIntValueAndNotify + 259 (in Foundation) [0x7fff86f8353f]
18 -[IDEEditorArea setEditorMode:] + 384 (in IDEKit) [0x108604a61]
18 -[IDEEditorArea _refreshEditorContextsAndPreserveCurrentEditorHistoryStack:] + 642 (in IDEKit) [0x108604d8e]
18 +[DVTLayoutView_ML _recursivelyLayoutSubviewsOfView:populatingSetWithLaidOutViews:] + 108 (in DVTKit) [0x107e858ec]
18 +[DVTLayoutView_ML
For me, the solution was simple:
Close Xcode
Delete the following folders/files from myProject.xcodeproj (or .xcworkspace if you're using cocoapods) (right click on the file and choose “Show Package Contents”)
/xcuserdata
/project.xcworkspace
Reopen Xcode and enjoy
The crash is occurring due to a corruption in project's userdata content.
Also, you should note that after deleting those files, the window size and position will reset and the opened tabs will be all closed.
I experienced similar problems on my Retina MacBook. The workaround is to specify "Open in Low Resolution" for Xcode in the Finder. From http://support.apple.com/kb/HT5266:
Quit the application if it is currently open.
In the Finder, choose Applications from the Go menu.
In the Applications folder that opens, click the application's icon so it is highlighted.
Choose Get Info from the File menu.
Place a checkmark next to "Open in Low Resolution" to enable Low Resolution mode.
Close the window and double click the Application to reopen it.
This does have an impact on text quality, though it's not awful (subjective). Hopefully Apple will update Xcode soon.
I am facing the same problem .... I solve it after make changes as per screenshot -
it works for me.

Resources