Best practices says
★ Note: Don’t overburden the user by requesting every permission at app startup. Be courteous of the user and only request permissions when they need access to a specific feature.
For instance, only prompt for microphone access when a user clicks on the microphone button. Users are more likely to allow a permission that they are expecting.
Syncthing purposely does the exact opposite. It requests three permissions at app startup. This process is “not courteous of the user” and when it was brought up in github as part of a feature request #1806, the reasoning provided is in stark contrast to all available best practices.
- Design your app’s UX so that specific actions in your app are associated with specific runtime permissions. Users should know which actions might require them to grant permission for your app to access private user data.
In this case,
- Request All files access only when the user is requesting a folder
- Request Battery optimizations, only when the sync starts
- Request location, if and when the user chooses to restrict to a specific WiFi network.
What if the user denies all three permissions? The app should still work according to graceful degradation of app(See handle denial section in the link above):
Guide the user’s attention. Highlight a specific part of your app’s UI where there’s limited functionality because your app doesn’t have the necessary permission. Several examples of what you could do include the following:
Show a message where the feature’s results or data would have appeared.
Display a different button that contains an error icon and color.
In case of storage permission denial, the app should show a error message where “other” folders should have appeared. The app should still show it’s inbuilt hidden private folders
/storage/emulated/0/Android/data/com.nutomic.syncthingandroid and work with it.
Be specific. Don’t display a generic message; instead, mention which features are unavailable because your app doesn’t have the necessary permission.
The current message isn’t specific at all.
Don’t block the user interface. In other words, don’t display a full-screen warning message that prevents users from continuing to use your app at all.
This is exactly what syncthing is doing. It’s blocking the user interface. In case of storage permission denial, the app should show a error message where other folders should have appeared, but still allow complete functionality of the app with the inbuilt folders.
Consider following standard best practices for a better User experience.