Alamofire 5.2.2 TestFlight watchOS构建在Apple Watch Series 3设备32位上崩溃与位代码有关?

如何解决Alamofire 5.2.2 TestFlight watchOS构建在Apple Watch Series 3设备32位上崩溃与位代码有关?

我在TestFlight上有一个WatchOS应用程序,该应用程序在Apple Watch Series 3设备(32位)上启动时崩溃。它可以在Simulators(Xcode 11.7)和Apple Watch Series 4上完美运行。

我正在将Alamofire 5.2.2与Swift Package Manager结合使用。最新的Xcode(版本11.7)。该设备是运行最新的最终watchOS(版本6.2.8)的Apple Watch Series 3设备(32位)。您可以帮我还是就此发生的事情提供指导吗?

如果没有提供网关访问令牌,我正在调用一个REST服务,该服务将返回JSON错误文件(响应)和HTTP状态代码401(未授权)。

正如我所说的,它可以在模拟器和Apple Watch Series 4设备中使用。我怀疑是位码,因为在过去的版本中,我有一个iOS配套应用程序并禁用了位码生成,但是现在我们只有监视应用程序,我不能禁用位码生成。

崩溃有点像这样:

Hardware Model:      Watch3,4
Process:             Watch App Extension [616]
Version:             132 (1.0)
AppVariant:          1:Watch3,4:6
Beta:                YES
Code Type:           ARM (Native)
Role:                Foreground
Parent Process:      launchd [1]

Date/Time:           2020-09-02 15:52:50.8659 -0300
Launch Time:         2020-09-02 15:52:48.0000 -0300
OS Version:          Watch OS 6.2.8 (17U63)
Release Type:        User
Baseband Version:    n/a
Report Version:      104

Exception Type:  EXC_BAD_ACCESS (SIGSEGV)
Exception Subtype: KERN_INVALID_ADDRESS at 0x00000060
VM Region Info: 0x60 is not in any region.  Bytes before following region: 2310048
      REGION TYPE              START - END     [ VSIZE] PRT/MAX SHRMOD  REGION DETAIL
      UNUSED SPACE AT START
--->  
      __TEXT                 00234000-0038c000 [ 1376K] r-x/r-x SM=COW  ...App Extension

Termination Signal: Segmentation fault: 11
Termination Reason: Namespace SIGNAL,Code 0xb
Terminating Process: exc handler [616]
Triggered by Thread:  0

