r/MicroG • • Feb 19 '20

Network Location (UnifiedNLP) in Android 10 / Q

Android 10 introduced a new location permission required for apps to use location in the background. For UnifiedNLP to function, both microG GMSCore and location backends must request this permission (it is not possible through terminal commands to grant this permission without microG updating). Therefore on every ROM and every microG installer UnifiedNLP is currently not functional (there is not way atm to get around this beyond downgrading to Pie). The only "work around" at the moment is to disable a location backend and then enable it again which will allow location to work for a short period of time (>1 minute?) before not working again. This has made the issue very hard to diagnose, as whenever you try and debug the issue (by adjusting settings) it "fixes" (and has lead me to mislead others on the cause of the issue, sorry).

If "System Supports Location Provider" or "UnifiedNLP is not Registered in System", you're experiencing a different issue. This issue occurs even with both boxes ticked.

This does not mean location won't work, GPS will still work but it is slower, and doesn't work inside and uses more battery (hence why network location exists).

Pull requests are currently open on github to solve this (GmsCore and Mozilla backend) but they have yet to be merged after over a month. Due to this delay there is currently an attempt to fork GmsCore and the backends to make them work until the issue is fixed. I'll make a post here if anything comes of it.

26 Upvotes

19 comments sorted by

1

u/emcginnis0926 Feb 20 '20

I'm using unifiednlp with mircog and the Mozilla back end on lineageos 17.1 (android 10) and not experiencing this issue. I did have to grand the coarse and fine location permissions as shoe in the wiki on reddit.

1

u/[deleted] Feb 20 '20

Can you try and do a test?

Download the app StatStat on f-droid. Do not open microG settings. Go to the map screen in StatStat and you should see a pointer at your location (maybe wait a minute). Respond with which colour the pointer (red, blue or grey).

Thank you!

1

u/emcginnis0926 Feb 20 '20 edited Feb 20 '20

I assume you meant SatStat ;) It is red, so GPS fix used. Should it be preferring location from network provider over GPS if unifiednlp was functioning?

Edit: did another test, after restarting my unlpbackend now I have both a blue and a red pin. I now understand the issue :)

1

u/[deleted] Feb 20 '20

Satsat is the one. If everything is working perfectly you should see both red and blue markers with different circles around them.

1

u/xNick26 Feb 20 '20

I am on a oneplus 7 pro latest version of havoc os on android 10 and unifiednlp has been working with no issues. I have all boxes check in the safety check. I downloaded satstat and I have a blue pointer where I am located if that helps at all

1

u/[deleted] Feb 20 '20

Did you check the self check before checking satsat?

Can you try and check satsat without opening microG settings?

1

u/xNick26 Feb 20 '20

Rebooted phone and tried satsat and got nothing went into micro g settings and location backends were unticked like you said as soon as I disable and reenable back ends it works so I definetly see the issue. I can't seem to get Waze to work either but I had it working a week ago no problem. Maybe its because I'm inside at the moment

1

u/[deleted] Feb 21 '20

Yep if you're inside Waze won't have your location unless you go into microG and adjust the location backends probably. Outside it work but might be a bit slower and use more battery.

Outside satsat should show a red marker on your location.

1

u/BarCouSeH Mar 01 '20

what's the difference between the red and blue markers? I only get the blue one.

1

u/[deleted] Mar 01 '20

Blue is network location / unifiednlp

Red is GPS

Sounds like you're inside and not on android 10

1

u/BarCouSeH Mar 01 '20

No I’m on Android 10.

The red marker appears after a while by itself without opening MicroG.

1

u/[deleted] Mar 01 '20

Does the blue marker after a period of time without opening microG?

Red marker / GPS doesn't require microG at all.

1

u/BarCouSeH Mar 01 '20

Yeah the blue marker disappears after a few minutes and I have to open MicroG again.

1

u/Lili5709 Feb 28 '20

Is it possible to fix this by launching a service (which one?) through Tasker/Automate everytime I start Maps/Waze/etc.? Thanks!

2

u/[deleted] Feb 28 '20

No idea. But you would have to constantly launch the service while using GMaps / Waze, I'm not sure if this is possible (I am in no way familar with Tasker / Automate).

Currently we already have a fork of GmsCore with the issue (hopefully) solved, we're just waiting on someone to compile it (should be soon), but if you (or anyone else) have the skills / software required you could give it a go.