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
image_picker Bitmap NullPointException on Android 10 with open failed: EACCES (Permission denied) #41459
Comments
Supplementary log
|
Did you add the necessary permissions in your android project? |
Does the exception happen when you tap on an image or even before? |
Not sure if I understand it correctly does it Work on the Pixel or doesn't it work on any phone? |
There is only an exception here, I think it may be because of the system, because the miui of the xiaomi released a new version these two days. |
|
I am normal on the lower version of xiaomi's miui system, I am confused. |
It does work on the Google Pixel? |
Yes, my phone is google pixel 3 xl, it works fine |
Which Android version runs on the Xiomi? |
Android 10 and MIUI system 11 |
Now I can't choose on my pixel 3 xl. |
Pixel 3 XL
|
|
That is really strange. Before you could select on the Pixel? |
I am pretty sure that the file exists. |
I tried another xiaomi, Android version 7.1.1. He is normal. I am surprised that it was OK yesterday. I will not be able to uninstall and reinstall today. |
I think you use it the wrong way. pickImage returns a File you have to use this File to load the image because Android makes a copy for you that is later removed. |
The problem now is that I have crashed without getting the image program. |
Did you get another error? |
On this issue, the file crashes when it is selected. The reason is open failed: EACCES (Permission denied), but it is normal on the xiaomi phone that also requires the runtime permissions of 7.1.1, which is not normal on xiaomi 9 android 10. But yesterday I was normal on the pixel 3 xl of android 10, but today it is not working. |
Happening the same when selecting a recent image using Pixel 4. Adding the |
emulator, Pixel C API 29 |
Un-assign myself from this issue as I don't have cycle to actively working on it. |
I'm using Pixel3 and @DevAlpesh fix solved the issue. |
Ping... Is there any progress on this issue? The workaround here to add requestLegacyExternalStorage doesn't work in Android 11: It blocks our targeting to Android 11. |
opened a WIP PR to fix this flutter/plugins#2728 |
Should be fixed by flutter/plugins#2728 in image_picker 0.6.6+1 |
This works perfectly |
Hi team, using Android API level 29 (Android10). Got this problem: After the permission has been granted (following request runtime permission), still got Is adding |
[WORKED FOR ME]
|
This thread just saved my life. flutter 1.22.1, image_picker 0.6.3+1 |
Updating the image_picker version solved my issue |
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of |
When I made a picture selection on Xiaomi Mi 9, I got an error. I debugged it and found that getting the bitmap failed. I got it on another phone Pixel 3 XL.
BitmapFactory show message : EACCES (Permission denied)
However, the display details have been granted in the app details interface.
Logs
flutter doctor -v
The text was updated successfully, but these errors were encountered: