flutter / flutter

Flutter makes it easy and fast to build beautiful apps for mobile and beyond
https://flutter.dev
BSD 3-Clause "New" or "Revised" License
165.55k stars 27.33k forks source link

iOS production app crash #29895

Closed irwinOT closed 4 years ago

irwinOT commented 5 years ago

First, sorry for my english.

Second, I put the question on stackoverflow.com but I have no answer.

In development it was tested and worked well, both in Android and in iOS. A production .app was generated, apple app store was sent and an error occurred:

Apple Message: We were unable to review your app as it crashed on launch. We have attached detailed crash logs to help troubleshoot this issue.

Apple Log:

Date/Time:           2019-03-21 08:46:52.1150 -0700
Launch Time:         2019-03-21 08:46:51.4234 -0700
OS Version:          iPhone OS 12.1.4 (16D57)
Baseband Version:    n/a
Report Version:      104

Exception Type:  EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note:  EXC_CORPSE_NOTIFY
Triggered by Thread:  0

Application Specific Information:
abort() called

Thread 0 name:  Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0   libsystem_kernel.dylib          0x000000023c1ff104 0x23c1dc000 + 143620
1   libsystem_pthread.dylib         0x000000023c27b020 0x23c279000 + 8224
2   libsystem_c.dylib               0x000000023c156d78 0x23c0ff000 + 359800
3   Flutter                         0x000000010144fa84 0x10141c000 + 211588
4   Flutter                         0x0000000101497318 0x10141c000 + 504600
5   Flutter                         0x0000000101429720 0x10141c000 + 55072
6   Flutter                         0x0000000101437bec 0x10141c000 + 113644
7   UIKitCore                       0x0000000269226350 0x268c98000 + 5825360
8   UIFoundation                    0x0000000246cd5cc4 0x246c68000 + 449732
9   UIFoundation                    0x0000000246c7481c 0x246c68000 + 51228
10  UIKitCore                       0x000000026922a838 0x268c98000 + 5843000
11  UIFoundation                    0x0000000246cd5cc4 0x246c68000 + 449732
12  UIFoundation                    0x0000000246cd5f08 0x246c68000 + 450312
13  UIFoundation                    0x0000000246c7481c 0x246c68000 + 51228
14  UIKitCore                       0x0000000269228138 0x268c98000 + 5833016
15  UIKitCore                       0x0000000269715f48 0x268c98000 + 11001672
16  UIKitCore                       0x0000000269580380 0x268c98000 + 9339776
17  UIKitCore                       0x0000000269580858 0x268c98000 + 9341016
18  UIKitCore                       0x000000026957ed68 0x268c98000 + 9334120
19  UIKitCore                       0x0000000268e1a93c 0x268c98000 + 1583420
20  UIKitCore                       0x0000000268e235bc 0x268c98000 + 1619388
21  UIKitCore                       0x0000000268e1a5b8 0x268c98000 + 1582520
22  UIKitCore                       0x0000000268e1af58 0x268c98000 + 1584984
23  UIKitCore                       0x0000000268e19058 0x268c98000 + 1577048
24  UIKitCore                       0x0000000268e18d04 0x268c98000 + 1576196
25  UIKitCore                       0x0000000268e1dec4 0x268c98000 + 1597124
26  UIKitCore                       0x0000000268e1ee24 0x268c98000 + 1601060
27  UIKitCore                       0x0000000268e1dd7c 0x268c98000 + 1596796
28  UIKitCore                       0x0000000268e22c68 0x268c98000 + 1617000
29  UIKitCore                       0x000000026957d34c 0x268c98000 + 9327436
30  UIKitCore                       0x0000000269168244 0x268c98000 + 5046852
31  FrontBoardServices              0x000000023f0a09d4 0x23f094000 + 51668
32  FrontBoardServices              0x000000023f0ab79c 0x23f094000 + 96156
33  FrontBoardServices              0x000000023f0aae94 0x23f094000 + 93844
34  libdispatch.dylib               0x000000023c0a2484 0x23c041000 + 398468
35  libdispatch.dylib               0x000000023c045e10 0x23c041000 + 19984
36  FrontBoardServices              0x000000023f0dfa9c 0x23f094000 + 309916
37  FrontBoardServices              0x000000023f0df728 0x23f094000 + 309032
38  FrontBoardServices              0x000000023f0dfd44 0x23f094000 + 310596
39  CoreFoundation                  0x000000023c5fa0e0 0x23c54d000 + 708832
40  CoreFoundation                  0x000000023c5fa060 0x23c54d000 + 708704
41  CoreFoundation                  0x000000023c5f9944 0x23c54d000 + 706884
42  CoreFoundation                  0x000000023c5f4810 0x23c54d000 + 686096
43  CoreFoundation                  0x000000023c5f40e0 0x23c54d000 + 684256
44  GraphicsServices                0x000000023e86d584 0x23e862000 + 46468
45  UIKitCore                       0x0000000269580c00 0x268c98000 + 9341952
46  Runner                          0x000000010086c284 0x100868000 + 17028
47  libdyld.dylib                   0x000000023c0b2bb4 0x23c0b2000 + 2996

