toasterofbread / spmp

A YouTube Music client with a focus on customisation of colours and song metadata. Built with Compose Multiplatform for Android and desktop.
GNU General Public License v3.0
1.17k stars 44 forks source link

SpMp crashed at the first open, maybe from the system language #70

Closed frknkrc44 closed 1 year ago

frknkrc44 commented 1 year ago

App Version: 0.1.2 Android Version: 13 QPR2 (SDK 33) - LineageOS 20 Device: Oneplus 9 System Language: Turkish (Turkey)

Logs are here:

kotlin.NotImplementedError: tr
    at com.toasterofbread.spmp.resources.uilocalisation.AmountStringsKt.parseYoutubeSubscribersString(Unknown Source:95)
    at com.toasterofbread.spmp.api.LoadMediaitemKt$processDefaultResponse$2.invokeSuspend(Unknown Source:929)
    at com.toasterofbread.spmp.api.LoadMediaitemKt$processDefaultResponse$2.invoke(Unknown Source:8)
    at com.toasterofbread.spmp.api.LoadMediaitemKt$processDefaultResponse$2.invoke(Unknown Source:4)
    at androidx.core.R$dimen.startUndispatchedOrReturn(Unknown Source:4)
    at coil.util.-Contexts.withContext(Unknown Source:71)
    at com.toasterofbread.spmp.api.LoadMediaitemKt.processDefaultResponse(Unknown Source:13)
    at com.toasterofbread.spmp.api.LoadMediaitemKt$loadMediaItemData$2.invokeSuspend(Unknown Source:241)
    at com.toasterofbread.spmp.api.LoadMediaitemKt$loadMediaItemData$2.invoke(Unknown Source:8)
    at com.toasterofbread.spmp.api.LoadMediaitemKt$loadMediaItemData$2.invoke(Unknown Source:4)
    at androidx.core.R$dimen.startUndispatchedOrReturn(Unknown Source:4)
    at coil.util.-Contexts.withContext(Unknown Source:71)
    at com.toasterofbread.spmp.api.LoadMediaitemKt.loadMediaItemData(Unknown Source:76)
    at com.toasterofbread.spmp.model.mediaitem.MediaItem$loadGeneralData$2.invokeSuspend(Unknown Source:121)
    at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(Unknown Source:8)
    at kotlinx.coroutines.DispatchedTask.run(Unknown Source:100)
    at kotlinx.coroutines.internal.LimitedDispatcher.run(Unknown Source:12)
    at kotlinx.coroutines.scheduling.TaskImpl.run(Unknown Source:2)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(Unknown Source:79)
    Suppressed: coil.network.HttpException: [androidx.compose.ui.platform.MotionDurationScaleImpl@afa453a, androidx.compose.runtime.BroadcastFrameClock@28355eb, StandaloneCoroutine{Cancelling}@4db5f48, AndroidUiDispatcher@21fb1e1]
toasterofbread commented 1 year ago

Thanks for the report. I haven't implemented Turkish localisations, but I've replaced some exception throws (including the one that caused this) with error logs. Some information might be missing from the app like artist subscriber counts, but otherwise it should work fine now.