Sazzad Hissain Khan
Sazzad Hissain Khan

Reputation: 40245

error: exportArchive: The operation couldn’t be completed. (IDEDistributionErrorDomain error 3.)

I am building iOS project on command line using xcodebuild. Building with Release configuration is ok which created and App.xcarchive. Then I am trying to export archive for App Store IPA using,

xcodebuild -exportArchive -archivePath App.xcarchive -exportPath ~/output/ -exportOptionsPlist appstore.plist

My appstore.plist,

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>teamID</key>
<string>T3AM1D</string>
<key>method</key>
<string>app-store</string>
</dict>
</plist

This gives me error,

error: exportArchive: The operation couldn’t be completed.(IDEDistributionErrorDomain error 3.)

Any help will be appreciated.

Upvotes: 9

Views: 8531

Answers (4)

In my case, my account session was expired as I changed my password, under signing and capabilities, I signed in again using my new password, and it worked as expected.

Upvotes: 0

Ahmad Habib
Ahmad Habib

Reputation: 2382

I got a similar issue while trying to upload my archived Ios build to testflight as shown in the image below.

Error while uploading Ios build

The reason I got the issue was, I had poor internet connection.

What I tried: I just switched to a better network and got this resolved.

I hope this helps someone

Upvotes: 0

Caadif Calawaash
Caadif Calawaash

Reputation: 1

Credentialed provider request failed with error: "The request timed out"

just connect computer to your mobile hotspot .

Upvotes: -1

Sazzad Hissain Khan
Sazzad Hissain Khan

Reputation: 40245

Finally I was able to solve this issue.

Solution Steps

  1. Make sure all profiles and certificates are setup successfully in Mac
  2. Make sure no red mark is shown from Xcode, For example Xcode->targets->Build settings ->Profiles and signing identity + team
  3. Make sure that all targets including MainApp, Widgets, Extensions are also configures without issue
  4. Make sure that all capabilities, appgroup and keychains are OK
  5. Important: Make sure that from Xcode -> Product -> Archive -> export to App Store IPA ran at least one time
  6. When running xcodebuild from command line, make sure that Xcode is closed

Hope this helps

Upvotes: 8

Related Questions