Thread 1:
0   libsystem_pthread.dylib         0x000000023c287ce8 0x23c279000 + 60648

Thread 2:
0   libsystem_pthread.dylib         0x000000023c287ce8 0x23c279000 + 60648

Thread 3 name:  com.apple.uikit.eventfetch-thread
Thread 3:
0   libsystem_kernel.dylib          0x000000023c1f3ea4 0x23c1dc000 + 97956
1   libsystem_kernel.dylib          0x000000023c1f337c 0x23c1dc000 + 95100
2   CoreFoundation                  0x000000023c5f9ad8 0x23c54d000 + 707288
3   CoreFoundation                  0x000000023c5f4974 0x23c54d000 + 686452
4   CoreFoundation                  0x000000023c5f40e0 0x23c54d000 + 684256
5   Foundation                      0x000000023cfea494 0x23cfe2000 + 33940
6   Foundation                      0x000000023cfea340 0x23cfe2000 + 33600
7   UIKitCore                       0x00000002696710c4 0x268c98000 + 10326212
8   Foundation                      0x000000023d11d23c 0x23cfe2000 + 1290812
9   libsystem_pthread.dylib         0x000000023c28425c 0x23c279000 + 45660
10  libsystem_pthread.dylib         0x000000023c2841bc 0x23c279000 + 45500
11  libsystem_pthread.dylib         0x000000023c287cf4 0x23c279000 + 60660

Thread 4:
0   libsystem_pthread.dylib         0x000000023c287ce8 0x23c279000 + 60648

Thread 5:
0   libsystem_pthread.dylib         0x000000023c287ce8 0x23c279000 + 60648

Thread 6 name:  io.flutter.1.ui
Thread 6:
0   libsystem_kernel.dylib          0x000000023c1f3ea4 0x23c1dc000 + 97956
1   libsystem_kernel.dylib          0x000000023c1f337c 0x23c1dc000 + 95100
2   CoreFoundation                  0x000000023c5f9ad8 0x23c54d000 + 707288
3   CoreFoundation                  0x000000023c5f4974 0x23c54d000 + 686452
4   CoreFoundation                  0x000000023c5f40e0 0x23c54d000 + 684256
5   Flutter                         0x0000000101452858 0x10141c000 + 223320
6   Flutter                         0x0000000101452100 0x10141c000 + 221440
7   libsystem_pthread.dylib         0x000000023c28425c 0x23c279000 + 45660
8   libsystem_pthread.dylib         0x000000023c2841bc 0x23c279000 + 45500
9   libsystem_pthread.dylib         0x000000023c287cf4 0x23c279000 + 60660

Thread 7 name:  io.flutter.1.gpu
Thread 7:
0   libsystem_kernel.dylib          0x000000023c1f3ea4 0x23c1dc000 + 97956
1   libsystem_kernel.dylib          0x000000023c1f337c 0x23c1dc000 + 95100
2   CoreFoundation                  0x000000023c5f9ad8 0x23c54d000 + 707288
3   CoreFoundation                  0x000000023c5f4974 0x23c54d000 + 686452
4   CoreFoundation                  0x000000023c5f40e0 0x23c54d000 + 684256
5   Flutter                         0x0000000101452858 0x10141c000 + 223320
6   Flutter                         0x0000000101452100 0x10141c000 + 221440
7   libsystem_pthread.dylib         0x000000023c28425c 0x23c279000 + 45660
8   libsystem_pthread.dylib         0x000000023c2841bc 0x23c279000 + 45500
9   libsystem_pthread.dylib         0x000000023c287cf4 0x23c279000 + 60660

Thread 8 name:  io.flutter.1.io
Thread 8:
0   libsystem_kernel.dylib          0x000000023c1f3ea4 0x23c1dc000 + 97956
1   libsystem_kernel.dylib          0x000000023c1f337c 0x23c1dc000 + 95100
2   CoreFoundation                  0x000000023c5f9ad8 0x23c54d000 + 707288
3   CoreFoundation                  0x000000023c5f4974 0x23c54d000 + 686452
4   CoreFoundation                  0x000000023c5f40e0 0x23c54d000 + 684256
5   Flutter                         0x0000000101452858 0x10141c000 + 223320
6   Flutter                         0x0000000101452100 0x10141c000 + 221440
7   libsystem_pthread.dylib         0x000000023c28425c 0x23c279000 + 45660
8   libsystem_pthread.dylib         0x000000023c2841bc 0x23c279000 + 45500
9   libsystem_pthread.dylib         0x000000023c287cf4 0x23c279000 + 60660

