pmusolino / Wormholy

iOS network debugging, like a wizard 🧙‍♂️
MIT License
2.31k stars 184 forks source link

crash on iOS 15.0.0 #103

Closed skeyboy closed 2 years ago

skeyboy commented 2 years ago

rashed: com.apple.main-thread 0 libswiftCore.dylib 0x18930dfd0 + 204 1 libswiftCore.dylib 0x18931a428 swift_checkMetadataState + 44 2 libswiftCore.dylib 0x18933c6ac + 252 3 libswiftCore.dylib 0x18933bc40 + 276 4 Wormholy 0x1073c7be0 WormholyReplaceMethod + 136788 5 Wormholy 0x1073c7ab8 WormholyReplaceMethod + 136492 6 CoreFoundation 0x184694a58 + 28 7 CoreFoundation 0x1847303b8 + 52 8 CoreFoundation 0x184703c10 + 440 9 CoreFoundation 0x1846aa55c _CFXNotificationPost + 716 10 Foundation 0x185e8a9dc + 64 11 UIKitCore 0x186ff76e0 + 3812 12 UIKitCore 0x186fe0398 + 1208 13 UIKitCore 0x186e3be38 + 152 14 UIKitCore 0x186c93e0c _UIScenePerformActionsWithLifecycleActionMask + 104 15 UIKitCore 0x186dbf200 + 224 16 UIKitCore 0x186ee0254 + 248 17 UIKitCore 0x187122a2c + 760 18 UIKitCore 0x1870adae4 + 340 19 UIKitCore 0x186c94c10 + 196 20 UIKitCore 0x186d54d78 + 892 21 UIKitCore 0x186c96ad4 _UISceneSettingsDiffActionPerformChangesWithTransitionContext + 276 22 UIKitCore 0x186d81688 + 384 23 UIKitCore 0x18720a04c + 776 24 UIKitCore 0x186cc59d8 + 256 25 UIKitCore 0x186d08c70 + 288 26 UIKitCore 0x186e40d38 + 572 27 UIKitCore 0x186d7f948 + 388 28 FrontBoardServices 0x196578e80 + 440 29 FrontBoardServices 0x19659ed3c + 128 30 FrontBoardServices 0x196559884 + 240 31 FrontBoardServices 0x19655aec4 + 372 32 libdispatch.dylib 0x1843765b0 + 20 33 libdispatch.dylib 0x18437a0e4 + 268 34 FrontBoardServices 0x19655b164 + 48 35 FrontBoardServices 0x19655a5a4 + 220 36 FrontBoardServices 0x19655ebb4 + 28 37 CoreFoundation 0x184724a7c + 28 38 CoreFoundation 0x184735498 + 208 39 CoreFoundation 0x184670250 + 268 40 CoreFoundation 0x18467595c + 820 41 CoreFoundation 0x18468924c CFRunLoopRunSpecific + 600 42 GraphicsServices 0x1a0233484 GSEventRunModal + 164 43 UIKitCore 0x187000110 + 1100 44 UIKitCore 0x186d7d088 UIApplicationMain + 2204 45 atome 0x104325108 main + 25 (xxxxxx.swift:25) 46 ??? 0x104c69e64 (缺少)

pmusolino commented 2 years ago

Hello there. Are you sure it's related to Wormholy? How to replicate it?

skeyboy commented 2 years ago

I. just. got. it from. firebase report

backslash-f commented 2 years ago

I'm also facing a crash in iOS 15.

I think you could reproduce it by creating a project that uses Wormholy in the latest Xcode 13 and running it against a simulator (iOS 15).

My versions:

Wormholy version: 1.6.4 (integrate via Cocoapods) Xcode version: 13.0 beta 3 (13A5192j) iOS: 15 beta 3 (19A5297e)

To me it crashes right after the app starts. Here are the relevant parts of the stack trace:


// ... inside the "CustomSelfAwareHelper.harmlessFunction"
for index in 0 ..< typeCount {
    (types[index] as? SelfAware.Type)?.awake() // LLDB says it crashes exactly in the "as?" part of the function, with a "Thread 1: EXC_BAD_ACCESS" exception
}

static CustomSelfAwareHelper.harmlessFunction()

0x111e33951 <+81>:  callq  0x111e33a00               ; function signature specialization <Arg[0] = Dead> of static Wormholy.CustomSelfAwareHelper.harmlessFunction() -> () at SwiftySelfAwareHelper.swift:18

0x129775e0b <+101>: leaq   0x7fdcfa(%rip), %rdi      ; "Application violated contract by causing UIApplicationMain() to return. This incident will be reported."

If I remove Wormhly, the app doesn't crash anymore.

Let me know if more info is needed, thanks.

backslash-f commented 2 years ago

Oh, and finally: it crashes when building for Release; (Xcode / Edit scheme / Run / Info / Build configuration / Release)

We weren't facing it during development as we were installing the app via Xcode in debug mode; QA was facing it in TestFlight builds (release mode).

You may not be able to reproduce w/o using Release mode.

Very tricky.

kitskomina commented 2 years ago

We also have got a crash on production build related to WormholyReplaceMethod call on iOS 15 beta.

danspndl commented 2 years ago

Possibly got the same crash, app works fine on iOS 14.x, but crashes on iOS 15b3. We only use Wormholy for debug builds. The project is built with Xcode 12.5.1

Screenshot 2021-07-21 at 15 53 03 Screenshot 2021-07-21 at 15 49 52