-
Notifications
You must be signed in to change notification settings - Fork 505
[Bug] Still unable to use MediaPicker ImageCapture on Android without declaring WRITE_EXTERNAL_STORAGE permissions in manifest #2037
Comments
Looks like could be sorted at same time #2041 |
Can you please mention the steps of compiling and adding the modified project. |
I created a fork which can be found here - though it might be out of date now https://github.com/plebnz/Essentials You can either clone the latest offical or use mine. If you use the official solution, and it has not yet been fixed, you'll need to delete or remove the line as mentioned in the issue description. The fork already has this done.
Boom, you should now be up and running. |
Adds Granular media permissions for Android 13+ https://developer.android.com/about/versions/13/behavior-changes-13#granular-media-permissions
hi @jamesmontemagno @jfversluis I think this bug is due to the CapturePhotoAsync method still having Storage write permission checking please help us to fix this |
hi Gerald
Thanks a lot for this fix
Regards
Samir
…On Thu, Jan 26, 2023 at 4:50 PM Gerald Versluis ***@***.***> wrote:
Closed #2037 <#2037> as
completed via #2073 <#2073>.
—
Reply to this email directly, view it on GitHub
<#2037 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AE2XOSBQRUXRZ5XEZDTJYS3WUI3FDANCNFSM57BQW72Q>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
When will this fix be available via the nuget packages? |
@jamesmontemagno it is getting crashing on Android 13 Please suggest any work around its very crucial |
Description
Found in Xamarin Essentials 1.7.3 on Android 11 targeting SDK v31
MediaPicker Image Capture still requires WRITE_EXTERNAL_STORAGE in the manifest otherwise i get a "You need to declare using the permission:
android.permission.WRITE_EXTERNAL_STORAGE
in your AndroidManifest.xml"All I want is to capture an image and post it to a server without writing to external storage - Why cant we have the option to write/cache to directories that do not require this permission?
Update: For now I have forked this project and deleted line 59 from the MediaPicker.android file in the project.
await Permissions.EnsureGrantedAsync<Permissions.StorageWrite>(); <-- Deleted
I have compiled the forked project and added it to my application and I can now take pictures and post to server using app cache and no reqauirement to add WRITE_EXTERNAL_STORAGE to manifest.
I feel that i missing something here, some questions I have
I dont think the docs are very clear around how this should be handling it and I'm pretty sure I have misunderstood something and I'm just not using the official package correctly in my application correctly so happy to be corrected and delete this bug report as required.
The text was updated successfully, but these errors were encountered: