You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "mejainankit (via GitHub)" <gi...@apache.org> on 2024/02/27 11:08:51 UTC

[PR] Fix: Duplicate Permission Error For WRITE_EXTERNAL_STORAGE [cordova-plugin-camera]

mejainankit opened a new pull request, #881:
URL: https://github.com/apache/cordova-plugin-camera/pull/881

   <!--
   Please make sure the checklist boxes are all checked before submitting the PR. The checklist is intended as a quick reference, for complete details please see our Contributor Guidelines:
   
   http://cordova.apache.org/contribute/contribute_guidelines.html
   
   Thanks!
   -->
   
   ### Platforms affected
   Android
   
   
   ### Motivation and Context
   <!-- Why is this change required? What problem does it solve? -->
   <!-- If it fixes an open issue, please link to the issue here. -->
   Fix For Duplicate Permission Error For WRITE_EXTERNAL_STORAGE
   
   
   ### Description
   <!-- Describe your changes in detail -->
   Due to minSDK check, this was creating multiple permission in Android manifest file.
   If you are using any other plugin, which also requires the WRITE_EXTERNAL_STORAGE
   
   Element uses-permission#android.permission.WRITE_EXTERNAL_STORAGE at AndroidManifest.xml:20:5-108 duplicated with element declared at AndroidManifest.xml:13:5-81
   
   ### Testing
   <!-- Please describe in detail how you tested your changes. -->
   Tested with android build process
   
   ### Checklist
   
   - [X] I've run the tests to see all new and existing tests pass
   - [X] I added automated test coverage as appropriate for this change
   - [X] Commit is prefixed with `(platform)` if this change only applies to one platform (e.g. `(android)`)
   - [X] If this Pull Request resolves an issue, I linked to the issue in the text above (and used the correct [keyword to close issues using keywords](https://help.github.com/articles/closing-issues-using-keywords/))
   - [X] I've updated the documentation if necessary
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


Re: [PR] Fix: Duplicate Permission Error For WRITE_EXTERNAL_STORAGE [cordova-plugin-camera]

Posted by "breautek (via GitHub)" <gi...@apache.org>.
breautek commented on PR #881:
URL: https://github.com/apache/cordova-plugin-camera/pull/881#issuecomment-1966545287

   This isn't fixing the issue, you're just shifting it.
   
   The conflict will always occur if you have 2 or more plugins declaring the same permission with a different configuration. This includes if this plugin declared with no min sdk but another plugin did, and that's completely outside of Cordova's control.
   
   The original discussion on this subject was done inside https://github.com/apache/cordova-plugin-camera/pull/814 (the PR was rebased and merged via https://github.com/apache/cordova-plugin-camera/pull/844)
   
   But to summarise why we choose max sdk 32 because even though WRITE didn't grant any explicit permissions over READ since API 28 with the introduction of scoped storage, requesting WRITE did grant READ access until API 33 which introduces the 3 newer permissions for reading. Additionally it's recommended by Android Studio lint tool to specify max SDK 32 and google has recently announced it will start cracking down on applications declaring permissions that isn't actually being used.
   
   ![Screenshot from 2024-02-27 09-22-46](https://github.com/apache/cordova-plugin-camera/assets/11200662/ef8db0f8-0d57-446a-a7bc-d60f555de82c)
   
   For those reasons I'm closing this PR. I'll link to how this issue can be work-around in https://github.com/apache/cordova-plugin-camera/issues/882


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


Re: [PR] Fix: Duplicate Permission Error For WRITE_EXTERNAL_STORAGE [cordova-plugin-camera]

Posted by "mejainankit (via GitHub)" <gi...@apache.org>.
mejainankit commented on PR #881:
URL: https://github.com/apache/cordova-plugin-camera/pull/881#issuecomment-1968292631

   @breautek Thanks for the update


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


Re: [PR] Fix: Duplicate Permission Error For WRITE_EXTERNAL_STORAGE [cordova-plugin-camera]

Posted by "breautek (via GitHub)" <gi...@apache.org>.
breautek closed pull request #881: Fix: Duplicate Permission Error For WRITE_EXTERNAL_STORAGE
URL: https://github.com/apache/cordova-plugin-camera/pull/881


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org