2

Set, Detect, and Avoid Mock Locations

(this is technically a duplicate of https://tasker.helprace.com/i1124-mock-up-on-tasker but the title of that post is misleading, at best. It also doesn't have very detailed requirements or a user story. So, here is a better one:)

As a user of Tasker, I need the ability to be able to set my system's location via the Developer Option's Mock Location App feature so I can ask Tasker to set a fake GPS location for the rest of the system.

I also need the ability for Tasker to "see past" that fake location so that profile conditions that use Location-driven conditions still work as if they aren't affected by the Mock Location set by Tasker. (Ideally, make it an option in each Location condition, something like: Allow Mock Locations with options: Yes, No, Any [which is ultimately not the same as a checkbox!!!])

Finally, as a Tasker user, I need the ability to detect if a Mock Location is currently active, as a global system (Tasker) variable (Mock Location Active [%MOCKLOC]). Users seeking to make the Mock Location check an independent condition in a profile can use the Variable State condition and consume %MOCKLOC; as well as in Tasks.

Important: please make all detection checks (including %MOCKLOC) based off of whether the system thinks a Mock Location is set (versus an internal Tasker state), that way if you set the Mock Location from an app other than Tasker, it can still detect it! It is known that there is an API call to determine this for any app.

If the Android API has additional information surrounding Mock Locations that extends beyond the scope of this enhancement request, please make that data available to Tasker users via an Action.