ChatGPT解决这个技术问题 Extra ChatGPT

This action could not be completed. Try Again (-22421)

I am trying to upload an Apple TV App to the App Store for testing purposes, but I got the issue:

This Action could not be completed. Try Again (-22421)

as in the below image:

https://i.stack.imgur.com/eV1e7.png

So what can I do?

Even i got the same error first time when I submitted. However when I tried again, it successfully got uploaded.
i had try many time but got same error every time
I got the error. but I tried again. it works.
I have try many time but got same error. Then after 2 or 3 days i try to create Archive then generate ipa and Upload to App Store using Application Loader. And Upload Successfully.

M
MenuMento.com

This happens because Apple's servers may not be working correctly. Just wait and try later or next time. It will work for sure eventually.


So: be patient, try again. Glad it's now an official answer on SO. It could also be your internet connection.
This is crazy. This happens ALL the time. WTF.
Nice that this Apple service is free, ... oh wait, actually we pay 99$ per year ...
April 2017 the same
mai 2017 the same
B
Bartłomiej Semańczyk

Just try exporting the iPA file and then upload that exported iPA file with application loader. It will solve your problem.


I have try this also but can't Upload exported ipa to App Store
I have tried everything mentioned here, but this solved my problem.
This is the best solution ever. APLICATION LOADER solves the problem.
Save yourself the trouble and do a reboot. ;)
Application loader gave me more pointers about what was wrong with my archive (in my case the build number needed to be incremented). I also recommend this solution as you won't need to re-perform the exporting process if the upload fails. Thanks !
a
asedra_le

There's another way to fix above error. Try this, it fixed it for me. Open Terminal and run:

cd ~  
mv .itmstransporter/ .old_itmstransporter/  
"/Applications/Xcode.app/Contents/Applications/Application Loader.app/Contents/itms/bin/iTMSTransporter" 

Three above code line will update iTMSTransporter, then you can try uploading in XCode again.

Refs for more details: https://forums.developer.apple.com/thread/76803


Thanks for sharing! This helped!
Thanks for sharing!
This solved it for me... too bad Xcode can't manage this on its own
I did an experiment with this, below, for June 1, 2017 (scroll down to my answer). Unfortunately it does not seem to be the root problem :/
Worked for me one release, thank you... next release the error returned.
B
BennyTheNerd

(As of May 23, 2018)

Step 1

Open Xcode --> Product tab --> Archive --> export and save to desktop

Step 2

Open Xcode --> Xcode tab --> Open Developer Tool --> Application Loader >> double-click Deliver YourApp and select the recently exported .ipa file from your desktop

Solved the issue every time =)


What is "XCode tab"?
Answer: XCode Menu at the top left!
I can't find "export and save to desktop" option in this chain: Open Xcode --> Product tab --> Archive --> export and save to desktop
@Aleksandr: once the project is finished archiving Xcode will open the "Organizer". This can also be accessed from "Window" tab --> "Organizer" ... once here, select the archive file you wish to upload to App Store and click on "Export" --> Save for Store --> Next --> Next --> (wait to finish) --> save to Desktop
This is the best answer, hands down.
D
Darren

As with all thing Xcode related. A simple reboot fixed the problem for me.


I just restarted xocde and it fixed this for me (xcode 8)
Multiple tries failed, but first after reboot worked. This suggests to me that it might not be just a problem on the server end.
@Phil_Ken_Sebben Exactly the same for me, I now have to reboot every time I want to submit ...
I think apple is the one who needs to reboot their server !
i
isKrishnaK

Hey i have same issue when i am trying to upload IPA on Appstore. I solved it when i checked that my Distribution provisioning profile was invalid. So just update provisioning profile,download then install and restart Xcode. Now archive and upload it on Appstore it will be done.

OR

Create IPA and upload via Application Loader.

Good luck.


I have check my certificates valid. But still i can't upload my app to app store
I always use Application Loader but unfortunately this time I got following error: Invalid iMessage App - Your iMessage app contains an invalid sticker pack. Guess I have to move to the generic way of doing this. BTW @Bartłomiej Semańczyk answer worked. I tried again and it worked ;)
A
Ashvin A

Will work for 100% sure. I had the same issue but its solved by below steps:

Delete all profiles from: ~/Library/MobileDevice/Provisioning Profiles/ Delete developer account from Xcode >> Preference >> Account >> Delete your Apple Id Delete derived data Restart machine Download your provisioning profiles which you require to submit app Open your project and clean it And try again for submit app.

I hope this will work for all.


Is this maybe a placebo solution? Could it be that doing this took enough time for the server side to fix itself?
N
Nimantha

I was experiencing the exact same error hence being here (failed about 6 times over an hour).

I just tried again now (without changing anything), it worked by itself.

