应用程序在启动时崩溃
Posted
技术标签:
【中文标题】应用程序在启动时崩溃【英文标题】:App crashes upon launch 【发布时间】:2016-10-14 19:37:08 【问题描述】:我向应用商店提交了我的应用,但它被拒绝了,它在启动时崩溃了。以下是崩溃日志:
"app_name":"my app","timestamp":"2016-10-14 11:23:40.71 -0700","app_version":"3.7","slice_uuid":"d7f7e7c6-eedf-34d3-87a4-f20da6f38209","adam_id":0,"build_version":"1.5.3","bundleID":"com.mycompany","share_with_app_devs":false,"is_first_party":false,"bug_type":"109","os_version":"iPhone OS 10.0.2 (14A456)","incident_id":"73C54050-9529-407C-9323-C5C609A2EB7F","name":"my app"
Incident Identifier: 73C54050-9529-407C-9323-C5C609A2EB7F
CrashReporter Key: 2c0ba505c2c6082ea09a6f57e4d847f80be99b41
Hardware Model: xxx
Process: my app [330]
Path: /private/var/containers/Bundle/Application/B7F24EF4-8716-484F-A83A-20CCCCDCFA3A/my app.app/my app
Identifier: com.mycompany
Version: 1.5.3 (3.7)
Code Type: ARM-64 (Native)
Role: Foreground
Parent Process: launchd [1]
Coalition: com.mycompany [404]
Date/Time: 2016-10-14 11:23:40.5372 -0700
Launch Time: 2016-10-14 11:23:40.4466 -0700
OS Version: iPhone OS 10.0.2 (14A456)
Report Version: 104
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Termination Description: DYLD, Library not loaded: @rpath/IBMMobileFirstPlatformFoundation.framework/IBMMobileFirstPlatformFoundation | Referenced from: /var/containers/Bundle/Application/B7F24EF4-8716-484F-A83A-20CCCCDCFA3A/my app.app/my app | Reason: image not found
Triggered by Thread: 0
Filtered syslog:
None found
Thread 0 Crashed:
0 dyld 0x0000000100361cd8 0x10033c000 + 154840
1 dyld 0x0000000100361668 0x10033c000 + 153192
2 dyld 0x00000001003616b0 0x10033c000 + 153264
3 dyld 0x0000000100340514 0x10033c000 + 17684
4 dyld 0x00000001003429a8 0x10033c000 + 27048
5 dyld 0x000000010033d044 0x10033c000 + 4164
Thread 0 crashed with ARM Thread State (64-bit):
x0: 0x0000000000000006 x1: 0x0000000000000001 x2: 0x000000016fd221b0 x3: 0x00000000000000c7
x4: 0x000000016fd21db0 x5: 0x0000000000000000 x6: 0x0000000000000000 x7: 0x00000000000001d0
x8: 0x0000000000000020 x9: 0x0000000000000009 x10: 0x67616d69203a6e6f x11: 0x6f6620746f6e2065
x12: 0x20200a495520656c x13: 0x203a6e6f73616552 x14: 0x6f6e206567616d69 x15: 0x00646e756f662074
x16: 0x0000000000000209 x17: 0x0000000000000010 x18: 0x0000000000000000 x19: 0x0000000000000000
x20: 0x000000016fd21db0 x21: 0x00000000000000c7 x22: 0x000000016fd221b0 x23: 0x0000000000000001
x24: 0x0000000000000006 x25: 0x000000010036dab8 x26: 0x000000010036fbb8 x27: 0xe6afae36b31a0072
x28: 0x000000010036d000 fp: 0x000000016fd21d80 lr: 0x0000000100361668
sp: 0x000000016fd21d40 pc: 0x0000000100361cd8 cpsr: 0x00000000
Binary Images:
0x1000dc000 - 0x100263fff my app arm64 <d7f7e7c6eedf34d387a4f20da6f38209> /var/containers/Bundle/Application/B7F24EF4-8716-484F-A83A-20CCCCDCFA3A/my app.app/my app
0x10033c000 - 0x10036bfff dyld arm64 <fc8715469f7b30228b67a5ae12cadf10> /usr/lib/dyld
EOF
终止描述说:
Termination Description: DYLD, Library not loaded: @rpath/IBMMobileFirstPlatformFoundation.framework/IBMMobileFirstPlatformFoundation | Referenced from: /var/containers/Bundle/Application/B7F24EF4-8716-484F-A83A-20CCCCDCFA3A/my app.app/my app | Reason: image not found
Triggered by Thread: 0
我正在使用 XCode 8 和 ios 10 来测试我的应用程序。当我通过 XCode 安装它时,它工作正常。只有当我从 iTunes、TestFlight 或 ApplicationCenter 安装 .ipa 文件时,才会发生这种崩溃。
应用中安装了以下插件:
cordova-plugin-console 1.0.4“控制台”
cordova-plugin-device 1.1.3“设备”
cordova-plugin-dialogs 1.3.0“通知”
cordova-plugin-globalization 1.0.4“全球化”
cordova-plugin-mfp 8.0.2016080320“IBM MobileFirst Platform Foundation”
cordova-plugin-okhttp 2.0.0 "OkHttp"
cordova-plugin-splashscreen 4.0.0“启动画面”
cordova-plugin-statusbar 2.2.0“状态栏”
cordova-plugin-whitelist 1.3.0“白名单”
当我在归档后验证应用程序时,出现以下错误:
【问题讨论】:
这是原生应用还是 Cordova 应用?您是如何将 SDK 添加到应用中的? @IdanAdar 这是科尔多瓦应用程序 什么是 MobileFirst Foundation 插件版本? "cordova 插件列表" @IdanAdar 查看更新后的问题。 【参考方案1】:IBMMobilefirstPlatformFoundation.framework
与i386
和x86_64
架构切片打包在一起,因此添加了这些框架的应用程序也可以在模拟器上运行。
但是动态库中的这些架构在提交到 AppStore/Generating Archive 时不受支持。这是一个已报告的 Xcode 缺陷,您可以找到 here。
目前的解决方法是在提交到 AppStore/Generating Archive 时从 IBMMobilefirstPlatformFoundation.framework
中删除这些架构。 This blog 描述了相同的问题并包含一个脚本,使用该脚本可以从动态库中去除不需要的架构(i386 / x86_64)。
【讨论】:
以上是关于应用程序在启动时崩溃的主要内容,如果未能解决你的问题,请参考以下文章