I bought licence key for Android to create Geofencing App, I've successfully implemented that in Android/iOS but unable to create release build in Android. I've done all the configuration as explained here
Your Environment
Plugin version: ^4.16.0
Platform: Android
OS version: 14
Device manufacturer / model: OnePlus 9
Flutter info (flutter doctor):
[✓] Flutter (Channel stable, 3.24.0, on macOS 15.0 24A335 darwin-arm64, locale en-IN)
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 16.0)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2023.3)
[✓] Connected device (3 available)
[✓] Network resources
• No issues found!
* Plugin config:
<-- Syntax highlighting: DO NOT REMOVE -->
bg.BackgroundGeolocation.ready(
bg.Config(
reset: true,
geofenceInitialTriggerEntry: true,
geofenceModeHighAccuracy: true,
desiredAccuracy: bg.Config.DESIRED_ACCURACY_HIGH,
distanceFilter: 10,
enableHeadless: true,
notification: bg.Notification(
title: "TrackOn",
text: "Getting Location",
),
stopOnTerminate: false,
startOnBoot: true,
debug: false,
locationAuthorizationRequest: 'Always',
backgroundPermissionRationale: bg.PermissionRationale(
title:
"Allow {applicationName} to access this device's location even when the app is closed or not in use.",
message:
"This application gathers location information so that we can determine the user's activity level and adjust their health insurance benefits appropriately.",
positiveAction: 'Change to "{backgroundPermissionOptionLabel}"',
negativeAction: 'Cancel',
),
logLevel: bg.Config.LOG_LEVEL_VERBOSE,
),
).then((bg.State state) async {
debugPrint('[ready] ${state.toMap()}');
if (!state.enabled) {
await bg.BackgroundGeolocation.start();
}
}).catchError((error) {
debugPrint('[ready] ERROR: $error');
});
## Expected Behavior
Release build is should be installed and worked as its working in debug mode.
## Actual Behavior
I am able to create release build but its not getting installed. After that I tried to install in my device but its throwing an error as below.
<img width="364" alt="Screenshot 2024-09-28 at 5 21 16 PM" src="https://github.com/user-attachments/assets/975590f1-312d-4790-95be-ed731a4dcced">
While running directly `flutter run --release` getting following error:
adb: failed to install /geofencing_flutter_app/build/app/outputs/flutter-apk/app-release.apk: Failure
[INSTALL_PARSE_FAILED_NO_CERTIFICATES: Failed to collect certificates from /data/app/vmdl1538718614.tmp/base.apk: Attempt to get length of null
array]
## Context
<!--- What were you trying to do? -->
Building release build to test in release mode.
## Debug logs
<!-- include iOS / Android logs
- ios XCode logs,
- use #getLog #emailLog methods (@see docs)
- Android: $ adb logcat -s TSLocationManager
-->
<details>
<summary>Logs</summary>
``` <!-- syntax-highligting: DO NOT REMOVE -->
Failure
[INSTALL_PARSE_FAILED_NO_CERTIFICATES: Failed to collect certificates from /data/app/vmdl1538718614.tmp/base.apk: Attempt to get length of null
array]
I bought licence key for Android to create Geofencing App, I've successfully implemented that in Android/iOS but unable to create release build in Android. I've done all the configuration as explained here
Your Environment
flutter doctor
):• No issues found!
<-- Syntax highlighting: DO NOT REMOVE --> bg.BackgroundGeolocation.ready( bg.Config( reset: true, geofenceInitialTriggerEntry: true, geofenceModeHighAccuracy: true, desiredAccuracy: bg.Config.DESIRED_ACCURACY_HIGH, distanceFilter: 10, enableHeadless: true, notification: bg.Notification( title: "TrackOn", text: "Getting Location", ), stopOnTerminate: false, startOnBoot: true, debug: false, locationAuthorizationRequest: 'Always', backgroundPermissionRationale: bg.PermissionRationale( title: "Allow {applicationName} to access this device's location even when the app is closed or not in use.", message: "This application gathers location information so that we can determine the user's activity level and adjust their health insurance benefits appropriately.", positiveAction: 'Change to "{backgroundPermissionOptionLabel}"', negativeAction: 'Cancel', ), logLevel: bg.Config.LOG_LEVEL_VERBOSE, ), ).then((bg.State state) async { debugPrint('[ready] ${state.toMap()}'); if (!state.enabled) { await bg.BackgroundGeolocation.start(); } }).catchError((error) { debugPrint('[ready] ERROR: $error'); });
adb: failed to install /geofencing_flutter_app/build/app/outputs/flutter-apk/app-release.apk: Failure [INSTALL_PARSE_FAILED_NO_CERTIFICATES: Failed to collect certificates from /data/app/vmdl1538718614.tmp/base.apk: Attempt to get length of null array]