Thread 0 crashed with ARM Thread State (64-bit):
    x0: 0x0000000000000000   x1: 0x0000000000000000   x2: 0x0000000000000000   x3: 0x000000023c236b2c
    x4: 0x0000000101b5b6b0   x5: 0x0000000000000014   x6: 0x0050000004210103   x7: 0x000000000000003f
    x8: 0x0000000000000800   x9: 0x000000023c27f820  x10: 0x000000023c27aea4  x11: 0x0000000277cc83f5
   x12: 0x0000000277cc83f5  x13: 0x0000000000000015  x14: 0x0000000000000001  x15: 0x0000000000000881
   x16: 0x0000000000000148  x17: 0x0000000000000000  x18: 0x0000000000000000  x19: 0x0000000000000006
   x20: 0x00000001013e6b80  x21: 0x000000000000000a  x22: 0x0000000000000303  x23: 0x00000001013e6c60
   x24: 0x0000000000000000  x25: 0x00000002811c42a0  x26: 0x00000002828d4e20  x27: 0x00000002832d0410
   x28: 0x0000000000000019   fp: 0x000000016f593590   lr: 0x000000023c27b020
    sp: 0x000000016f593560   pc: 0x000000023c1ff104 cpsr: 0x00000000

FLUTTER DOCTOR:

[✓] Flutter (Channel stable, v1.2.1, on Mac OS X 10.13.6 17G5019, locale es-EC)
    • Flutter version 1.2.1 at /Users/irwinortiz/Documents/flutter
    • Framework revision 8661d8aecd (5 weeks ago), 2019-02-14 19:19:53 -0800
    • Engine revision 3757390fa4
    • Dart version 2.1.2 (build 2.1.2-dev.0.0 0a7dcf17eb)

[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
    • Android SDK at /Users/irwinortiz/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-28, build-tools 28.0.3
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)
    • All Android licenses accepted.

[✓] iOS toolchain - develop for iOS devices (Xcode 10.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 10.1, Build version 10B61
    • ios-deploy 1.9.4
    • CocoaPods version 1.5.3

[✓] Android Studio (version 3.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 33.4.1
    • Dart plugin version 182.5215
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)

[✓] VS Code (version 1.32.3)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 2.24.0

[✓] Connected device (1 available)
    • BLL L23 • 9DLDU17214008625 • android-arm64 • Android 6.0 (API 23)
irwinOT commented 5 years ago

cc @cyanglaz

irwinOT commented 5 years ago

@mraleph

mraleph commented 5 years ago

@cbracken can somebody on the Flutter team symbolize this crash?

cyanglaz commented 5 years ago

@mraleph @irwinOT I don't think anyone other than the app owner can symbolicate this crash log without a dSYM. Maybe you can follow this to try to symbolicate the crash? As much as I want to help, without a symbolicated crash log, it is very difficult to know what's going on.

mraleph commented 5 years ago

@cyanglaz Flutter framework is prebuilt so Flutter team should have dSYM for it. Unless of course those are not archived - which would be a pity.

mraleph commented 5 years ago

They are in fact archived: instructions are here https://github.com/flutter/flutter/wiki/Crashes

I went ahead and symbolicated Flutter frames using dSYM from engine build 3757390fa4b00d2d261bfdf5182d2e87c9113ff9

$ atos -arch arm64 -o Flutter.dSYM/**/Flutter -l 0x10141c000 0x000000010144fa84
fml::DataMapping::~DataMapping() (in Flutter) (mapping.cc:15)
$ atos -arch arm64 -o Flutter.dSYM/**/Flutter -l 0x10141c000 0x0000000101497318
shell::Shell::Create(blink::TaskRunners, blink::Settings, std::__1::function<std::__1::unique_ptr<shell::PlatformView, std::__1::default_delete<shell::PlatformView> > (shell::Shell&)>, std::__1::function<std::__1::unique_ptr<shell::Rasterizer, std::__1::default_delete<shell::Rasterizer> > (shell::Shell&)>) (in Flutter) (shell.cc:209)
$ atos -arch arm64 -o Flutter.dSYM/**/Flutter -l 0x10141c000 0x0000000101429720
-[FlutterEngine createShell:libraryURI:] (in Flutter) (FlutterEngine.mm:360)
$ atos -arch arm64 -o Flutter.dSYM/**/Flutter -l 0x10141c000 0x0000000101437bec
-[FlutterViewController initWithProject:nibName:bundle:] (in Flutter) (FlutterViewController.mm:75)

Unfortunately this symbolication is not that helpful to me (e.g. I don't think the code in question can actually call DataMapping::~DataMapping, I think this is just code deduplication where multiple destructors with the same body ended up at the same address in the binary) - but somebody with Shell knowledge (@chinmaygarde ?) might be able to reason what exactly went wrong.

irwinOT commented 5 years ago

@cyanglaz @cbracken See how this incidence can be reproduced (I have already done it with 3 different devices and three different devices):

  1. flutter create "my_app" (ok)
  2. flutter run (this runs ok)
  3. flutter build ios (ok)
  4. flutter install (ok)
  5. I open the installed app - EXC_CRASH (SIGABRT)
Hixie commented 4 years ago

We cannot reproduce this as reported. If you are still seeing this, I recommend trying a new host machine, a new device, and a newer version of Flutter. If you're still seeing it then, please provide precise steps to reproduce in a new bug with extreme detail.

pacozaa commented 4 years ago

@irwinOT I am facing the same error. Do you manage to solve it?

github-actions[bot] commented 3 years ago

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.