iOS开发之Application Loader上传包出现的问题

91 篇文章 3 订阅

iOS开发之ipa包Application Loader上传到Appstore

我们在工作中上传IPA包基本上都会用到Application Loader,那么在上传IPA包的时候肯定会遇到一些报错问题,以下就来说一下:

第一种

Archive upload failed due to the issues listed below:

ERROR ITMS-90534:"Invalid Toolchain. New apps and app updates must be built with the public(GM) versions of Xcode 6 or later,macOS,and iOS SDK or later. Don't submit apps built with beta software including beta macOS builds.

Snip20170801_29.png

 

这个问题说的就是我们在打包的时候用的beta版本的xcode打的,需要用xcode6及以后的正式版xcode打包。

有兴趣的童鞋可以了解下:iOS打包的两种方式

这个问题的背景是苹果WWDC大会发布了beta版本的xcode为了体验一下就下了一个,但是打包的时候用了beta版本的来打包,所以这个报错了。我们只需要切换到正式版本打包就行了。

第二种

Archive upload failed due to the issues listed below:

The session's status is FAILED and the error description is 'Connection lost in midst of data session, SSH connection failure: Operation timed out(16)'...
the max number of retries was performed. the package will not be upload

Snip20170801_28.png

 

像这种情况是因为网络的问题,解决办法有两种:

  • 再次双传,因为可能中途和苹果的连接断了
  • 换一个稳定点的网络,这样保证在传输过程中链路是稳定的

第三种

Archive upload failed due to the issues listed below:

ERROR ITMS-90122:"Invalid Executable Size. The size of your app's executable file '*********' is 86605824 bytes for architecture 'armv7',which exceeds the maxmum allowed size of 60MB."

ERROR ITMS-90122:"Invalid Executable Size. The size of your app's executable file '*********' is 86343680 bytes for architecture 'arm64',which exceeds the maxmum allowed size of 60MB."

Snip20170818_133.png

像这个问题说的是我们打包之后的ipa包中打开的二进制可执行文件不能超过60M,并不是说ipa包不能超过60M,其中我们很多能做成资源文件的就把这部分放到外面来,然后动态加载,以下是官方文档要求的:
Submitting the App to App Review

For iOS and tvOS apps, check that your app size fits within the App Store requirements.
Your app’s total uncompressed size must be less than 4GB. Each Mach-O executable file (for example, app_name.app/app_name) must not exceed these limits:

For apps whose MinimumOSVersion is less than 7.0: maximum of 80 MB for the total of all __TEXT sections in the binary.
For apps whose MinimumOSVersion is 7.x through 8.x: maximum of 60 MB per slice for the __TEXT section of each architecture slice in the binary.
For apps whose MinimumOSVersion is 9.0 or greater: maximum of 500 MB for the total of all __TEXT sections in the binary.
However, consider download times when determining your app’s size. Minimize the file’s size as much as possible, keeping in mind that there is a 100 MB limit for over-the-air downloads. Abnormally large build files are usually the result of storing data, such as images, inside the compiled binary itself instead of as a resource inside your app bundle. If you are compiling an image or large dataset into your binary, it would be best to split this data out into a resource that is loaded dynamically by your app.

PS: MinimumOSVersion版本也就是Development Target版本
7.0版本以下的二进制文件的__TEXT最大80M
7.0-8.0版本的二进制文件的__TEXT最大60M
9.0-以后版本二进制文件的__TEXT最大500M
其中后面内容还有讲到解压缩之后安装在手机上最大4G.

Snip20170818_145.png

查看二进制文件的大小:

Snip20170818_135.png

Snip20170818_137.png

Snip20170818_138.png

Snip20170819_14.png

但是怎么查看__TEXT的大小呢?
其实只要用size命令查看一下刚刚找到的二进制文件即可:

Snip20170819_13.png

Snip20170819_15.png

 

PS: 这里显然只有32KB,那么比169KB是要小很多了,当然这个里面有我很多的重复代码,可能会影响这个数字,一般如果没有很多重复代码的话差别应该不会太大但是一定会小。

请参考:iOS坑:IPA可执行文件大小限制

后面如果遇到别的问题还会继续添加的,希望能给大家带来帮助!

以上!



作者:KODIE
链接:https://www.jianshu.com/p/185a6e3552a9
来源:简书
简书著作权归作者所有,任何形式的转载都请联系作者获得授权并注明出处。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值