Issue with crash log on huawei generally (p8 in specific)

I’ve a crash in a p8 huawei device but there’s no way to understand where crash happen. The main issue seems that huawei log is not complete. I’ve found a procedure to activate logs on huawei device and follow it but during crash i cannot identify crashing thread or last line log. (https://www.xda-developers.com/huawei-phones-disable-logcat-heres-how-to-restore-access/)

Have you some advice to understand, or activate some others, huawei logs during crash?
Here you can find my last crash.

10-23 14:19:01.102 19471 20044 I libc    : Another thread contacted debuggerd first; not contacting debuggerd.: redevogames.redmption.tcg
10-23 14:19:01.114 19471 19519 I trace   : ClientCardView.hx:129: downscaleCard AFTER b:(270,405): redevogames.redmption.tcg
10-23 14:19:01.114 19471 19519 I trace   : StartupLoadingManager.hx:422: ----------------> GeneralStatus:37.441058079356: redevogames.redmption.tcg
10-23 14:19:01.114 19471 19519 I trace   : GetLargeImages.hx:174: loadCardsImagesFromDevice.length:153 _remainingOnDeviceAvatars.length:156: redevogames.redmption.tcg
10-23 14:19:01.114 19471 19519 I trace   : GetLargeImages.hx:177: loadCardsImagesFromDevice 1: redevogames.redmption.tcg
10-23 14:19:01.114 19471 19519 I trace   : GetLargeImages.hx:212: readSingleImage: msaterId:224 type:TypeCardImage: redevogames.redmption.tcg
10-23 14:19:01.142 19471 19519 I trace   : GetLargeImages.hx:221: onComplete() _imageRequested-_imageRequestProcessed:(160-7): redevogames.redmption.tcg
10-23 14:19:01.143 19471 19519 I trace   : ClientCardView.hx:127: downscaleCard tScale:1.5 SCALEX:1.24583333333333 scaleFactor:0.6 b:(360,540): redevogames.redmption.tcg
10-23 14:19:01.176 19471 19519 I trace   : ClientCardView.hx:129: downscaleCard AFTER b:(270,405): redevogames.redmption.tcg
10-23 14:19:01.176 19471 19519 I trace   : StartupLoadingManager.hx:422: ----------------> GeneralStatus:37.6032202415182: redevogames.redmption.tcg
10-23 14:19:01.176 19471 19519 I trace   : GetLargeImages.hx:174: loadCardsImagesFromDevice.length:151 _remainingOnDeviceAvatars.length:156: redevogames.redmption.tcg
10-23 14:19:01.176 19471 19519 I trace   : GetLargeImages.hx:177: loadCardsImagesFromDevice 1: redevogames.redmption.tcg
10-23 14:19:01.176 19471 19519 I trace   : GetLargeImages.hx:212: readSingleImage: msaterId:147 type:TypeCardImage: redevogames.redmption.tcg
10-23 14:19:01.609  3089 20056 I am_crash: [3089,0,redevogames.redmption.tcg,948485700,Native crash,Segmentation fault,unknown,0]: system_server
10-23 14:19:01.610  2478  2478 E DEBUG   : AM write failed: Broken pipe: /system/bin/debuggerd
10-23 14:19:01.612  3089 20056 I am_finish_activity: [0,257567661,19,redevogames.redmption.tcg/.MainActivity,force-crash]: system_server
10-23 14:19:01.616  2467  2513 I [Gralloc]: alloc w[428] h[240] format[1] usage[819]: /system/bin/surfaceflinger
10-23 14:19:01.616  2467  2513 I [Gralloc]: alloc succ handle[0x559d078b70] stride[428]: /system/bin/surfaceflinger
10-23 14:19:01.618  2467  2467 E HAL     : load: id=gralloc != hmi->id=gralloc: /system/bin/surfaceflinger
10-23 14:19:01.630  3089 20056 I am_pause_activity: [0,257567661,redevogames.redmption.tcg/.MainActivity]: system_server
10-23 14:19:01.648  3089  3089 I SendBroadcastPermission: action:android.intent.action.DROPBOX_ENTRY_ADDED, mPermissionType:0: system_server
10-23 14:19:01.649  2712  3070 I logserver: handle_logfile_events, Object Path:/data/system/dropbox/, mask=0x00000080: /system/bin/logserver
10-23 14:19:01.649  2712  3070 I logserver: process_one_event, event->len=48, [email protected]: /system/bin/logserver
10-23 14:19:01.649  2712  3070 E logserver: process_one_event, can not find this event([email protected]): /system/bin/logserver
10-23 14:19:01.649  2712  3070 I logserver: clean_cur_cache:999, system(rm -r /data/log/logcache/-151746256/* > /dev/null 2>&1): /system/bin/logserver
10-23 14:19:01.665  3089  3807 I am_create_service: [0,96426513,.DropBoxEntryAddedService,10009,4621]: system_server
10-23 14:19:01.677  3089  3089 I SendBroadcastPermission: action:android.intent.action.DROPBOX_ENTRY_ADDED, mPermissionType:0: system_server
10-23 14:19:01.686  2712  3070 I logserver: handle_logfile_events, Object Path:/data/system/dropbox/, mask=0x00000080: /system/bin/logserver
10-23 14:19:01.686  2712  3070 I logserver: process_one_event, event->len=48, [email protected]: /system/bin/logserver
10-23 14:19:01.686  2712  3070 I logserver: find_first_match: find match, plogs(type=1, pfile=/data/system/dropbox/, match=TOMBSTONE): /system/bin/logserver
10-23 14:19:01.686  2712  3070 I logserver: dump_logs:1872, system(rm -r /data/log/logcache/-151746256/* > /dev/null 2>&1): /system/bin/logserver
10-23 14:19:01.696  3089  3808 I am_destroy_service: [0,96426513,4621]: system_server
10-23 14:19:01.709  2712  3070 I logserver: dump_logs:1880, system(logcat -b main -v threadtime -t 4096 -f  /data/log/logcache/-151746256/20171023141901_main): /system/bin/logserver
10-23 14:19:01.731  2592  2925 I AudioFlinger: BUFFER TIMEOUT: remove(4097) from active list on thread 0xf2b72008: /system/bin/mediaserver
10-23 14:19:01.731  2592  2925 I AudioFlinger: updateWakeLockUids_l() AudioOut_6 mType: 0 status 0: /system/bin/mediaserver
10-23 14:19:01.746  2592  2688 I APM::AudioPolicyManager: stopOutput() output 6, stream 3, session 51: /system/bin/mediaserver
10-23 14:19:01.746  2592  2688 I APM::AudioPolicyManager: getNewOutputDevice() selected device 0: /system/bin/mediaserver
10-23 14:19:01.746  2592  2688 I APM::AudioPolicyManager: setOutputDevice() device 0x0000 delayMs 40: /system/bin/mediaserver
10-23 14:19:01.746  2592  2688 I APM::AudioPolicyManager: setOutputDevice() prevDevice 0x0002: /system/bin/mediaserver
10-23 14:19:01.746  2592  2688 I APM::AudioPolicyManager: setOutputDevice() setting same device 0x0000 or null device: /system/bin/mediaserver
10-23 14:19:01.755  3089  3102 I am_pss  : [3977,10053,com.huawei.android.launcher,62205952,58785792]: system_server
10-23 14:19:01.797  3089  3345 W InputDispatcher: channel '73c9dbf redevogames.redmption.tcg/redevogames.redmption.tcg.MainActivity (server)' ~ Consumer closed input channel or an error occurred.  events=0x9: system_server
10-23 14:19:01.797  3089  3345 E InputDispatcher: channel '73c9dbf redevogames.redmption.tcg/redevogames.redmption.tcg.MainActivity (server)' ~ Channel is unrecoverably broken and will be disposed!: system_server
10-23 14:19:01.797  2491  2491 I Zygote  : Process 19471 exited due to signal (11)
10-23 14:19:01.799  3089  3807 W InputDispatcher: Attempted to unregister already unregistered input channel '73c9dbf redevogames.redmption.tcg/redevogames.redmption.tcg.MainActivity (server)': system_server
10-23 14:19:01.799  3089  3549 I am_proc_died: [0,19471,redevogames.redmption.tcg]: system_server
10-23 14:19:01.800  3089  3549 I am_destroy_service: [0,68879501,7031]: system_server
10-23 14:19:01.800  3089  3549 I am_focused_activity: [-1,NULL]: system_server
10-23 14:19:01.810  3089  3549 I am_home_stack_moved: [0,1,0,0,appDied leftTaskHistoryEmpty]: system_server
10-23 14:19:01.818  3937  4855 W PGApi_client: recv actoionId = 10010, action = [email protected] actionId =10010 pkg =com.huawei.android.launcher extend1 =57 extend2 = flag =3 type =1: com.huawei.powergenie
10-23 14:19:01.818  3937  4855 W PGMiddleWare: in handleAction method, action = 10010: com.huawei.powergenie
10-23 14:19:01.818  3937  4855 W PGMiddleWare: in handleAction, invoke client = [email protected], action = [email protected] actionId =10010 pkg =com.huawei.android.launcher extend1 =57 extend2 = flag =3 type =1: com.huawei.powergenie
10-23 14:19:01.819  2467  3086 I [Gralloc]: alloc w[720] h[1280] format[1] usage[2867]: /system/bin/surfaceflinger
10-23 14:19:01.821  2467  3086 I [Gralloc]: alloc succ handle[0x559d044de0] stride[720]: /system/bin/surfaceflinger
10-23 14:19:01.822  2467  2467 W [Gralloc-Warning]: int gralloc_register_buffer(const gralloc_module_t*, buffer_handle_t):66 Registering handle 0x559d087f80 coming from the same process: 2467.: /system/bin/surfaceflinger
10-23 14:19:01.822  2467  2467 E HAL     : load: id=gralloc != hmi->id=gralloc: /system/bin/surfaceflinger
10-23 14:19:01.830  2467  2467 E HAL     : load: id=gralloc != hmi->id=gralloc: /system/bin/surfaceflinger
10-23 14:19:01.831  2467  2515 I SurfaceFlinger: set Mirror VirtualDisplay orientation = 0: /system/bin/surfaceflinger
10-23 14:19:01.844  3089  3549 I configuration_changed: 1152: system_server
10-23 14:19:01.853  3500  3500 I HwSystemManager: HsmPackageManager:onConfigureChanged: it_IT: com.huawei.systemmanager:service
10-23 14:19:01.858  3089  3346 I InputReader: Reconfiguring input devices.  changes=0x00000004: system_server
10-23 14:19:01.858  3089  3346 I InputReader: Device reconfigured: id=3, name='cyttsp5_mt', size 720x1280, orientation 0, mode 1, display id 0: system_server
10-23 14:19:01.858  2710  3117 E Parcel  : Reading a NULL string not supported here.: /system/bin/defragd
10-23 14:19:01.859  2710  3117 E Parcel  : Reading a NULL string not supported here.: /system/bin/defragd
10-23 14:19:01.859  3943  3943 W Settings: Setting airplane_mode_on has moved from android.provider.Settings.System to android.provider.Settings.Global, returning read-only value.: com.android.phone
10-23 14:19:01.874 11563 11563 I HwSystemManager: HsmPackageManager:onConfigureChanged: it_IT: com.huawei.systemmanager
10-23 14:19:01.881  3089  3549 I wm_stack_removed: 8: system_server
10-23 14:19:01.882  3089  3549 I wm_task_removed: [19,removeAppToken: last token]: system_server
10-23 14:19:01.882  3089  3549 I wm_task_removed: [19,removeTask]: system_server
10-23 14:19:01.889  3089  3549 I am_resume_activity: [0,191984916,1,com.huawei.android.launcher/.Launcher]: system_server
10-23 14:19:01.892  3089  3549 I wm_task_moved: [1,1,0]: system_server
10-23 14:19:01.893  3451  3451 I HwSecImmHelper: mSecurityInputMethodService is null: com.android.systemui
10-23 14:19:01.894  3451  3451 I HwSecImmHelper: mSecurityInputMethodService is null: com.android.systemui
10-23 14:19:01.895  2467  2467 I sf_frame_dur: [SurfaceView,0,0,0,0,1,14,10]: /system/bin/surfaceflinger
10-23 14:19:01.895  2467  2467 I sf_frame_dur: [redevogames.redmption.tcg/redevogames.redmption.tcg.MainActivity,1,0,0,0,0,0,0]: /system/bin/surfaceflinger

Thanks in advance.
David.

This seems to be the most relevant part, your trace at line 212 comes through, but then you get a segmentation fault afterward. The other messages appear to be related to not finding a crash log for the application, and the application ultimately being dead :slight_smile:

Check especially for the possibility of null references, and if you aren’t already, try a -debug build, as it sometimes has a better stack trace

In my experience with android and openfl last log writing is not always the most relevant row, overall if there are threads in the middle. Normally i receive more clear logs in other develop devices. I really hate works on huawei phones.
I’m going to give another chance to debug, really thanks :slight_smile:, as usual.

David.

It looks like the debugger server on the device itself is crashing. I’ve seen this happen with the emulator on Android 7.x and it’s a documented problem, but I’ve never seen it happen on a real device.

As @singmajesty suggested you might want to inspect the code that runs after your trace at line 212 (add more traces?) just to find out where it’s actually crashing. It’s a bit tedious but it might lead you in the right direction.

Un saluto Tanis, Mezzelfo?

Thanks for reply. Going to investigate more using more trace technique seems the only way. Hope to find a solution because this is a scum bug :frowning:

David.

1 Like

It’s a long-shot, but maybe (?) there’s a chance that it doesn’t like how soon the application crashes. Adding Sys.sleep (1) in your code (before where it would crash) might make a difference

Is there any advance with this topic? I am having the same issues with Huawei P8.
Google Play pre-launch report shows me this error: java.lang.NoClassDefFoundError: aewt

This is the whole stacktrace:
FATAL EXCEPTION: Firebase-Messaging-Intent-Handle
Process: com.google.android.youtube, PID: 16887
java.lang.NoClassDefFoundError: aewt
at aewu.b(PG:1)
at duc.a(PG:230)
at duc.get(PG:247)
at aevw.b(PG:1)
at dud.al(PG:5)
at dud.aw(PG:4)
at dud.bg(PG:8)
at duc.a(PG:232)
at duc.get(PG:247)
at afke.a(PG:1)
at aeri.b(PG:1)
at dud.fv(PG:4)
at duc.c(PG:269)
at duc.get(PG:247)
at amfk.a(PG:1)
at eiu.K(PG:5)
at dud.fV(PG:7)
at duc.d(PG:334)
at duc.get(PG:247)
at com.google.android.apps.youtube.app.common.notification.FcmMessageListenerService.b(PG:1)
at com.google.firebase.messaging.FirebaseMessagingService.g(PG:53)
at avgp.run(Unknown Source:7)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
at usj.run(PG:2)
at java.lang.Thread.run(Thread.java:764)
Caused by: java.lang.ExceptionInInitializerError
at aewu.b(PG:1)
at duc.a(PG:230)
at duc.get(PG:247)
at aevw.b(PG:1)
at dud.al(PG:5)
at duc.a(PG:174)
at duc.get(PG:247)
at aeqv.a(PG:6)
at acpw.b(PG:2)
at dxe.a(PG:8)
at dus.onCreate(PG:41)
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1119)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5767)
at android.app.ActivityThread.-wrap1(Unknown Source:0)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1680)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6523)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:857)
Caused by: dkp: libelements.so
at dks.c(PG:52)
at dkq.a(PG:6)
at duv.a(Unknown Source:8)
at avlz.f(PG:8)
at avlz.e(PG:5)
at avlz.a(PG:1)
at wqq.a(PG:1)
at aewt.(PG:1)
… 21 more

I have seen the video demostration of the crash and it looks completely normal until it blows up with this error.

Any suggestions?

This looks like an issue with YouTube and Firebase, am I wrong?