Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash on app demo #20

Open
matteoKuama opened this issue Nov 10, 2022 · 2 comments
Open

Crash on app demo #20

matteoKuama opened this issue Nov 10, 2022 · 2 comments

Comments

@matteoKuama
Copy link

Hi I was looking for a package that had extactly the functionalities that yours offers but it keeps crashing even when i launch the demo app allowing all the permissions.
Here the stack trace:
FATAL EXCEPTION: main Process: com.huhx.app, PID: 17944 java.lang.NullPointerException: getString(indexDirectory) must not be null at com.huhx.picker.data.AssetLoader.load(AssetLoader.kt:105) at com.huhx.picker.data.AssetPickerRepository.getAssets(AssetPickerRepository.kt:11) at com.huhx.picker.data.AssetViewModel.initAssets(AssetViewModel.kt:44) at com.huhx.picker.data.AssetViewModel.access$initAssets(AssetViewModel.kt:14) at com.huhx.picker.data.AssetViewModel$initDirectories$1.invokeSuspend(AssetViewModel.kt:30) at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) at kotlinx.coroutines.internal.DispatchedContinuationKt.resumeCancellableWith(DispatchedContinuation.kt:367) at kotlinx.coroutines.intrinsics.CancellableKt.startCoroutineCancellable(Cancellable.kt:30) at kotlinx.coroutines.intrinsics.CancellableKt.startCoroutineCancellable$default(Cancellable.kt:25) at kotlinx.coroutines.CoroutineStart.invoke(CoroutineStart.kt:110) at kotlinx.coroutines.AbstractCoroutine.start(AbstractCoroutine.kt:126) at kotlinx.coroutines.BuildersKt__Builders_commonKt.launch(Builders.common.kt:56) at kotlinx.coroutines.BuildersKt.launch(Unknown Source:1) at kotlinx.coroutines.BuildersKt__Builders_commonKt.launch$default(Builders.common.kt:47) at kotlinx.coroutines.BuildersKt.launch$default(Unknown Source:1) at com.huhx.picker.data.AssetViewModel.initDirectories(AssetViewModel.kt:29) at com.huhx.picker.view.AssetPickerKt$AssetPicker$1.invokeSuspend(AssetPicker.kt:34) at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106) at androidx.compose.ui.platform.AndroidUiDispatcher.performTrampolineDispatch(AndroidUiDispatcher.android.kt:81) at androidx.compose.ui.platform.AndroidUiDispatcher.access$performTrampolineDispatch(AndroidUiDispatcher.android.kt:41) at androidx.compose.ui.platform.AndroidUiDispatcher$dispatchCallback$1.doFrame(AndroidUiDispatcher.android.kt:68) at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1106) at android.view.Choreographer.doCallbacks(Choreographer.java:866) at android.view.Choreographer.doFrame(Choreographer.java:792) at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1092) at android.os.Handler.handleCallback(Handler.java:938) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loopOnce(Looper.java:226) at android.os.Looper.loop(Looper.java:313) at android.app.ActivityThread.main(ActivityThread.java:8669) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:571) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1135) Suppressed: kotlinx.coroutines.DiagnosticCoroutineContextException: [StandaloneCoroutine{Cancelling}@7c01437, Dispatchers.Main.immediate]

@huhx
Copy link
Owner

huhx commented Nov 10, 2022

Thanks for your feedback, the issue maybe cause by demo refer to the old picker lib. I have already refer to the project code and upgrade the compose version and test it can work now. You can pull lasted code and try, hope it can help you.

@frhnfrq
Copy link

frhnfrq commented Feb 10, 2023

I pulled the latest code and tried, it didn't work. @huhx
@matteoKuama have you found any fix?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants