sosauce / CuteMusic

CuteMusic is a simple,lightweight and open-source offline music player app for Android.
GNU General Public License v3.0
161 stars 14 forks source link

Crash on startup Android 11 #1

Closed jvde08 closed 5 months ago

jvde08 commented 5 months ago

Fresh install of beta 1, when opened up it immediately crashes and closes(Android error: CuteMusic has stopped). I tried to open it again a few times but crashes immediately everytime(even after force stop). Briefly shows screen with my songs when I tried reopening it again. The first time opening it still requested for files and media permission despite crashing.

Device information: OnePlus 9 Pro OxygenOS 11

Shocoo commented 5 months ago

Hello, I'm having the same crash issue with both apks. I'll share you the crash logs:

1rst version:

FATAL EXCEPTION: main Process: com.sosauce.cutemusic, PID: 14356 java.lang.RuntimeException: setDataSource failed: status = 0xFFFFFFEA at android.media.MediaMetadataRetriever._setDataSource(Native Method) at android.media.MediaMetadataRetriever.setDataSource(MediaMetadataRetriever.java:310) at android.media.MediaMetadataRetriever.setDataSource(MediaMetadataRetriever.java:334) at android.media.MediaMetadataRetriever.setDataSource(MediaMetadataRetriever.java:383) at W2.d.s(SourceFile:15) at i3.a.o(SourceFile:9) at y3.F.run(SourceFile:97) at android.support.v4.media.g.run(SourceFile:14) at E3.i.run(SourceFile:3) at E3.a.run(SourceFile:92) Suppressed: D3.f: [s0.F0@f0117e4, K.g@716d44d, p0{Cancelling}@9f60b02, e0@aa97c13]

2nd version (the one you provided):

FATAL EXCEPTION: main Process: com.sosauce.cutemusic, PID: 14870 androidx.datastore.preferences.protobuf.k0: lateinit property player has not been initialized at U2.d.u(SourceFile:179) at h3.a.n(SourceFile:9) at w3.F.run(SourceFile:97) at android.os.Handler.handleCallback(Handler.java:942) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loopOnce(Looper.java:201) at android.os.Looper.loop(Looper.java:288) at android.app.ActivityThread.main(ActivityThread.java:7959) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:942) Suppressed: B3.f: [p0{Cancelling}@ed95dfd, Dispatchers.Main.immediate]

sosauce commented 5 months ago

I think were that's from, im not home right now so I'll try not to forget

sosauce commented 5 months ago

Also, looking at the error of 2nd APK, DO NOT USE THE 2ND APK (I deleted it anymays) I wrapped the player initialization in a function but forgot to call this function 😥💀

PMARZV commented 5 months ago

still crashing

sosauce commented 5 months ago

still crashing

Yeah I know, should release version 1 later today or tomorrow. At latest wednwsday

PMARZV commented 5 months ago

I think calling setdatasource for retrieving artwork is the main problem. btw can we open pull request to improve the code? (Putting the player in a separate class and not in the viewmodel?)

sosauce commented 5 months ago

Sure! But wait that I release veraion 1, as I made lots of code improvement and fixed the crash

sosauce commented 5 months ago

BTW, the crash occured because you prolly have a corrupted audio file. Make sure to mayeb delete it cuz it could cause problem in other apps (if they dont handle it well) 😄

sosauce commented 5 months ago

Y'all, version 1.0.0 is available, can y'all confirm your not crashing anymore ? Thanks !

PMARZV commented 5 months ago

not crashing, i like the style!

sosauce commented 5 months ago

Cool ! Glad to here that ! Trying to detach from the typical music player look 😁

nubesurrealista commented 5 months ago

I had this bug also in the beta, Android 8.1, but now that I'm using the stable version it's all fixed and working properly. Great job! I want to see how this cute app evolves

sosauce commented 5 months ago

Ahah thanks @dskzero22 ! Wish I didn't have school so I could focus on it, but it is what it is 😢

Shocoo commented 5 months ago

Y'all, version 1.0.0 is available, can y'all confirm your not crashing anymore ? Thanks !

Working perfectly !