JulianAssmann / flutter_background

A flutter plugin to keep apps running in the background via foreground services. Android only.
https://pub.dev/packages/flutter_background
MIT License
89 stars 52 forks source link

I am not getting the persistent notification #72

Closed kgoofori closed 3 months ago

kgoofori commented 1 year ago

I am not able to get the app running with the persistent notification even after running FlutterBackground.enableBackgroundExecution() successfully.

I am testing on Samsung A51 running android 12.

[✓] Flutter (Channel stable, 3.7.10, on macOS 12.5.1 21G83 darwin-x64, locale en-GB) [✓] Android toolchain - develop for Android devices (Android SDK version 32.0.0)

environment: sdk: '>=2.18.6 <3.0.0'

dependencies: flutter_background: ^1.2.0

Muhammad-Mohsen commented 1 year ago

I think this is related to https://github.com/JulianAssmann/flutter_background/issues/69 I'd try the solution by @jakoss to add the service to the AndroidManifset manually

<service android:name="de.julianassmann.flutter_background.IsolateHolderService" android:exported="false" />

KhaledYussef commented 1 year ago

<service android:name="de.julianassmann.flutter_background.IsolateHolderService" android:exported="true" />

Aturex1 commented 11 months ago

Not working here either. I'm using Android 14

flutter_background: ^1.2.0

JulianAssmann commented 3 months ago

Thanks for creating the issue. Can you please upgrade to the new version of the plugin (1.3.0), update your AndroidManifest.xml according to the new README (specifically including the foreground service types). This should fix this issue. If not, please feel free to re-open the issue.