Snippet Intents and location

Hello, I’d like to ask about best practices for handling interactive snippet intents when working with the user’s location.

My use case is: 1. Get the user’s location 2. Fetch nearby data 3. Display it

My current flow is: try to show the snippet view in "loading" state while waiting for Core Location Manager, then fetch data and reload() the view. BUT I’m running into an issue where I sometimes receive Core Location error 1 (not authorized), even though the main app has “While In Use” authorization.

It seems that in some cases, especially when the app has been force-closed, App Intents are unable to start location updates, even though I’m using supportedModes = .foreground(.dynamic).

Any guidance would be appreciated.

Cheers, Ondrej

Snippet Intents and location
 
 
Q