Closed frankvollebregt closed 2 years ago
1.6.12 is broken. You have to rollback to 1.6.6. The issue is actually caused by a null exception in the fromJson method in location_dto.dart due to the added provider field for location.
@nick1377 Thanks for the update. I was facing the same problem.
Does this plugin support sdk 31 (Android 12) ?
As seen in the build.gradle file it says compileSdkVersion 30
@mehdok @nick1377
@RohitRB I think it should, given that the most recent patch specifically mentions fixing compatibility with the Android 12 permissions.
My older test app with a 6-12 months old version of this plugin even works fine on my Android 12 Pixel 6.
@frankvollebregt
thanks for your feedback. But i am facing issues with this new OS called FunTouch OS running android 12, 11
What can be the min interval that we can go to in seconds when keeping distance filter 1 meter so that the OS doesn't ban our app and we stop receiving location updates?
this question is a bit off track but i find no other place to put it. @mehdok @atsumo @moovida @splangi @gomazaba
1.6.12 is broken. You have to rollback to 1.6.6. The issue is actually caused by a null exception in the fromJson method in location_dto.dart due to the added provider field for location.
Hi @nick1377, thanks for your answer. Unfortunately, it still won't work for me after rolling back the package version. Running the example
app with 1.6.6 works, so I'll try to adapt my code to that and hope I can get it working that way.
I just ran the app with the --no-sound-null-safety
flag, after which the callbacks come through as expected. This is using version 1.6.6 of the package.
You were completely right @nick1377, it was caused by the provider
being null
in the fromJson
method. For now, I've created a fork of the repo where I set the provider
to an empty String if it's missing. This seems to resolve the issue.
I'm not sure whether this is a solution that should be applied, or if it should instead be ensured that the provider is set: At any rate, if anyone wants to use this dependency instead for the time being, feel free:
dependency_overrides:
background_locator:
git:
url: git@github.com:frankvollebregt/background_locator.git
ref: location-dto-null-fix
As this issue is essentially the same as #301 I'll close this one.
same issue here, please fix it as soon as you can
Please remove my email from this email
Thanks, Rohit Rajnikant
M: 9099 20 9892 | Email: @.***
On Sun, Feb 6, 2022 at 6:07 PM daviddagan @.***> wrote:
same issue here, please fix it as soon as you can
— Reply to this email directly, view it on GitHub https://github.com/rekabhq/background_locator/issues/304#issuecomment-1030824303, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEXS4ETJIV4ACFY52YSBMGTUZZTQJANCNFSM5MHRXJPA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.
You are receiving this because you were mentioned.Message ID: @.***>
I fix this also for Flutter 3.0: https://github.com/glofru/background_locator
Hello. First of all, sorry if this is has been asked before, and thanks for the awesome package!
I set up the package similar to the example, but my Dart callback is never called (no difference if the app is running in the foreground or background).
In the console, I do see something like the following:
Where all logs have the same callback identifier.
Looking through the code, this seems to be caused in the
IsolateHolderService.kt
file. link to the lineIs there any immediate reason why this might be happening?
I tried running my code on 2 real devices:
But both show the same behaviour.
The callback specified in
BackgroundLocator.registerLocationUpdate
is in theLocationCallbackHandler
class as per the example:Any help solving this is appreciated!
Version information
background_locator: ^1.6.12 Flutter 2.8.1 • channel stable • https://github.com/flutter/flutter.git Framework • revision 77d935af4d (5 weeks ago) • 2021-12-16 08:37:33 -0800 Engine • revision 890a5fca2e Tools • Dart 2.15.1