Post

Replies

Boosts

Views

Activity

TestFlight watchOS build crashes on Apple Watch Series 3 devices (32-bit) (Bitcode related?)
Hello! I have a WatchOS Application on TestFlight that is crashing on startup on Apple Watch Series 3 devices (32-bit). It works flawlessly on Simulators (Xcode 11.7) and Apple Watch Series 4. I am using Alamofire 5.2.2 with Swift Package Manager. Latest Xcode (version 11.7). The device is Apple Watch Series 3 devices (32-bit) running latest final watchOS (version 6.2.8). I am calling a REST service that returns a JSON error file (response) and HTTP status code 401 (Unauthorized) if no gateway access token is given. As I said this works in simulator and Apple Watch Series 4 device. I suspect of Bitcode, as in the past versions I had an iOS companion app and disabled bitcode generation, but now we only have the watch app and I cannot disable Bitcode generation. What happened instead? The crash is somewhat like this: 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 ... 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 NOTE Unfortunately this is a big project for a bank. I do not have yet a demo project because the error only occurs via TestFlight installing on Apple Watch Series 3 (32-bits). Already opened an issue on Alamofire GitHub but they said maybe it is an Apple TestFlight generation (bitcode?) error. < https://github.com/Alamofire/Alamofire/issues/3295 >
14
0
3.5k
Sep ’20
watchOS 7 beta networking gives SSL error
I have a watch app that is working OK with watchOS 6. It uses AlamoFire 5 for networking. Testing it with watchOS 7, it gives this error "Error Domain=NSURLErrorDomain Code=-1200 "An SSL error has occurred and a secure connection to the server cannot be made." if I disable Certificate Pinning (PinnedCertificatesTrustEvaluator). If I enable it, the error is "Code=-67820 "Certificate 2 “Trusted Root CA SHA256 G2” has errors: Certificate is revoked;". The same certificate I use on the app on watchOS 6 and it was generated with the openssl command (openssl sclient -connect <SITEURL>:443 </dev/null | openssl x509 -outform DER -out cert.der). I have nothing related to networking configured in a .plist. Someone knows what's changed in watchOS 7 or need to be done in Alamofire 5 ? Thank you in advance!
8
0
1.6k
Aug ’20