FossifyOrg / Messages

An easy and quick way of managing SMS and MMS messages without ads.
https://www.fossify.org
GNU General Public License v3.0
419 stars 30 forks source link

Exporting Messages causes crash #6

Open biopsin opened 6 months ago

biopsin commented 6 months ago

Checklist

Describe the bug Exporting messages generates file with 0kb and application force close/crash

To Reproduce Open SMS-Messanger and goto settings -> export messages -> select SMS & MMS -> export to any sdcard location

Expected behavior Export succseeds

Device info (please complete the following information):

Additional context Reported at https://github.com/SimpleMobileTools/Simple-SMS-Messenger/issues/806

catlog 2-17 11:23:17.983 27980 27980 D PickerActionHandler: onFinished( [content://com.android.externalstorage.documents/document/7489-9A91%3ABackup%2FSettings%2FSimpleMobileTools%2FMessages_2023_12_17_11_23_15.json] 12-17 11:23:18.008 30867 30867 D CompatibilityChangeReporter: Compat change id reported: 147798919; UID 10194; state: ENABLED 12-17 11:23:18.015 30867 30867 D skia : --- Failed to create image decoder with message 'unimplemented' 12-17 11:23:18.045 1896 1916 W System : A resource failed to call release. 12-17 11:23:18.066 951 951 I QTI PowerHAL: Power setBoost: 0, duration: 0 12-17 11:23:18.066 951 951 I QTI PowerHAL: Power setBoost: 0, duration: 0 12-17 11:23:18.078 27980 27980 D AbstractActionHandler: Loader has finished for: content://com.android.externalstorage.documents/document/7489-9A91%3ABackup%2FSettings%2FSimpleMobileTools 12-17 11:23:18.078 27980 27980 I Model : Updating model with new result set. 12-17 11:23:18.078 27980 27980 D DirectoryFragment: Received model update. Loading=false 12-17 11:23:18.349 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:18.385 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:18.407 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:11.523 0 0 I pm8150b_charger: somc_aicl_irq_handler: IRQ: aicl-done 12-17 11:23:11.528 0 0 I FG : fg_gen4_cl_ok_to_begin: IBAT_FLT thr: 100 val: -13 but ignore this function 12-17 11:23:11.528 0 0 I ALG : cap_learning_update: [SOMC CL][OFF] charge_status:1 bsoc_cp:7271 12-17 11:23:18.444 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:11.540 0 0 W healthd : battery l=76 v=4046 t=24.7 h=2 st=2 c=12207 fc=3464000 cc=6 chg=u 12-17 11:23:18.455 959 959 D illumination-service: 'battery': Color ffffff00, BrMode 0, OnMS 0, OffMS 0, Mode 0 12-17 11:23:11.546 0 0 E leds rgb: rgbcommon_sync_state_store do nothing. same state 12-17 11:23:18.465 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.483 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.514 30867 31904 E CursorWindow: Failed to read row 3, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.532 30867 31857 W System : A resource failed to call release. 12-17 11:23:18.535 30867 31904 E CursorWindow: Failed to read row 4, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.551 30867 31904 E CursorWindow: Failed to read row 5, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.571 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.586 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.602 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.619 30867 31904 E CursorWindow: Failed to read row 3, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.637 30867 31904 E CursorWindow: Failed to read row 4, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.652 30867 31904 E CursorWindow: Failed to read row 5, column -1 from a CursorWindow which has 6 rows, 17 columns. 12-17 11:23:18.676 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:18.698 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.727 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.752 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.773 30867 31904 E CursorWindow: Failed to read row 3, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.802 30867 31904 E CursorWindow: Failed to read row 4, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.843 30867 31904 E CursorWindow: Failed to read row 5, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.857 30867 31904 E CursorWindow: Failed to read row 6, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.872 30867 31904 E CursorWindow: Failed to read row 7, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.886 30867 31904 E CursorWindow: Failed to read row 8, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.903 30867 31904 E CursorWindow: Failed to read row 9, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.931 30867 31904 E CursorWindow: Failed to read row 10, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.949 30867 31904 E CursorWindow: Failed to read row 11, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.966 30867 31904 E CursorWindow: Failed to read row 12, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:18.984 30867 31904 E CursorWindow: Failed to read row 13, column -1 from a CursorWindow which has 14 rows, 17 columns. 12-17 11:23:19.023 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:19.048 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 4 rows, 17 columns. 12-17 11:23:19.063 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 4 rows, 17 columns. 12-17 11:23:19.077 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 4 rows, 17 columns. 12-17 11:23:19.092 30867 31904 E CursorWindow: Failed to read row 3, column -1 from a CursorWindow which has 4 rows, 17 columns. 12-17 11:23:19.114 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:19.132 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:19.154 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 3 rows, 17 columns. 12-17 11:23:19.168 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 3 rows, 17 columns. 12-17 11:23:19.189 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 3 rows, 17 columns. 12-17 11:23:19.214 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 3 rows, 17 columns. 12-17 11:23:19.232 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 3 rows, 17 columns. 12-17 11:23:19.247 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 3 rows, 17 columns. 12-17 11:23:19.272 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:19.301 30867 31904 I chatty : uid=10194(com.simplemobiletools.smsmessenger) Thread-18 identical 1 line 12-17 11:23:19.333 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:19.369 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:19.384 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:19.415 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:19.436 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:19.454 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 7 rows, 17 columns. 12-17 11:23:19.477 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 7 rows, 17 columns. 12-17 11:23:19.497 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 7 rows, 17 columns. 12-17 11:23:19.515 30867 31904 E CursorWindow: Failed to read row 3, column -1 from a CursorWindow which has 7 rows, 17 columns. 12-17 11:23:19.536 30867 31904 E CursorWindow: Failed to read row 4, column -1 from a CursorWindow which has 7 rows, 17 columns. 12-17 11:23:19.554 30867 31904 E CursorWindow: Failed to read row 5, column -1 from a CursorWindow which has 7 rows, 17 columns. 12-17 11:23:19.572 30867 31904 E CursorWindow: Failed to read row 6, column -1 from a CursorWindow which has 7 rows, 17 columns. 12-17 11:23:19.614 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 4 rows, 17 columns. 12-17 11:23:19.632 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 4 rows, 17 columns. 12-17 11:23:19.657 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 4 rows, 17 columns. 12-17 11:23:19.679 30867 31904 E CursorWindow: Failed to read row 3, column -1 from a CursorWindow which has 4 rows, 17 columns. 12-17 11:23:19.715 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:19.744 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:19.766 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:19.783 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:19.818 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:19.859 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:19.873 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:19.892 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:19.910 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:19.930 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:19.947 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:19.976 30867 31904 E CursorWindow: Failed to read row 3, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:20.002 30867 31904 E CursorWindow: Failed to read row 4, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:20.028 1507 1824 W NotificationService: Toast already killed. pkg=com.simplemobiletools.smsmessenger token=android.os.BinderProxy@9335011 12-17 11:23:13.122 0 0 I qcom_rpmh DRV: apps_rsc TCS Busy, retrying RPMH message send: addr=0x30080 12-17 11:23:20.034 951 951 I QTI PowerHAL: Power setBoost: 0, duration: 0 12-17 11:23:20.052 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:20.068 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:20.070 1507 1520 W System : A resource failed to call release. 12-17 11:23:13.170 0 0 I IRQ 5 : no longer affine to CPU7 12-17 11:23:20.071 1507 1520 I chatty : uid=1000(system) FinalizerDaemon identical 5 lines 12-17 11:23:20.072 1507 1520 W System : A resource failed to call release. 12-17 11:23:20.092 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:20.113 30867 31904 I chatty : uid=10194(com.simplemobiletools.smsmessenger) Thread-18 identical 1 line 12-17 11:23:20.132 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:20.149 951 951 I QTI PowerHAL: Power setBoost: 0, duration: 0 12-17 11:23:20.161 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:20.186 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:20.206 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 2 rows, 17 columns. 12-17 11:23:20.236 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:20.260 30867 31904 E CursorWindow: Failed to read row 1, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:20.282 30867 31904 E CursorWindow: Failed to read row 2, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:20.297 30867 31904 E CursorWindow: Failed to read row 3, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:20.312 30867 31904 E CursorWindow: Failed to read row 4, column -1 from a CursorWindow which has 5 rows, 17 columns. 12-17 11:23:20.341 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:20.385 30867 31904 E CursorWindow: Failed to read row 0, column -1 from a CursorWindow which has 1 rows, 17 columns. 12-17 11:23:20.757 30867 31904 I ls.smsmessenge: Starting a blocking GC Alloc 12-17 11:23:20.757 30867 31904 I ls.smsmessenge: Starting a blocking GC Alloc 12-17 11:23:20.766 30867 31904 I ls.smsmessenge: Alloc young concurrent copying GC freed 2112(79KB) AllocSpace objects, 0(0B) LOS objects, 17% free, 116MB/140MB, paused 30us total 8.613ms 12-17 11:23:20.766 30867 31904 I ls.smsmessenge: Starting a blocking GC Alloc 12-17 11:23:20.788 30867 31904 I ls.smsmessenge: Alloc concurrent copying GC freed 7(16KB) AllocSpace objects, 1(26MB) LOS objects, 21% free, 89MB/113MB, paused 26us total 21.693ms 12-17 11:23:20.788 30867 31904 I ls.smsmessenge: Forcing collection of SoftReferences for 104MB allocation 12-17 11:23:20.788 30867 31904 I ls.smsmessenge: Starting a blocking GC Alloc 12-17 11:23:20.802 30867 31904 I ls.smsmessenge: Alloc concurrent copying GC freed 5480(203KB) AllocSpace objects, 0(0B) LOS objects, 21% free, 89MB/113MB, paused 28us total 13.666ms 12-17 11:23:20.802 30867 31904 W ls.smsmessenge: Throwing OutOfMemoryError "Failed to allocate a 109453288 byte allocation with 25165824 free bytes and 102MB until OOM, target footprint 119157176, growth limit 201326592" (VmSize 14045404 kB) 12-17 11:23:20.802 30867 31904 I ls.smsmessenge: Starting a blocking GC Alloc 12-17 11:23:20.802 30867 31904 I ls.smsmessenge: Starting a blocking GC Alloc 12-17 11:23:20.809 30867 31904 I ls.smsmessenge: Alloc young concurrent copying GC freed 4(31KB) AllocSpace objects, 0(0B) LOS objects, 21% free, 89MB/113MB, paused 25us total 7.326ms 12-17 11:23:20.809 30867 31904 I ls.smsmessenge: Starting a blocking GC Alloc 12-17 11:23:20.827 30867 31904 I ls.smsmessenge: Alloc concurrent copying GC freed 4(16KB) AllocSpace objects, 0(0B) LOS objects, 21% free, 89MB/113MB, paused 26us total 17.139ms 12-17 11:23:20.827 30867 31904 I ls.smsmessenge: Forcing collection of SoftReferences for 104MB allocation 12-17 11:23:20.827 30867 31904 I ls.smsmessenge: Starting a blocking GC Alloc 12-17 11:23:20.840 30867 31904 I ls.smsmessenge: Alloc concurrent copying GC freed 5(16KB) AllocSpace objects, 0(0B) LOS objects, 21% free, 89MB/113MB, paused 26us total 13.044ms 12-17 11:23:20.840 30867 31904 W ls.smsmessenge: Throwing OutOfMemoryError "Failed to allocate a 109453288 byte allocation with 25165824 free bytes and 102MB until OOM, target footprint 119157176, growth limit 201326592" (VmSize 14045404 kB) --------- beginning of crash 12-17 11:23:20.841 30867 31904 E AndroidRuntime: FATAL EXCEPTION: Thread-18 12-17 11:23:20.841 30867 31904 E AndroidRuntime: Process: com.simplemobiletools.smsmessenger, PID: 30867 12-17 11:23:20.841 30867 31904 E AndroidRuntime: java.lang.OutOfMemoryError: Failed to allocate a 109453288 byte allocation with 25165824 free bytes and 102MB until OOM, target footprint 119157176, growth limit 201326592 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at java.util.Arrays.copyOf(Arrays.java:3257) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kb.m.a(SourceFile:12) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kb.f.i(SourceFile:19) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kb.v.t(SourceFile:8) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at ib.b1.a(SourceFile:13) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kb.v.n(SourceFile:106) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.bumptech.glide.d.p(SourceFile:34) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kb.v.p(SourceFile:19) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at d9.u.g(SourceFile:79) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at d9.s.a(SourceFile:19) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kb.v.n(SourceFile:106) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.bumptech.glide.d.b0(SourceFile:14) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at ib.o.a(SourceFile:45) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kb.v.n(SourceFile:106) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.bumptech.glide.d.b0(SourceFile:14) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at d9.r.h(SourceFile:134) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at d9.p.a(SourceFile:19) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at jb.j.a(SourceFile:687) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kb.v.n(SourceFile:106) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.bumptech.glide.d.b0(SourceFile:14) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at ib.o.a(SourceFile:45) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kb.v.n(SourceFile:106) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.bumptech.glide.c.n0(SourceFile:32) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at e8.k0.E(SourceFile:396) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at j.a.d(SourceFile:339) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at n8.o.b(SourceFile:1443) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at n8.o.f(SourceFile:229) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at p1.v.run(SourceFile:20) 12-17 11:23:20.841 30867 31904 E AndroidRuntime: at java.lang.Thread.run(Thread.java:923) 12-17 11:23:20.842 1507 7831 W ActivityTaskManager: Force finishing activity com.simplemobiletools.smsmessenger/.activities.SettingsActivity 12-17 11:23:20.842 1507 31911 I DropBoxManagerService: add tag=data_app_crash isTagEnabled=true flags=0x2 12-17 11:23:20.861 30867 31904 I Process : Sending signal. PID: 30867 SIG: 9 12-17 11:23:13.980 0 0 I binder : undelivered TRANSACTION_COMPLETE 12-17 11:23:13.980 0 0 I binder : undelivered transaction 118411719, process died. 12-17 11:23:20.891 1507 27195 I WindowManager: WIN DEATH: Window{1b89499 u0 com.simplemobiletools.smsmessenger/com.simplemobiletools.smsmessenger.activities.MainActivity} 12-17 11:23:20.891 1507 27195 W InputDispatcher: Attempted to unregister already unregistered input channel '1b89499 com.simplemobiletools.smsmessenger/com.simplemobiletools.smsmessenger.activities.MainActivity (server)' 12-17 11:23:20.891 793 793 I Zygote : Process 30867 exited due to signal 9 (Killed) 12-17 11:23:20.892 1507 2674 I ActivityManager: Process com.simplemobiletools.smsmessenger (pid 30867) has died: fg TOP 12-17 11:23:20.893 1507 1556 I libprocessgroup: Successfully killed process cgroup uid 10194 pid 30867 in 0ms 12-17 11:23:20.895 1507 7275 W WindowManager: Cannot find window which accessibility connection is added to 12-17 11:23:20.895 1507 2017 I WindowManager: WIN DEATH: Window{4bf4f3e u0 com.simplemobiletools.smsmessenger/com.simplemobiletools.smsmessenger.activities.SettingsActivity} 12-17 11:23:20.895 1507 2017 W InputDispatcher: Attempted to unregister already unregistered input channel '4bf4f3e com.simplemobiletools.smsmessenger/com.simplemobiletools.smsmessenger.activities.SettingsActivity (server)' 12-17 11:23:20.902 1507 26240 W WindowManager: Cannot find window which accessibility connection is added to 12-17 11:23:20.908 1507 1547 W ActivityManager: setHasOverlayUi called on unknown pid: 30867 12-17 11:23:20.909 1507 1547 D CompatibilityChangeReporter: Compat change id reported: 135634846; UID 10194; state: DISABLED 12-17 11:23:20.909 1507 1547 D CompatibilityChangeReporter: Compat change id reported: 135754954; UID 10194; state: ENABLED 12-17 11:23:20.910 1507 1555 D CompatibilityChangeReporter: Compat change id reported: 143937733; UID 10194; state: ENABLED 12-17 11:23:20.916 1507 1555 I ActivityManager: Start proc 30868:com.simplemobiletools.smsmessenger/u0a194 for top-activity {com.simplemobiletools.smsmessenger/com.simplemobiletools.smsmessenger.activities.MainActivity} 12-17 11:23:20.917 5160 5164 I adbd : jdwp connection from 30868 12-17 11:23:20.927 30868 30868 I ls.smsmessenge: The ClassLoaderContext is a special shared library. 12-17 11:23:20.936 30868 30868 W ls.smsmessenge: JIT profile information will not be recorded: profile file does not exist. 12-17 11:23:20.941 30868 30868 D NetworkSecurityConfig: No Network Security Config specified, using platform default 12-17 11:23:20.941 30868 30868 D NetworkSecurityConfig: No Network Security Config specified, using platform default 12-17 11:23:20.949 1022 1575 W DisplayIdentification: Invalid EDID: ASCII text is not printable. 12-17 11:23:20.949 1022 1575 W DisplayIdentification: Invalid EDID: falling back to serial number due to missing display name. 12-17 11:23:20.949 1022 1575 W DisplayIdentification: Invalid EDID: falling back to ASCII text due to missing serial number. 12-17 11:23:20.950 1022 1575 E DisplayIdentification: Invalid EDID: display name and fallback descriptors are missing. 12-17 11:23:20.954 30868 30868 D AppCompatDelegate: Checking for metadata for AppLocalesMetadataHolderService : Service not found 12-17 11:23:20.991 30868 30868 D skia : --- Failed to create image decoder with message 'unimplemented' 12-17 11:23:21.009 30868 31930 I AdrenoGLES-0: QUALCOMM build : 191610ae03, Ic907de5ed0 12-17 11:23:21.009 30868 31930 I AdrenoGLES-0: Build Date : 09/17/20 12-17 11:23:21.009 30868 31930 I AdrenoGLES-0: OpenGL ES Shader Compiler Version: EV031.32.02.01 12-17 11:23:21.009 30868 31930 I AdrenoGLES-0: Local Branch : 12-17 11:23:21.009 30868 31930 I AdrenoGLES-0: Remote Branch : refs/tags/AU_LINUX_ANDROID_LA.UM.9.12.10.00.00.582.274 12-17 11:23:21.009 30868 31930 I AdrenoGLES-0: Remote Branch : NONE 12-17 11:23:21.009 30868 31930 I AdrenoGLES-0: Reconstruct Branch : NOTHING 12-17 11:23:21.009 30868 31930 I AdrenoGLES-0: Build Config : S P 10.0.5 AArch64 12-17 11:23:21.009 30868 31930 I AdrenoGLES-0: Driver Path : /vendor/lib64/egl/libGLESv2_adreno.so 12-17 11:23:21.012 30868 31930 I AdrenoGLES-0: PFP: 0x016dd091, ME: 0x00000000 12-17 11:23:21.049 951 951 I QTI PowerHAL: Power setBoost: 0, duration: 0 12-17 11:23:21.113 30868 30868 W Glide : Failed to find GeneratedAppGlideModule. You should include an annotationProcessor compile dependency on com.github.bumptech.glide:compiler in your application and a @GlideModule annotated AppGlideModule implementation or LibraryGlideModules will be silently ignored 12-17 11:23:14.210 0 0 I IRQ 5 : no longer affine to CPU6 12-17 11:23:21.156 30868 30868 W Glide : Load failed for [] with dimensions [113x113] 12-17 11:23:21.156 30868 30868 W Glide : class com.bumptech.glide.load.engine.GlideException: Failed to load resource 12-17 11:23:21.524 1507 1547 W WindowManager: Unable to start animation, surface is null or no children. 12-17 11:23:21.157 30868 30868 I chatty : uid=10194(com.simplemobiletools.smsmessenger) identical 8 lines 12-17 11:23:21.157 30868 30868 W Glide : Load failed for [] with dimensions [113x113] 12-17 11:23:21.157 30868 30868 W Glide : class com.bumptech.glide.load.engine.GlideException: Failed to load resource 12-17 11:23:22.319 4119 4119 D MyReceiver: ACTION_MONITOR_BATTERY_LEVEL received. 12-17 11:23:22.320 4119 4119 D MyReceiver: min level setting=20; max level setting=80 12-17 11:23:22.320 4119 4119 D MyReceiver: current level=76 12-17 11:23:22.322 4119 4119 D Util : Trigger alarm in 5 seconds 12-17 11:23:26.781 30868 31958 D ProfileInstaller: Skipping profile installation for com.simplemobiletools.smsmessenger 12-17 11:23:27.069 959 959 D illumination-service: 'buttons': Color ff000000, BrMode 0, OnMS 0, OffMS 0, Mode 0
tom93 commented 3 months ago

Looks like it's getting OutOfMemoryError.

@biopsin Are you still interested in debugging this?

@​devs Can we get the deobfuscated stack trace? And what do you think about modifying exportMessages to serialize the JSON directly to the file instead of in-memory (i.e. Json.encodeToStream instead of json.encodeToString)? It should reduce the memory requirement by at least half, but may produce an incomplete (corrupt) file on serialization error.

naveensingh commented 3 months ago

@tom93 The stack trace is from Simple SMS Messenger:

--------- beginning of crash
12-17 11:23:20.841 30867 31904 E AndroidRuntime: FATAL EXCEPTION: Thread-18
12-17 11:23:20.841 30867 31904 E AndroidRuntime: Process: com.simplemobiletools.smsmessenger, PID: 30867
12-17 11:23:20.841 30867 31904 E AndroidRuntime: java.lang.OutOfMemoryError: Failed to allocate a 109453288 byte allocation with 25165824 free bytes and 102MB until OOM, target footprint 119157176, growth limit 201326592
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at java.util.Arrays.copyOf(Arrays.java:3257)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.JsonToStringWriter.ensureTotalCapacity(JsonToStringWriter.kt:132)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.JsonToStringWriter.ensureAdditionalCapacity(JsonToStringWriter.kt:125)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.JsonToStringWriter.writeQuoted(JsonToStringWriter.kt:51)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.Composer.printQuoted(Composers.kt:41)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.StreamingJsonEncoder.encodeString(StreamingJsonEncoder.kt:220)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.internal.StringSerializer.serialize(Primitives.kt:160)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.internal.StringSerializer.serialize(Primitives.kt:157)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.StreamingJsonEncoder.encodeSerializableValue(StreamingJsonEncoder.kt:228)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.encoding.Encoder$DefaultImpls.encodeNullableSerializableValue(Encoding.kt:299)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.encoding.AbstractEncoder.encodeNullableSerializableValue(AbstractEncoder.java:18)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.encoding.AbstractEncoder.encodeNullableSerializableElement(AbstractEncoder.java:90)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.StreamingJsonEncoder.encodeNullableSerializableElement(StreamingJsonEncoder.kt:157)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.models.MmsPart.write$Self(MmsPart.kt:9)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.models.MmsPart$$serializer.serialize(MmsPart.kt:9)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.models.MmsPart$$serializer.serialize(MmsPart.kt:9)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.StreamingJsonEncoder.encodeSerializableValue(StreamingJsonEncoder.kt:228)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.encoding.AbstractEncoder.encodeSerializableElement(AbstractEncoder.java:80)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.internal.CollectionLikeSerializer.serialize(CollectionSerializers.kt:69)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.StreamingJsonEncoder.encodeSerializableValue(StreamingJsonEncoder.kt:228)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.encoding.AbstractEncoder.encodeSerializableElement(AbstractEncoder.java:80)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.models.MmsBackup.write$Self(MmsBackup.kt:9)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.models.MmsBackup$$serializer.serialize(MmsBackup.kt:9)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.models.MmsBackup$$serializer.serialize(MmsBackup.kt:9)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.JsonContentPolymorphicSerializer.serialize(JsonContentPolymorphicSerializer.kt:85)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.StreamingJsonEncoder.encodeSerializableValue(StreamingJsonEncoder.kt:228)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.encoding.AbstractEncoder.encodeSerializableElement(AbstractEncoder.java:80)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.internal.CollectionLikeSerializer.serialize(CollectionSerializers.kt:69)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.StreamingJsonEncoder.encodeSerializableValue(StreamingJsonEncoder.kt:228)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.internal.JsonStreamsKt.encodeByWriter(JsonStreams.kt:28)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at kotlinx.serialization.json.Json.encodeToString(Json.kt:81)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.activities.SettingsActivity$exportMessages$1$1.invoke(SettingsActivity.kt:421)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.activities.SettingsActivity$exportMessages$1$1.invoke(SettingsActivity.kt:124)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.helpers.MessagesReader.getMessagesToExport(MessagesReader.kt:32)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.activities.SettingsActivity$exportMessages$1.invoke(SettingsActivity.kt:124)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.smsmessenger.activities.SettingsActivity$exportMessages$1.invoke(SettingsActivity.kt:122)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at com.simplemobiletools.commons.helpers.ConstantsKt.ensureBackgroundThread$lambda$0(Constants.kt:452)
12-17 11:23:20.841 30867 31904 E AndroidRuntime: at java.lang.Thread.run(Thread.java:923)
12-17 11:23:20.842 1507 7831 W ActivityTaskManager: Force finishing activity com.simplemobiletools.smsmessenger/.activities.SettingsActivity

FYI you can deobfuscate it yourself using the following command once you have created a minified build:

/Path/To/Android/Sdk/cmdline-tools/latest/bin/retrace app/build/outputs/mapping/prepaidRelease/mapping.txt crashlog.txt

tom93 commented 3 months ago

Thanks! My hunch about encodeToString was correct. I'll write a patch.

biopsin commented 3 months ago

@tom93 shure

tom93 commented 3 months ago

I wrote a patch: #139.

@biopsin Please test it out. If you don't want to built from source / wait for a project member to build, you can use the following APK that I built myself, but note that I am not a project member so use it at your own risk (discussion): unofficial-messages-2-foss-debug-for-issue-6.apk.zip

biopsin commented 3 months ago

@tom93 Export went successfull, generated a 31.9Mb json file. Could not test manual importing since after a "clear storage" and opening Messages apk it will auto populate from backup or something.. Edit: I will test importing on my second device when I get home..

knuxyl commented 2 months ago

I can confirm this fixes the issue. Tested exporting on a Pixel 5 and importing on a Pixel 4 and all MMS and SMS were available. Generated archive was ~120MB. It's slow but it works. Please merge the patch #139

QuestioningEspecialy commented 2 months ago

(...) you can use the following APK that I built myself, but note that I am not a project member so use it at your own risk (discussion): unofficial-messages-2-foss-debug-for-issue-6.apk.zip

@Aga-C came here from #169 seeking a possible solution and~, after finding a way around setting it as the new default app just so i can open it (App info > Additional settings in the app), i got an error message when attempting to export 1) SMS & MMS messages, 2) SMS messages, and 3) MMS messages :x Error: java.lang.SecurityException: Permission Denial: reading com.androi...

Suggestion: add "fix" to the name or something so it doesn't get mistaken for the official app also, i ran the files and download link through VirusTotal:

tom93 commented 1 month ago

@QuestioningEspecialy I replied over at https://github.com/FossifyOrg/Messages/issues/169#issuecomment-2119215852. I opened a PR to set a unique app name for debug builds (#171). Re permissions, on stock Android you should get a popup asking to make it the default messaging app; the awkwardness might be a GrapheneOS thing.