Weex 应用发布苹果应用商店审核被拒 - 移除 ATSDK 解决

更新日期: 2017-11-10 阅读次数: 7140 分类: weex

收到苹果审核的拒绝邮件,提示说 Weex 应用使用了非公开的 API,IOKit.framework APIs.

Guideline 2.5.1 - Performance - Software Requirements

Your app uses or references the following non-public APIs:

IOKit.framework APIs.

The use of non-public APIs is not permitted on the App Store because it can lead to a poor user experience should these APIs change. 

Continuing to use or conceal non-public APIs in future submissions of this app may result in the termination of your Apple Developer account, as well as removal of all associated apps from the App Store.

Next Steps

If you are using third-party libraries, please update to the most recent version of those libraries. If you do not have access to the libraries' source, you may be able to search the compiled binary using the "strings" or "otool" command line tools. The "strings" tool can output a list of the methods that the library calls and "otool -ov" will output the Objective-C class structures and their defined methods. These tools can help you narrow down where the problematic code resides. You could also use the "nm" tool to verify if any third-party libraries are calling these APIs.

网上看到其他人也有遇到 Weex 类似的问题,但是调用的 API 更具体:

kIOMasterPortDefault, _IOServiceMatching, _IOServiceGetMatchingService, _IORegistryEntryCreateCFProperties, _IOObjectRelease


在 platforms/ios 目录下

$ grep "IOKit.framework" -r .
Binary file ./Pods/ATSDK/ATSDK.framework/ATSDK matches
Binary file ./Pods/ATSDK/ATSDK.framework/Versions/A/ATSDK matches
Binary file ./Pods/ATSDK/ATSDK.framework/Versions/Current/ATSDK matches

ATSDK 是内部做调试的一个工具,所以去掉之后不会对线上有影响。

$ grep ATManager -r .
Binary file ./Pods/ATSDK/ATSDK.framework/ATSDK matches
./Pods/ATSDK/ATSDK.framework/Headers/ATManager.h://  ATManager.h
./Pods/ATSDK/ATSDK.framework/Headers/ATManager.h:@interface ATManager : NSObject
./Pods/ATSDK/ATSDK.framework/Headers/ATManager.h:+ (ATManager *)shareInstance;
Binary file ./Pods/ATSDK/ATSDK.framework/Versions/A/ATSDK matches
./Pods/ATSDK/ATSDK.framework/Versions/A/Headers/ATManager.h://  ATManager.h
./Pods/ATSDK/ATSDK.framework/Versions/A/Headers/ATManager.h:@interface ATManager : NSObject
./Pods/ATSDK/ATSDK.framework/Versions/A/Headers/ATManager.h:+ (ATManager *)shareInstance;
Binary file ./Pods/ATSDK/ATSDK.framework/Versions/Current/ATSDK matches
./Pods/ATSDK/ATSDK.framework/Versions/Current/Headers/ATManager.h://  ATManager.h
./Pods/ATSDK/ATSDK.framework/Versions/Current/Headers/ATManager.h:@interface ATManager : NSObject
./Pods/ATSDK/ATSDK.framework/Versions/Current/Headers/ATManager.h:+ (ATManager *)shareInstance;
./Pods/Headers/Public/ATSDK/ATSDK/ATManager.h://  ATManager.h
./Pods/Headers/Public/ATSDK/ATSDK/ATManager.h:@interface ATManager : NSObject
./Pods/Headers/Public/ATSDK/ATSDK/ATManager.h:+ (ATManager *)shareInstance;
./WeexDemo/AppDelegate.m:#import <ATSDK/ATManager.h>
./WeexDemo/AppDelegate.m:    [[ATManager shareInstance] addPluginWithId:@"weex" andName:@"weex" andIconName:@"../weex" andEntry:@"" andArgs:@[@""]];
./WeexDemo/AppDelegate.m:    [[ATManager shareInstance] addSubPluginWithParentId:@"weex" andSubId:@"logger" andName:@"logger" andIconName:@"log" andEntry:@"WXATLoggerPlugin" andArgs:@[@""]];
./WeexDemo/AppDelegate.m://    [[ATManager shareInstance] addSubPluginWithParentId:@"weex" andSubId:@"viewHierarchy" andName:@"hierarchy" andIconName:@"log" andEntry:@"WXATViewHierarchyPlugin" andArgs:@[@""]];
./WeexDemo/AppDelegate.m:    [[ATManager shareInstance] addSubPluginWithParentId:@"weex" andSubId:@"test2" andName:@"test" andIconName:@"at_arr_refresh" andEntry:@"" andArgs:@[]];
./WeexDemo/AppDelegate.m:    [[ATManager shareInstance] addSubPluginWithParentId:@"weex" andSubId:@"test3" andName:@"test" andIconName:@"at_arr_refresh" andEntry:@"" andArgs:@[]];


  • 注释掉 ./WeexDemo/AppDelegate.m 中的 ATSDK/ATManager 相关代码
  • 删除 ./Pods/ATSDK 目录
  • 删掉 Podfile 中的 ATSDK 项目
  • 打开 XCode,搜索 ATSDK,依次处理掉



$ weex --version
 - weex-builder : v0.2.6
 - weex-previewer : v1.3.8
 - weexpack : v0.4.1


  • http://www.jianshu.com/p/93cc9891f8cf
  • https://segmentfault.com/q/1010000011806166


我是来自山东烟台的一名开发者,喜欢瞎折腾,顺便记记笔记。有敢兴趣的话题,欢迎加微信 zhongwei 聊聊。 白天工地搬砖,晚上哄熊孩子,可能回复有点慢,见谅。 查看更多联系方式




2019年12月12日 西安事变纪念日
2019年12月13日 南京大屠杀
2019年12月20日 澳门回归日
2019年12月21日 国际篮球日
2019年12月22日 冬至
2019年12月24日 平安夜
2019年12月25日 圣诞节