iOS Build Environment Help Center

Delete

(Leave this as-is, it’s a trap!)

To delete this post you must be either the original author or a designated moderator.
The content of the post will be removed but the name and date will remain.

  • The post will be removed completely from the thread, rather than blanked
  • Only posts on the last page of the thread can be removed completely (so as to not break permalinks)

RE[2]: Apple iOS Upload Fails Frequently

_Apocx

Yeah the upload will just randomly fail up to 3-4 times sometimes before finally succeeding.

I wrote a batch file to just continuously upload until it either succeeds or fails at least 10 times, since usually it only fails 3-4 times before it finally works. Since this is part of my automated build pipeline, the upload failing was getting to be extremely annoying. It used to succeed 100% of the time, now it only works like 1 in 5 times. It's strange. Everything else is working flawlessly though, love the software :)

For anyone else that has this problem, here is the script:

@echo off
echo Running upload script until it either succeeds or fails at least 10 times...
setlocal

set /a "count=0"

:loop
if %count% geq 10 (
echo Reached maximum attempt limit.
goto end
)

call "C:\iOS\iOS Project Builder for Unity\upload.cmd" "<path to your file>.ipa" -asclogin "<your ios dev username>" -ascpassword "<your ios app password>" -ascprovider ""
set /a "exitcode=%errorlevel%"
set /a "count+=1"

if %exitcode% equ 0 (
echo Success on attempt %count%.
goto end
) else (
echo Attempt %count% failed, exit code %exitcode%.
goto loop
)

:end
endlocal

Moderators: Pierre-Marie Baty