Skip to content
This repository has been archived by the owner on Oct 15, 2022. It is now read-only.

Android 11 breaks local network detection... again #87

Open
mlim15 opened this issue Jul 9, 2020 · 0 comments
Open

Android 11 breaks local network detection... again #87

mlim15 opened this issue Jul 9, 2020 · 0 comments

Comments

@mlim15
Copy link
Contributor

mlim15 commented Jul 9, 2020

Another year, another Android release, another set of stupid permissions changes that break apps for no reason. Android 11 now further differentiates user permissions for location between foreground/background, and because in Android 10 Google changed SSID queries to count as "location", this means that Audinaut can no longer detect whether to use the local or external server address when it is backgrounded. In practice, this means that it when you have a local server address set up, Audinaut will be unable to download new tracks or basically reach the server at all if you are using another app or the screen is off.

Adding ACCESS_BACKGROUND_LOCATION and having the user manually grant background location access in app permissions does solve this issue, but leads to unsightly "Audinaut accessed your location in the background" notifications. Are you OK with that as a solution? As a side note, this permission also apparently leads to increased scrutiny from Google when submitting apps to Google Play.

Alternatively, I could try to cook something up where it tries to ping the local address (or get a HEAD or something? do all subsonic-compatible servers provide an HTTP frontend?) and if that fails it uses the external one, but I'm not sure how much overhead this would add to each request compared to the current way things are done. That might also not work as reliably as I am hoping.

If you are OK with the background location access notifications, I can send a pull request with that. Just wanted to know how you'd like to proceed before I spend time on an alternative solution.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant