Skip to content
This repository has been archived by the owner on Jul 23, 2022. It is now read-only.

Runtime Exception #73

Open
ytheekshana opened this issue Jun 13, 2019 · 6 comments
Open

Runtime Exception #73

ytheekshana opened this issue Jun 13, 2019 · 6 comments

Comments

@ytheekshana
Copy link

Got this today.
image

Fatal Exception: java.lang.RuntimeException: Failure delivering result ResultInfo{who=@android:requestPermissions:, request=782, result=0, data=null} to activity {com.ytheekshana.deviceinfo/com.obsez.android.lib.filechooser.permissions.PermissionActivity}: java.lang.RuntimeException: there are no permissions
at android.app.ActivityThread.deliverResults(ActivityThread.java:5002)
at android.app.ActivityThread.handleSendResult(ActivityThread.java:5044)
at android.app.servertransaction.ActivityResultItem.execute(ActivityResultItem.java:49)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2155)
at android.os.Handler.dispatchMessage(Handler.java:109)
at android.os.Looper.loop(Looper.java:207)
at android.app.ActivityThread.main(ActivityThread.java:7539)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:958)

Caused by java.lang.RuntimeException: there are no permissions
at com.obsez.android.lib.filechooser.permissions.PermissionActivity.onRequestPermissionsResult(PermissionActivity.java:73)
at android.app.Activity.dispatchRequestPermissionsResult(Activity.java:7934)
at android.app.Activity.dispatchActivityResult(Activity.java:7784)
at android.app.ActivityThread.deliverResults(ActivityThread.java:4995)
at android.app.ActivityThread.handleSendResult(ActivityThread.java:5044)
at android.app.servertransaction.ActivityResultItem.execute(ActivityResultItem.java:49)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2155)
at android.os.Handler.dispatchMessage(Handler.java:109)
at android.os.Looper.loop(Looper.java:207)
at android.app.ActivityThread.main(ActivityThread.java:7539)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:958)

@hedzr
Copy link
Owner

hedzr commented Jun 14, 2019

version 9? it should be lower than minSDK.

@hedzr
Copy link
Owner

hedzr commented Jun 14, 2019

or android 9 P?, cc @Guiorgy

@ytheekshana
Copy link
Author

Its android 9 Pie

@joielechong
Copy link
Contributor

Android permission is really a delicate problem... There is no single solution for the problem because some manufactures change the permission with their own implementation (especially Chinese device Manufactures like Xiaomi, Huawei, Vivo, Oppo, etc). There is no easy way out.. :/

I think the android-file-chooser should not handle the permission and let the user to use their own Permission handling, either using their own code or using permission library. How do you thing @hedzr ?

@ytheekshana
Copy link
Author

Android permission is really a delicate problem... There is no single solution for the problem because some manufactures change the permission with their own implementation (especially Chinese device Manufactures like Xiaomi, Huawei, Vivo, Oppo, etc). There is no easy way out.. :/

I think the android-file-chooser should not handle the permission and let the user to use their own Permission handling, either using their own code or using permission library. How do you thing @hedzr ?

I'd like that

@hedzr
Copy link
Owner

hedzr commented Jun 14, 2019

You could handle its whatever you need at first.
If u do sth like that, afc's checkPermissions can ignore internal logic. but if u have no any idea to do or just forget permissions' check, the internal check and launcher can defend its.
I feel same with you about those devices. maybe, you have to grant some perms before ChooserDialoog.show().
IMHO, all permissions should be grouped by its types and priorities, and some of them should be requested to end-user at first running. If so, afc's inner codes about permissions will not puzzle u.

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

No branches or pull requests

3 participants