I read on the Apple-forums that it's an issue with Apple servers, nothing to do with your Xcode.

I also read that others trying the upload via ApplicationLoader (Menu -> Xcode -> Open Developer Tool -> Application Loader), this will ask where your code is, you would then have to select your Archive (not the source code), you can upload your code this way if you need. I personally prefer the built-in Xcode instead.

Works either way.

For the record, I am copying the thread from Apple Forums.


Can I just add,... to Steve Jobs,... God Bless your soul.... you're gone again, and sadly your company has already started going down hill... so many un-tested not-so-interesting variations of your inventions, I hope someone at Apple start looking into their existing products before launching more convoluted ones.
Looks like most of the other answers just help spending some time and has no relation with the problem.
H
Hsm

Uncheck "Include bitcode" box, worked for me.


this did it for me
C
Community

Update June5 ...

Apple appear to have fixed the current particular bug that was present for about the last week.

In short, you can upload with the blue "Upload to App Store..." button, rather than having to use the application loader.

For June 1, 2017

even more information, the seemingly failed uploads

do indeed seem to go to the app store...!

https://i.stack.imgur.com/o0vvX.png

with each of the items there 208-231, I had tried to upload in the normal way, and it failed with the "Try Again (-22421)" code.

In fact, unnoticed by me, they were all going up to the app store, but it looks like they were just getting stuck on endless processing.

I then did I believe exactly what StevenOjo reported (yesterday) above:

Setting up an A NEW account on iTunes with a NEW email address

ALSO SET THAT UP ON DEVELOPER, remembering that, because Apple is the world's most idiotic organization, developer.apple is totally different from ituneconnect.apple

From my actual normal account, and this is IN DEVELOPER, NOT ITUNES CONNECT, I invited that new alter ego as an admin

Exporting the app from the organizer, as an IPA for app store distribution.

Logging into application loader with that new email and uploading the archive. It worked without any issues.

It's possible it would actually work fine now with my usual account; I don't know.

To be clear, after a very short time (say, two minutes), the final build (ie, 233 above) did indeed become "ready to test" as normal on the app store ..

https://i.stack.imgur.com/0ZV2I.png

All the "dud" uploads seem to be stuck forever on processing.

The staggering incompetence of Apple has reached "conspiracy theory" levels....

It is literally not possible to hire programmers and sysadmins, who are this bad.

There must be some sort of conspiracy theory, behind the utter fiasco that is Apple's provisioning. Maybe it's some sort of reverse-psychology marketing plot or something ....... who knows.

Later the same day:

I TRIED UPDATING itmstransporter:

I then tried with a new build number using the normal "Upload to the App Store..." cheery blue button.

It did not work ...

I then tried using Application Loader as described above...

It DID work with ApplicationLoader.

Conclusion ...

Unfortunately, itmstransporter is probably not relevant.

:/ what a fiasco.


I've literally been trying to upload for the past 25 hours. Glad to see the date on here.
Like Andrew, I spent all day and all night last night trying to get this to work. Not only have I lost 7 months of my life from anger-induced stress, Apple has stolen a little portion of my soul away via their provisioning errors. I've actually felt it leave my body. The incompetence of Apple with these generic, confusing, and buggy problems is greater than the incompetence of my father, who had 34 children with 18 different women and completely abandoned me. Just like Apple has abandoned this process.
@AndrewK, i added some more info: I tested the "itmstransporter" theory. Hope it helps someone.
I had to disable the 2 factor authentication from appleid.apple.com to be able to log in Application loader
I am facing similar issue. I am uploading my build through Application Loader. App is uploading and Activity tab is showing my build but not appearing in TestFilght. Can't understand what to do, boss and client are eating me.
A
Arnon

Open Terminal and run:

cd ~

mv .itmstransporter/ .old_itmstransporter/

"/Applications/Xcode.app/Contents/Applications/Application Loader.app/Contents/itms/bin/iTMSTransporter"


This worked for me. I've seen this in other forums too... seems to be a fix.
Excelent! Thanks a lot!
I did an experiment with this, below, for June 1 (scroll down to my answer). Unfortunately it does not seem to be the root problem :/
D
Devansh Bhardwaj

The problem can not be solved with xCode Upload Process. I was facing same issues few days ago when submitting few of my apps and all apps showing same error. After many tries, I used Application Loader to upload app and it worked.

First go to xcode -> product menu -> archive Select Export for Appstore Save IPA file Now Open Application loader by going to xCode -> xCode Menu -> Open Developer Tool -> Application Loader Login with the credentials of account, and select the IPA file.

Submit it! It works!


This works for me. I now prefer using Application Loader because it's got a slightly better UX than XCode. XCode feels like a black box compared to Application Loader.
C
Community

For Xcode 8.3.2

i have resolved same issue

"This action could not be completed. Try Again (-22421)"

using following steps...

Quit your xcode (if open) in Application Folder, Xcode 8.3.2 -->Show Package Contents -->Contents -->Application -->Application Loader (Show package contents) -->Contents -->itms -->bin -->iTMSTransporter (right click and Open with Terminal, it will auto start updating...) after updating open your project, rebuild your archive and upload it again..

For Xcode 9

issue

”This action could not be completed. Try Again (-22421)”

has been Resolved in Xcode 9. Now, we can upload app through Xcode Organizer also.

https://developer.apple.com/library/content/releasenotes/DeveloperTools/RN-Xcode/Chapters/Introduction.html#//apple_ref/doc/uid/TP40001051-CH1-SW876


N
Nazar

I've tried to load archive nearly 10 times (with all kinds of cleans and reloads, with different versions and provisioning files), still received the same error. Then suddenly on my next attempt it showed me: "cannot proceed with delivery an existing transporter instance is currently uploading this package", I did the following and it helped:

Basically, you need to clear out the transport tokens. This can happen if you were to close out of Xcode while in the middle of submitting an app to iTunes Connect.

/Users/<username>/.itmstransporter/UploadTokens/

Delete any .token files in this directory. If you are unable to find the .token files, this is because they are hidden in Finder. To hide/show hidden files in Finder, use the following Terminal command (TRUE = UNHIDE, FALSE = HIDE):

defaults write com.apple.finder AppleShowAllFiles TRUE;killall Finder


This and restarting Xcode seem to has solved the issue.
B
Berk

I increased build number but the problem remained.

Then,

I approved renewed licence agreement at itunesconnect. I opened App Store application on my MAC, and clicked update button for "Command Line Tools (OS X 10.11) for XCode, Version 7.3" I opened XCode. Clicked "Product" button on top bar. While tab content is open, I clicked "alt" key of keyboard to make "Clean Build Folder" option visible. I clicked this option. I rebuild my application for the same version that I received below error;

This action could not be completed. Try Again (-22421)

This time I received below error when I want to upload new version;

This action could not be completed. Try again.

I clicked Done and clicked blue "Upload to App Store" button again, and upload completed successfully.

I hope this helps.


Thanks for the Option+Product trick to clean the build folder (so much easier). This finally worked for us... after a computer restart (Xcode wasn't enough) and clean rebuild (not just resubmitting the same one)
A
Alex Zavatone
Tested in Xcode 7.3, 04142016

Instead of clicking the blue Upload to App Store… button from the Organizer or while Archiving, Xcode offers a better tool to do this, but it is a little hidden and the process is not clear how to use it.

Here is what I documented while submitting our latest iOS application to the App Store:

First, do NOT use the blue Upload to App Store… button.

From Xcode's Xcode: Developer Tools: menu, select Application Loader.

Sign in with appropriate credentials that allow you to upload to the App Store.

When Application Loader shows you its main screen, select the Choose button on the lower right of the main window and open your IPA that you exported for the App Store.

Proceed with the submission.

Why you want to do this:

Detailed app submission error reporting. Exact explanations of submission errors. It tells you what's incorrect in your app that you are trying to submit. You don't have to deal with the insipid error that prompted this question in the first place. It works consistently in my tests where Xcode's Submit App to Store… from the Archive menu does not.


I had try both ways but at that time couldn't upload app to AppStore.
Nimisha, you only stated that it failed. You did not explain how it failed, where in the process it failed or what the error was. How can we help you if you don't provide this information? We're not sitting over your desk watching what happened. We don't know if you don't tell us.
I have already explain in question that while uploading Archive to AppStore after that uploading process started and came this error like above image i have attached. This Problem solve in my case. This issue generated may be because of Apple Server but after some days i try using Application Loader it's Uploaded successfully. Thank you for your reply.
D
Daishi Nakajima

Just In case it is same my mistake.

Did you check both provisioning profile settings in "your Project" and "your Targets"?

https://i.stack.imgur.com/d2IRv.png


P
Przemysław Wrzesiński

In my case it was caused by lack of some of the app icons in the Images.xcassets


S
StevenOjo

Both developers on our team experienced the same problem, from different machines on May 31st 2017. I worked around the problem by:

Setting up an app specific password on my Apple ID. Exporting the app from the organizer, as an IPA for app store distribution. Logging into application loader with that App Specific password and uploading the archive. It worked without any issues.

What a lovely waste of time. Hopefully these steps work for others and save some time.


May31st failed to submit with Xcode over 6-7 times in a row (persistence), worked first try with application loader
S
Sandip Patel - SM

When you receive error "Action could not be completed. Try Again (-22421)", Just try to resubmit same app on iTunes store using XCode again, and you will get the actual error messages next time.

Detailed error message which your received next time will help you what to do actually!!!

If you are receiving same error again and again, you can submit app using "App Loader" and it may success to submit.

[ Take care Point: ]

Please check your app version / build version number is greater than previously submitted version. You can verify it in Xcode -> Project setting -> General section AND iTunes-Connect-Account -> App Package -> Activity tab


This was true for me "Just try to resubmit same app on iTunes store using XCode again, and you will get the actual error messages next time." In my case it was ITMS-90062 and I need to bump the CFBundleShortVersionString
Using Application Loader works for me. The Xocde internal upload mechanism is a bit bugged..
L
Lasse Bunk

I had this problem over and over again. No descriptive description, just the error message that OP posted.

In fact, it was a problem with the build and so had nothing to do with Apple's servers at all, as you might think.

The solution was to go to Organizer and Export the build, then upload it via Application Loader. Here I got the correct error messages. In my case, it was a problem with CocoaPods breaking app extension validations. I solved this and then I could upload my build.

Hope this helps someone like me.


A
Aleksandar Lugonja

I had the same issue. It was related to the Build Settings -> Code Signing Identity -> Release which was set to iOS Developer. If has to be set to iOS Distribution in order for Xcode upload to work.


A
Aanchal Chaurasia

For June 1 2017

Certain combined steps from answer of this thread that worked for me. I am writing the process that worked fine for me.

1) Open terminal and run this

