2

I am trying to archive my iOS app and upload it to iTunes connect.

After selecting Product->Archive in XCode, the process does not go further starting from this point.enter image description here

I left it for more than 10 hours, but nothing seems changed.

There is another similar question in Stackoverflow though, he takes long to archive the app and takes forever to upload to App Store. In my case, it takes me forever even to archive the app. These are the solutions for other developers of that question:

  • delete AppleID certificates in Keychain
  • remove iMessage Encrption Key
  • able/unable Automatically manage signing

I tried all the above solutions, all certificates are updated again after this issue appears. None of them work for me. I am totally stuck at here. Any suggestion is appreciated. Thanks!

I am using XCode 8.2.1, macOS 10.12.3.

Wilfred
  • 187
  • 3
  • 15

4 Answers4

1

Fix the issue finally. It includes my code's problem and XCode bugs.

I update XCode to 8.3.3 and archive the app again, instead of processing forever, it shows this error

Command failed due to signal: Segmentation fault: 11

Refer to this question and this answer, I reach a function and find out that the issue come from one statement.

viewModel.willDestroy(additionalInfo: ["text": text])

And this is what my ViewModel and its parent class look like

// ViewModelBase Class
func willDestroy(additionalInfo: Dictionary<String, Any>) {
    ...
}

// ViewModel Class 
override func willDestroy(additionalInfo: Dictionary<String, Any>? = nil) {
    ...
}

The signature of willDestroy in ViewModel does not match with its parent is the core issue of this question. After updating the signature, my app can finally be archived in XCode 8.3.3.

Wilfred
  • 187
  • 3
  • 15
0

You can try once by deleting your derived data. You can follow the link to get the Derived data folder. image1 image2

Then follow as below,

Before Deleting the contents of Derived Data, Force Quit your Xcode - Then Delete all contents from Derived Folder - Clean the Bin - Restart Your Xcode

When I got stuck in the similar situation I follow this (Even Restart my Mac). Good Luck.

MarkMe
  • 51
  • 7
0

I faced same problem. To identify the problem, open terminal and run the command given below. This command outputs you the exact error.

xcodebuild archive -project <Your_Project_Name>.xcodeproj -scheme <Your_Scheme_Name> -archivePath <Path_For_Output_File>.xcarchive 
T.D.E.
  • 1
-1

I closed the xcode_9.4.1 (red x at top left) and the organizer was on the back with the stuff ready, uploaded to AppleStore with no problem

becker
  • 351
  • 4
  • 8