ITMS-90338: Non-public API usage - Frameworks/Flutter.framework/Flutter: _ptrace

使用Flutter 打包上传到appstore应用商店到时候,构建成功到包自动删除消失了,通过查找邮件出现以下问题:


ITMS-90338: Non-public API usage - The app references non-public symbols in Frameworks/Flutter.framework/Flutter: _ptrace. If method names in your source code match the private Apple APIs listed above, altering your method names will help prevent this app from being flagged in future submissions. In addition, note that one or more of the above APIs may be located in a static library that was included with your app. If so, they must be removed. For further information, visit the Technical Support Information at http://developer.apple.com/support/technical/


通过各种百度,bing搜索,结果发现大多数是下面到这种情况,

ITMS-90338: Non-public API usage - Frameworks/Flutter.framework/Flutter: _ptrace_第1张图片
是因为没有导入库,但是我一个搞flutter的,我并不很懂iOS开发,改oc语言是不可能改的了,于是通过google发现了原来很多人都有着我同样都问题,而且看问题,他们还讨论的很欢快。

下面给出解决方法:

解决方法一:

1 flutter clean
2 flutter build ios --release
3 Open xcode and select archive (I tried this by selecting clean in xcode before archiving, and just selecting archive without cleaning.)

白话一点就是:

  • 1 flutter clean
  • 2 flutter build ios --release
  • 3 open xcode

我的步骤暂时这样的,但是之前不用这个步骤也是没有报错,原因可能还有一点:我升级了SDK,因为之前启动图等待时间过长的原因,我把flutter的sdk由原来的1.7hotfix升级到了1.9stable,所以打包的时候才出现的这个问题

解决方法二:

flutter clean
rm -rf ios/Flutter/Flutter.framework
flutter build ios --release
open xcode

如果第一个方法行不通的话,就使用第二个方法,不要害怕,干就完事了,下面是一段有趣的国外开发者的精彩对话。

flutter build ios --release may use a debug Flutter.framework by mistake #37850

在这里插入图片描述

在这里插入图片描述

只能说flutter社区还是很活跃的(bug多的意思)


更多资源请访问:

超详细图文搭建个人免费博客

关注「蛇崽网盘教程资源」公众号 ,在微信后台回复「领取资源」,获取IT资源200G干货大全。

在微信后台回复「130个小程序」,即可免费领取享有导入就能跑的微信小程序

在微信后台回复「Flutter移动电商」,即可免费领取Flutter移动电商系列全套
在这里插入图片描述

你可能感兴趣的:(Flutter开发)