cd ~

mv .itmstransporter/ .old_itmstransporter/

"/Applications/Xcode.app/Contents/Applications/Application Loader.app/Contents/itms/bin/iTMSTransporter"

iTMSTransporter will then update itself, wait till process completes.

2) Logout the apple account from Xcode preferences account and login again instead of creating new Id on iTunes and developer account.

3) Clean the project and archive then export the app from organiser as an IPA for app store distribution.

4) Logging into application loader with same account and upload the ipa.

5) Process will complete successfully.


C
Community

You can try following solutions: Use Application Loader to upload your app, as Xcode organizer can't upload file (rejects IPA) sometimes, without genuine reason and it's frequently occurring issue, with Xcode Organizer, that apple could not resolve permanently.

Solution for error code: 22421

Apple app upload server is not working properly (not in connection or lost connection during file upload). Just wait and try again later (may be after a day). Fluctuation in your network connection, during file upload. You may not have added privacy statements in your info.plist file.

Cocoa Keys: Here, is list of keys (with privacy statements) that you should consider to add in your info.plist file, if you have used that service in your application.

Nowadays, you may also face, this error code: 90186 (with app loader)

Outdated application loader can be reason of this error. Use latest Xcode tool and use application loader from Xcode Tool. Incorrect/invalid provisioning profile, associated with your build. Ensure, your have used correct provisioning profile (A provisioning profile with Distribution/Production mode is require. A Development mode provisioning profile won't allow your to upload app on store.)

You can find latest Application Loader Tool from latest Xcode Tool: Xcode -> Open Developer Tool -> Application Loader

https://i.stack.imgur.com/6eMX8.png


A
Alex Zavatone

The best solution is indeed Application Loader. I can't comment on Naresh's note on this (I'm too much of a newbie to StackOverflow), but am warning you that if you are using Swift, don't the use Xcode ipa generation system. I prefer manual creation of the IPA by:

1) zipping 2 folders : a Payload folder that contain your .app and a SwiftSupport folder that you can copy from your Xarchive. 
2) rename the zip to .ipa.

j
juhan_h

Validating the same archive that failed to upload worked for me. Or just Apple's servers came back up.


A
Alfro

If you connect a device while the app is building/archiving, your generic device will change to your connected device automatically, and when you are trying to upload to the app store you will have that weird crash.

https://i.stack.imgur.com/qKblr.png

will change to this automatically:

https://i.stack.imgur.com/UGhtJ.png

So to answer your question, I don't know if your issue have been caused because you plugged your iOs device while archiving, but you will be able to reproduce that issue if you plug your iOS device while archiving your app. Hope this helps somebody


D
Dasoga

My problem was with the provisional profiles.

So for me it worked:

Go to Xcode preferences -> Accounts -> In my ID Apple Account -> Select "Download All"

I checked too, in member center and delete all invalid provisionals profiles and:

1 - Close Xcode

2 - Open Xcode, do clean and build of my project.

3 - Archive my code again.


佚名

Check this list or just keep trying upload!

Got to member center

Check if there are any invalid provisioning profiles (for some reason, my app store distribution profile has become invalid)

Delete invalid profiles

Create new ones

Download and drag on XCode

Reboot Mac

Archive => Upload to App Store

Everything should be fine again


E
Eric

This occurred to me after I enabled two-factor authentication in my Apple ID. After I disable two-factor authentication, everything works as expected.