Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Location continuelly #20

Closed
gaoyx-tech opened this issue Mar 2, 2021 · 4 comments
Closed

Location continuelly #20

gaoyx-tech opened this issue Mar 2, 2021 · 4 comments
Labels
more info needed More information is necessary to triage the bug

Comments

@gaoyx-tech
Copy link

hello,I am a Chinese flutter developer,I used this project for location continuelly,even if screen off or let the app back to background.I use HuaWei Meta20,I found that if screen off after seconds the service will stop,it cannot location again.

@JulianAssmann
Copy link
Owner

I am not sure how Huawei handles background execution of apps, as every OEM handles it a bit differently. What code are you trying to run where? Do you have any logs that could reveal the issue?
I did not test this package with geolocation services, but check out other plugins specifically made for this purpose like flutter_background_geolocation or background_locator.

@JulianAssmann JulianAssmann added the more info needed More information is necessary to triage the bug label Mar 2, 2021
@gaoyx-tech
Copy link
Author

ok,thanks for reply.

@JulianAssmann
Copy link
Owner

You're welcome. Please feel free to reopen the issue at any time.

@alkebuware
Copy link
Contributor

I was able to fix this problem recently and wanted to post a solution if anyone comes across this issue. In your Flutter app's Android's AndroidManifest.xml tag add the following

<service android:name="de.julianassmann.flutter_background.IsolateHolderService"
                 android:foregroundServiceType="location" />

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
more info needed More information is necessary to triage the bug
Projects
None yet
Development

No branches or pull requests

3 participants