-
-
Notifications
You must be signed in to change notification settings - Fork 894
Fix issue #26 #182
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Fix issue #26 #182
Conversation
Finally a proper fix for this! Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ty0x2333 thank you very much for this PR it looks very good. Sorry for the late reply, I was on holiday during the festive season.
I do have one small remark which is related to the documentation, please have a look.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, this looks great.
@ty0x2333 I need only camera and photos permission. I added the following code in the podfile, excluded those two, cleaned and rebuilt. But once uploaded to TestFlight, I'm still getting the error. Am I missing something? PFA. |
We just (5 minutes ago) released version 4.1.0 which contains the contents of this PR. |
Thanks so much for this fix @ty0x2333! |
Hello @mvanbeusekom. I´m developin with flutter for Android and iOS, I don´t have any Podfile on my project, because I use windows. Where should I change those permission? Thank you. |
Hi @brunozanoelo, if you want to develop for iOS you will have to compile your project on a Apple machine running macOS, there is no escaping to this. So if you stick to Windows you will not be able to develop the iOS App (or at least compile it). In this case you will only be able to develop for Android and the web (and in the near future Windows and Linux Desktop). Most likely Flutter noticed you are running on Windows when you initially created your project and didn't setup the iOS part of the project (in your project root there should be an In your case there will not be an iOS App and thus no need to worry about the permission configuration yet. Once you get hold of a Apple machine with macOS and Xcode you will be able to generate the iOS part of the Flutter project and you will automatically also have a |
Hello @mvanbeusekom, Thank you for you reply. I don´t have an mac computer, so I´m building this with Codemagic, with him, I´m able to build and automatically publish into Play Store and Apple Store. However, the changes to run the app inside Podfile is very difficult for me, since I need to access the cloud machine pretty fast and change the Podfile everytime I build one version, and actually, this is not working so far. It seens, I´m the different one, but buying one macOS will be pretty expensive in my country. |
@brunozanoelo I've used MacInCloud to do iOS specific things, it's pretty cheap if you only need it for a couple of days, and first 24h were free. |
> IMPORTANT: On iOS you will have to include all permission options when you want to submit your App. This is because the `permission_handler` plugin touches all different SDKs and because the static code analyser (run by Apple upon App submission) detects this and will assert if it cannot find a matching permission option in the `Info.plist`. More information about this can be found [here](https://github.com/Baseflow/flutter-permission-handler/issues/26). Unfortunately we don't have a good solution for this. | ||
> IMPORTANT: ~~On iOS you will have to include all permission options when you want to submit your App.~~ This is because the `permission_handler` plugin touches all different SDKs and because the static code analyser (run by Apple upon App submission) detects this and will assert if it cannot find a matching permission option in the `Info.plist`. More information about this can be found [here](https://github.com/BaseflowIT/flutter-permission-handler/issues/26). | ||
|
||
On iOS, the permission_handler plugin use [macros](https://github.com/BaseflowIT/flutter-permission-handler/blob/develop/ios/Classes/PermissionHandlerEnums.h) to control whether a permission is supported. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This URL is no longer valid. Any chance to submit a pr to correct it?
|
||
On iOS, the permission_handler plugin use [macros](https://github.com/BaseflowIT/flutter-permission-handler/blob/develop/ios/Classes/PermissionHandlerEnums.h) to control whether a permission is supported. | ||
|
||
By default, all the permissions listed [here](https://github.com/Baseflow/flutter-permission-handler#list-of-available-permissions) are supported. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This URL is no longer valid. Any chance to submit a pr to correct it?
> ... # Here are some configurations automatically generated by flutter | ||
> | ||
> # You can remove unused permissions here | ||
> # for more infomation: https://github.com/BaseflowIT/flutter-permission-handler/blob/develop/ios/Classes/PermissionHandlerEnums.h |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This URL is no longer valid. Any chance to submit a pr to correct it?
@@ -64,6 +64,47 @@ post_install do |installer| | |||
installer.pods_project.targets.each do |target| | |||
target.build_configurations.each do |config| | |||
config.build_settings['ENABLE_BITCODE'] = 'NO' | |||
|
|||
# You can remove unused permissions here | |||
# for more infomation: https://github.com/BaseflowIT/flutter-permission-handler/blob/develop/ios/Classes/PermissionHandlerEnums.h |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This URL is no longer valid. Any chance to submit a pr to correct it?
I used this library in my application. But when I submitted the application to the app store for review, I received a warning email. same as #26.
I see in README that "on iOS you will have to include all permission options when you want to submit your app". This makes this library almost impossible to use on iOS.
I added some macro definitions to remove useless permissions. (reference: https://github.com/delba/permission)
This PR will not change any default behavior.
By default, these macro definitions do not exist, and the code will default that they are enabled. Unless the user specifies their value in the Podfile.
✨ What kind of change does this PR introduce? (Bug fix, feature, docs update...)
feature
same as before
🆕 What is the new behavior (if this is a feature change)?
Users can remove unused permission codes on iOS.
💥 Does this PR introduce a breaking change?
No
🐛 Recommendations for testing
Usage: 296982b
📝 Links to relevant issues/docs
#26
🤔 Checklist before submitting