Since apple has deferred the "Always Allow" permission and only OS can and will ask for that permission based on its own convenience, it is hard to understand what all the scenarios are.
If you see the WWDC video: https://developer.apple.com/videos/play/wwdc2019/705/
The guy clearly says at 04:14, "you ask for requestAlwaysAuthorization, apple provides you with the max option of "While In Use", but at the same time the delegate callback says, the app has "Always Allow permission"". This works as expected, and my app gets the location updates, only If I keep it opened. At 04:35 he says, start Geofence activity as a background-tracking/always-allow requirement. This is where it confuses me, If I put my app in background, location updates are stopped. Why am I asked to setup a geofence for a user who is already in motion even when my delegate call back received "Always Allow" permission?
At 05:22, the pop up which solidifies the provisional always allow permission only comes up (at OS convenience), when you lock the device and unlock it, after putting it in the background as discussed in above paragraph. But all the data in between is lost. My app tracks user's trips and this will completely kill the valid use case of recording user's movement in a vehicle.
Even if I follow the video and create a geofence when app goes to the background and then start to move, nothing happens until I lock and unlock the device. This seems to be pretty useless.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…