Open Shivamtruein opened 4 years ago
I have the seem problem
me too, I have same problem
Thanks for reporting the problem.
Android have 3 types of accuracy. reference High accuracy = All possible providers (WiFi, Mobile networks, GPS) GPS = Only GPS. Battery saving = WiFi and Mobile network.
This plugin only supports high accuracy, you have to enable high accuracy location on settings before check mock location. read more
Me too, I have same problem.
any other solution ?
is there any solution for this issue?
other alternatives that are working https://pub.dev/packages/safe_device (null safety) https://pub.dev/packages/fake_gps_detector
other alternatives that are working https://pub.dev/packages/safe_device (null safety) https://pub.dev/packages/fake_gps_detector
safe_device is dependent with this library when checking Mock Location in Android platform. And you will get same result. i found similar issue in safe_device and found this thread.
is there any update on this issue? still got wrong isMockLocation = true on many users eventhough they did not use any mock gps apps
Hey! Got the same problem, so migrated on fake_gps_detector package and it works fine. But original package is not null-safety, so it's necessary to use this PR - https://github.com/andiksetyawan/fake_gps_detector/pull/2
Hey! Got the same problem, so migrated on fake_gps_detector package and it works fine. But original package is not null-safety, so it's necessary to use this PR - andiksetyawan/fake_gps_detector#2
Hi I am trying fake_gps_detector package (I just add fake_gps_detector: ^0.5.0 in my yaml and call the function in my project) but I don't get the result of await FakeGpsDetector.isFakeGps
for more than 5 seconds, is it really take a long time to get the result of await FakeGpsDetector.isFakeGps.
?
Hi I am trying fake_gps_detector package (I just add fake_gps_detector: ^0.5.0 in my yaml and call the function in my project) but I don't get the result of
await FakeGpsDetector.isFakeGps
for more than 5 seconds, is it really take a long time to get the result ofawait FakeGpsDetector.isFakeGps.
?
Hi! I had an error (not an exception, just an error in console log) when I tried await FakeGpsDetector.isFakeGps
at first time (wrote about it here - https://github.com/andiksetyawan/fake_gps_detector/pull/2#issuecomment-1544674034). After fixing this error, it becomes to work fine and fast (less than 1 sec). Checked on android emulator and on my device
Hi I am trying fake_gps_detector package (I just add fake_gps_detector: ^0.5.0 in my yaml and call the function in my project) but I don't get the result of
await FakeGpsDetector.isFakeGps
for more than 5 seconds, is it really take a long time to get the result ofawait FakeGpsDetector.isFakeGps.
?Hi! I had an error (not an exception, just an error in console log) when I tried
await FakeGpsDetector.isFakeGps
at first time (wrote about it here - andiksetyawan/fake_gps_detector#2 (comment)). After fixing this error, it becomes to work fine and fast (less than 1 sec). Checked on android emulator and on my device
I will try to add that configuration and I wanna ask about how you add fake_gps_detector package in yaml, do you add like this : fake_gps_detector: ^0.5.0
or you add github link of fake_gps_detector in yaml ?
I will try to add that configuration and I wanna ask about how you add fake_gps_detector package in yaml, do you add like this :
fake_gps_detector: ^0.5.0
or you add github link of fake_gps_detector in yaml ?
For using non-published fixed version you can just add next lines in pubspec instead of fake_gps_detector: ^0.5.0
fake_gps_detector:
git:
url: https://github.com/4RSIM3R/fake_gps_detector
I will try to add that configuration and I wanna ask about how you add fake_gps_detector package in yaml, do you add like this :
fake_gps_detector: ^0.5.0
or you add github link of fake_gps_detector in yaml ?For using non-published fixed version you can just add next lines in pubspec instead of
fake_gps_detector: ^0.5.0
fake_gps_detector: git: url: https://github.com/4RSIM3R/fake_gps_detector
Thank you veeeeery much, I will try your suggestion
i have the same problem but I resolved it by writing twice
isFakeGPS = await maps.detectFakeGPS(); isFakeGPS = await maps.detectFakeGPS();
I think it would be better if it was written once
I am using this in my project. I am using a plugin Location for getting location and this for detecting mock. After providing the location access to the app for the very first time plugin returns true even though there is no mock location app running. After that, it runs correctly but every time permission is requested this code returns true.
Code I am using :
TrustLocation.isMockLocation.then((value) { if (value) { showToast("Mock location enabled, Attendance not allowed", duration: Toast.LENGTH_LONG, gravity: Toast.CENTER); Navigator.of(context).pop(); } }).catchError((onError) {});
Flutter version 1.17.1 in use.