Thread 0 name:  Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0   libswiftCore.dylib              0x6f7f4060 static _SetStorage.allocate+ 864352 (scale:age:seed:) + 16
1   libswiftCore.dylib              0x6f7f007e static _SetStorage.allocate+ 847998 (capacity:) + 126
2   Watch App Extension 0x002fcca4 specialized protocol witness for Collection.endIndex.getter in conformance [A] + 822436 (_$s30Watch_App_Extension12SimulaCambioMp:0)
3   Watch App Extension 0x002ebcfe static ResponseSerializer.defaultEmptyRequestMethods.getter + 752894 (contaFormatada.modify:102)
4   Watch App Extension 0x002801e2 AlamofireLoginService.loginSmartwatch(completion:) + 311778 (AlamofireLoginService.swift:49)
5   Watch App Extension 0x0027b568 specialized InterfaceController.doLogin(:semProgresso:) + 292200 (InterfaceController.swift:0)
6   Watch App Extension 0x00275ec6 InterfaceController.awake(withContext:) + 270022 (InterfaceController.swift:246)
7   Watch App Extension 0x00276888 @objc InterfaceController.awake(withContext:) + 272520 (<compiler-generated>:0
8   WatchKit                        0x5f1959c2 _WKInterfaceControllerCreateClass + 444
9   WatchKit                        0x5f1ceef4 __153-[SPRemoteInterface createViewController:className:properties:contextID:info:gestureDescriptions:clientIdentifier:interfaceControllerCreationCompletion:]_block_invoke_3 + 348
10  WatchKit                        0x5f1cebbe __153-[SPRemoteInterface createViewController:className:properties:contextID:info:gestureDescriptions:clientIdentifier:interfaceControllerCreationCompletion:]_block_invoke_2 + 1070
11  WatchKit                        0x5f194130 spUtils_dispatchAsyncToMainThread + 22
12  WatchKit                        0x5f1ce75c __153-[SPRemoteInterface createViewController:className:properties:contextID:info:gestureDescriptions:clientIdentifier:interfaceControllerCreationCompletion:]_block_invoke + 156
13  WatchKit                        0x5f1956c4 -[SPRemoteInterface performAfterApplicationDidFinishLaunching:] + 40
14  WatchKit                        0x5f195410 -[SPRemoteInterface createViewController:className:properties:contextID:info:gestureDescriptions:clientIdentifier:interfaceControllerCreationCompletion:] + 282
15  WatchKit                        0x5f23564a __178-[SPExtensionConnection interfaceViewController:createCompanionControllerClass:properties:initializationContextID:info:gestureDescriptions:interfaceControllerCreationCompletion:]_block_invoke + 294
16  WatchKit                        0x5f192ba2 -[SPExtensionConnection performOnSendQueue:syncIfUnsuspended:] + 464
17  WatchKit                        0x5f195298 -[SPExtensionConnection interfaceViewController:createCompanionControllerClass:properties:initializationContextID:info:gestureDescriptions:interfaceControllerCreationCompletion:] + 284
18  WatchKit                        0x5f1950f4 -[SPApplicationDelegate viewController:createWKInterfaceControllerClass:properties:contextID:creationCompletion:] + 1588
19  WatchKit                        0x5f183740 -[SPInterfaceViewController loadView] + 2004
20  UIKitCore                       0x678d7aca -[UIViewController loadViewIfRequired] + 160
21  UIKitCore                       0x678d80f0 -[UIViewController view] + 24
22  WatchKit                        0x5f182536 -[SPInterfaceViewController applicationDidBecomeActive] + 126
23  WatchKit                        0x5f182024 -[SPApplicationDelegate applicationDidBecomeActive:] + 670
24  UIKitCore                       0x67d6dc9a -[UIApplication _stopDeactivatingForReason:] + 1150
25  UIKitCore                       0x6772463e -[_UISceneLifecycleMultiplexer _performBlock:withApplicationOfDeactivationReasons:fromReasons:] + 414
26  UIKitCore                       0x677248f0 -[_UISceneLifecycleMultiplexer _evalTransitionToSettings:fromSettings:forceExit:withTransitionStore:] + 632
27  UIKitCore                       0x677242d6 -[_UISceneLifecycleMultiplexer uiScene:transitionedFromState:withTransitionContext:] + 266
28  UIKitCore                       0x67727d88 __186-[_UIWindowSceneFBSSceneTransitionContextDrivenLifecycleSettingsDiffAction _performActionsForUIScene:withUpdatedFBSScene:settingsDiff:fromSettings:transitionContext:lifecycleActionType:]_block_invoke_2 + 162
29  UIKitCore                       0x679f8238 +[BSAnimationSettings+ 4551224 (UIKit) tryAnimatingWithSettings:actions:completion:] + 746
30  UIKitCore                       0x67ab8a1c _UISceneSettingsDiffActionPerformChangesWithTransitionContext + 230
31  UIKitCore                       0x67727ba8 __186-[_UIWindowSceneFBSSceneTransitionContextDrivenLifecycleSettingsDiffAction _performActionsForUIScene:withUpdatedFBSScene:settingsDiff:fromSettings:transitionContext:lifecycleActionType:]_block_invoke + 116
32  UIKitCore                       0x67ab892c _UISceneSettingsDiffActionPerformActionsWithDelayForTransitionContext + 78
33  UIKitCore                       0x67727a4c -[_UIWindowSceneFBSSceneTransitionContextDrivenLifecycleSettingsDiffAction _performActionsForUIScene:withUpdatedFBSScene:settingsDiff:fromSettings:transitionContext:lifecycleActionType:] + 296
34  UIKitCore                       0x675d7bd2 __64-[UIScene scene:didUpdateWithDiff:transitionContext:completion:]_block_invoke + 578
35  UIKitCore                       0x675d6b48 -[UIScene _emitSceneSettingsUpdateResponseForCompletion:afterSceneUpdateWork:] + 190
36  UIKitCore                       0x675d795c -[UIScene scene:didUpdateWithDiff:transitionContext:completion:] + 158
37  UIKitCore                       0x67a1480e -[UIApplicationSceneClientAgent scene:handleEvent:withCompletion:] + 406
38  PepperUICore                    0x59fc7e62 -[PUICApplicationSceneClientAgent scene:handleEvent:withCompletion:] + 642
39  CarouselUIServices              0x5d67f498 -[CUISWatchKitApplicationSceneClientAgent scene:handleEvent:withCompletion:] + 220
40  FrontBoardServices              0x52fa4b5c -[FBSSceneImpl updater:didUpdateSettings:withDiff:transitionContext:completion:] + 510
41  FrontBoardServices              0x52fc3396 __88-[FBSWorkspaceScenesClient sceneID:updateWithSettingsDiff:transitionContext:completion:]_block_invoke_2 + 104
42  FrontBoardServices              0x52fad00c -[FBSWorkspace _calloutQueue_executeCalloutFromSource:withBlock:] + 204
43  FrontBoardServices              0x52fc32f8 __88-[FBSWorkspaceScenesClient sceneID:updateWithSettingsDiff:transitionContext:completion:]_block_invoke + 154
44  libdispatch.dylib               0x4f882e1e _dispatch_client_callout + 6
45  libdispatch.dylib               0x4f88507a _dispatch_block_invoke_direct + 180
46  FrontBoardServices              0x52fe1748 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 22
47  FrontBoardServices              0x52fe152e -[FBSSerialQueue _queue_performNextIfPossible] + 346
48  FrontBoardServices              0x52fe1926 -[FBSSerialQueue _performNextFromRunLoopSource] + 24
49  CoreFoundation                  0x4fd0696e __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 14
50  CoreFoundation                  0x4fd068c4 __CFRunLoopDoSource0 + 84
51  CoreFoundation                  0x4fd062d6 __CFRunLoopDoSources0 + 200
52  CoreFoundation                  0x4fd02264 __CFRunLoopRun + 732
53  CoreFoundation                  0x4fd01cec CFRunLoopRunSpecific + 326
54  GraphicsServices                0x52b6bd3c GSEventRunModal + 132
55  UIKitCore                       0x67d7736e UIApplicationMain + 1720
56  libxpc.dylib                    0x4faa3f0c _xpc_objc_main.cold.3 + 152
57  libxpc.dylib                    0x4fa94e8c _xpc_objc_main + 184
58  libxpc.dylib                    0x4fa96ae8 xpc_main + 110
59  Foundation                      0x50617090 +[NSXPCListener serviceListener] + 0
60  PlugInKit                       0x577f0392 0x577de000 + 74642
61  WatchKit                        0x5f18faf0 WKExtensionMain + 62
62  libdyld.dylib                   0x4f8bd7b2 start + 2

Thread 1:
0   libsystem_pthread.dylib         0x4fa5bf24 start_wqthread + 0

Thread 2:
0   libsystem_pthread.dylib         0x4fa5bf24 start_wqthread + 0

Thread 3:
0   libsystem_pthread.dylib         0x4fa5bf24 start_wqthread + 0

Thread 4 name:  com.apple.uikit.eventfetch-thread
Thread 4:
0   libsystem_kernel.dylib          0x4f9c76a8 mach_msg_trap + 20
1   libsystem_kernel.dylib          0x4f9c6d7a mach_msg + 42
2   CoreFoundation                  0x4fd06390 __CFRunLoopServiceMachPort + 106
3   CoreFoundation                  0x4fd0238a __CFRunLoopRun + 1026
4   CoreFoundation                  0x4fd01cec CFRunLoopRunSpecific + 326
5   Foundation                      0x505e3a58 -[NSRunLoop+ 27224 (NSRunLoop) runMode:beforeDate:] + 180
6   Foundation                      0x505e3974 -[NSRunLoop+ 26996 (NSRunLoop) runUntilDate:] + 76
7   UIKitCore                       0x67df5f18 -[UIEventFetcher threadMain] + 140
8   Foundation                      0x506e4308 __NSThread__start__ + 708
9   libsystem_pthread.dylib         0x4fa55236 _pthread_start + 130
10  libsystem_pthread.dylib         0x4fa5bf50 thread_start + 20

Thread 5:
0   libsystem_pthread.dylib         0x4fa5bf24 start_wqthread + 0

Thread 6:
0   libsystem_pthread.dylib         0x4fa5bf24 start_wqthread + 0

Thread 7:
0   libsystem_pthread.dylib         0x4fa5bf24 start_wqthread + 0

Thread 8 name:  Dispatch queue: com.apple.NSXPCConnection.m-user.com.apple.nsurlsessiond.NSURLSessionProxyService
Thread 8:
0   libsystem_kernel.dylib          0x4f9e0bac kevent_id + 24
1   libdispatch.dylib               0x4f89aec8 _dispatch_kq_poll + 144
2   libdispatch.dylib               0x4f89a73a _dispatch_event_loop_poke + 650
3   libdispatch.dylib               0x4f889dee _dispatch_queue_wakeup + 354
4   CFNetwork                       0x5044ee96 0x502f6000 + 1412758
5   CoreFoundation                  0x4fd6f564 __invoking___ + 84
6   CoreFoundation                  0x4fc83cf6 -[NSInvocation invoke] + 274
7   Foundation                      0x507c00bc __NSXPCCONNECTION_IS_CALLING_OUT_TO_EXPORTED_OBJECT__ + 22
8   Foundation                      0x506256fc -[NSXPCConnection _decodeAndInvokeMessageWithEvent:flags:] + 1168
9   Foundation                      0x507c01e0 message_handler + 196
10  libxpc.dylib                    0x4fa8f730 _xpc_connection_call_event_handler + 36
11  libxpc.dylib                    0x4fa8fa04 _xpc_connection_mach_event + 716
12  libdispatch.dylib               0x4f882e8c _dispatch_client_callout4 + 8
13  libdispatch.dylib               0x4f895cda _dispatch_mach_msg_invoke + 312
14  libdispatch.dylib               0x4f887ca2 _dispatch_lane_serial_drain + 308
15  libdispatch.dylib               0x4f8966a8 _dispatch_mach_invoke + 418
16  libdispatch.dylib               0x4f887ca2 _dispatch_lane_serial_drain + 308
17  libdispatch.dylib               0x4f888650 _dispatch_lane_invoke + 352
18  libdispatch.dylib               0x4f890334 _dispatch_workloop_worker_thread + 508
19  libsystem_pthread.dylib         0x4fa56cfc _pthread_wqthread + 204
20  libsystem_pthread.dylib         0x4fa5bf38 start_wqthread + 20

Thread 9:
0   libsystem_pthread.dylib         0x4fa5bf24 start_wqthread + 0

Thread 0 crashed with ARM Thread State (32-bit):
    r0: 0x00000001    r1: 0x00000000      r2: 0x00000001      r3: 0x00000000
    r4: 0x00000001    r5: 0x00000001      r6: 0x000000e4      r7: 0x27bcd708
    r8: 0x00000000    r9: 0x00000000     r10: 0x00000000     r11: 0x16db3fd0
    ip: 0xfff00000    sp: 0x27bcd670      lr: 0x6f7f007f      pc: 0x6f7f4060
  cpsr: 0x60000030

Binary Images:
0x234000 - 0x3d3fff Watch App Extension armv7k  <53780c55b55534578139202ab803cb6a> /var/containers/Bundle/Application/8D10BAB7-2EDF-4C98-8558-915BEBC0F499/Watch App.app/PlugIns/Watch App Extension.appex/Watch App Extension
0x504000 - 0x513fff libobjc-trampolines.dylib armv7k  <6ad2db0ce5f230ef93a1624440cf513a> /usr/lib/libobjc-trampolines.dylib
0x590000 - 0x5ebfff dyld armv7k  <3cbcec3e342e3bfab00f28eb029de430> /usr/lib/dyld
0x4f772000 - 0x4f775fff libSystem.B.dylib armv7k  <bfe605fff46e3cfe8397e37435e59490> /usr/lib/libSystem.B.dylib
0x4f776000 - 0x4f7b9fff libc++.1.dylib armv7k  <68da4f7256543e498f1e74e33a812556> /usr/lib/libc++.1.dylib
0x4f7ba000 - 0x4f7cdfff libc++abi.dylib armv7k  <1d210edc8eba3fcfa230d00b69cb680e> /usr/lib/libc++abi.dylib
0x4f7ce000 - 0x4f7f9fff libobjc.A.dylib armv7k  <0d9598610d3d3e1a8fe88321114d241b> /usr/lib/libobjc.A.dylib
0x4f7fa000 - 0x4f801fff libcache.dylib armv7k  <08fbf121eaf13f1da5f709956c6e2c70> /usr/lib/system/libcache.dylib
...
...
...

解决方法

这是一个已知问题

https://github.com/Alamofire/Alamofire/issues/3295

除了 Apple 发布了针对其错误的修复程序之外 - 解决方法包括:

在监视扩展目标中将死代码剥离设置为否。

不同版本的 Alamofire。

将 AF 从 SPM 转移到 CocoaPods。

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐


依赖报错 idea导入项目后依赖报错,解决方案:https://blog.csdn.net/weixin_42420249/article/details/81191861 依赖版本报错:更换其他版本 无法下载依赖可参考:https://blog.csdn.net/weixin_42628809/a
错误1:代码生成器依赖和mybatis依赖冲突 启动项目时报错如下 2021-12-03 13:33:33.927 ERROR 7228 [ main] o.s.b.d.LoggingFailureAnalysisReporter : *************************** APPL
错误1:gradle项目控制台输出为乱码 # 解决方案:https://blog.csdn.net/weixin_43501566/article/details/112482302 # 在gradle-wrapper.properties 添加以下内容 org.gradle.jvmargs=-Df
错误还原:在查询的过程中,传入的workType为0时,该条件不起作用 &lt;select id=&quot;xxx&quot;&gt; SELECT di.id, di.name, di.work_type, di.updated... &lt;where&gt; &lt;if test=&qu
报错如下,gcc版本太低 ^ server.c:5346:31: 错误:‘struct redisServer’没有名为‘server_cpulist’的成员 redisSetCpuAffinity(server.server_cpulist); ^ server.c: 在函数‘hasActiveC
解决方案1 1、改项目中.idea/workspace.xml配置文件,增加dynamic.classpath参数 2、搜索PropertiesComponent,添加如下 &lt;property name=&quot;dynamic.classpath&quot; value=&quot;tru
删除根组件app.vue中的默认代码后报错:Module Error (from ./node_modules/eslint-loader/index.js): 解决方案:关闭ESlint代码检测,在项目根目录创建vue.config.js,在文件中添加 module.exports = { lin
查看spark默认的python版本 [root@master day27]# pyspark /home/software/spark-2.3.4-bin-hadoop2.7/conf/spark-env.sh: line 2: /usr/local/hadoop/bin/hadoop: No s
使用本地python环境可以成功执行 import pandas as pd import matplotlib.pyplot as plt # 设置字体 plt.rcParams[&#39;font.sans-serif&#39;] = [&#39;SimHei&#39;] # 能正确显示负号 p
错误1:Request method ‘DELETE‘ not supported 错误还原:controller层有一个接口,访问该接口时报错:Request method ‘DELETE‘ not supported 错误原因:没有接收到前端传入的参数,修改为如下 参考 错误2:cannot r
错误1:启动docker镜像时报错:Error response from daemon: driver failed programming external connectivity on endpoint quirky_allen 解决方法:重启docker -&gt; systemctl r
错误1:private field ‘xxx‘ is never assigned 按Altʾnter快捷键,选择第2项 参考:https://blog.csdn.net/shi_hong_fei_hei/article/details/88814070 错误2:启动时报错,不能找到主启动类 #
报错如下,通过源不能下载,最后警告pip需升级版本 Requirement already satisfied: pip in c:\users\ychen\appdata\local\programs\python\python310\lib\site-packages (22.0.4) Coll
错误1:maven打包报错 错误还原:使用maven打包项目时报错如下 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0:resources (default-resources)
错误1:服务调用时报错 服务消费者模块assess通过openFeign调用服务提供者模块hires 如下为服务提供者模块hires的控制层接口 @RestController @RequestMapping(&quot;/hires&quot;) public class FeignControl
错误1:运行项目后报如下错误 解决方案 报错2:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project sb 解决方案:在pom.
参考 错误原因 过滤器或拦截器在生效时,redisTemplate还没有注入 解决方案:在注入容器时就生效 @Component //项目运行时就注入Spring容器 public class RedisBean { @Resource private RedisTemplate&lt;String
使用vite构建项目报错 C:\Users\ychen\work&gt;npm init @vitejs/app @vitejs/create-app is deprecated, use npm init vite instead C:\Users\ychen\AppData\Local\npm-