Closed toufiqpathan closed 2 months ago
Hi @christocracy,UAE customers are facing this issue. Is the plugin not working for any specific zone? Please help me with this ASAP.
java.lang.ClassNotFoundException: driverconnect.latitude247.BackgroundGeolocationHeadlessTask
Your problem has nothing to do with geography. You failed to properly configure your headless-task class.
See api docs Config.enableHeadless.
HI @christocracy ,
Thanks for your response, i have add the enableHeadless as true in ready function, still activity is getting kill, here is adb logcat logs.txt
There's far more to enabling headless mode than enableHeadless: true.
You have to create a custom Java class. It is a very advanced feature requiring careful attention to following the Setup Instructions, as detailed in the api docs.
yeah i have created the java class file
That's your BackgroundFetch headless task.
What about the BackgroundGeolocation headless task?
shall i create BackgroundGeolocation headless task in the same folder?
Just follow the api docs Config.headlessTask for each plugin."
Followed the api doc for headlessTask, still getting the error attached the logs logs.txt
System.err: Caused by: java.lang.ClassNotFoundException: Didn't find class "driverconnect.latitude247.BackgroundGeolocationHeadlessTask"
In BackgroundGeolocationHeadlessTask class file, do we need to update the package name?
What do the Setup Instructions tell you to do?
i am not getting any error, but still activity is getting closed logs.txt [Uploading logs.txt…]()
I don't see any problems coming from the plug-in. See wiki "Debugging" and learn to use verbose logging
Hi @christocracy , here is the verbose logs, when i put application in the background. logs.txt
I suggest you comment-out all plug-in code except for the call to .ready(config).
Those don't look anything like the plug-in's verbose logs. The plug-in's verbose logs are very colorful with heavy use of emojis.
See api docs Config.logLevel.
READ the wiki "Debugging"
here is the verbose loglevel with 5 logs.txt
I told you to disable everything but .ready. Your .watchPosition code is still running!
Also, what are you doing in your headless task?
I have commented out the other parts of the code except for '.ready,' and in the headless task, I have implemented exactly what is documented in the API, without adding any additional code to the 'headlesstask.java' file. HeadlessTasktxt.txt logs.txt
I see no issue with the plug-in. It is not responsible for you app being terminated. There is no exception raised and the plug-in headless-task happily runs.
I suggest you create yourself a simple hello-world app and experiment using the plug-in in isolation.
Your Environment
cordova -v
): 12.0.0cordova platform ls
):android 12.0.0Plugin config provided to
#ready
:Expected Behavior
Actual Behavior
Steps to Reproduce
1. 2. 3. 4.
Context
Debug logs
Logs
``` 2024-01-22 14:51:57.391 21761-21761 Compatibil...geReporter driverconnect.latitude247 D Compat change id reported: 171979766; UID 10219; state: ENABLED 2024-01-22 14:51:57.410 21761-21761 nativeloader driverconnect.latitude247 D Configuring classloader-namespace for other apk /system/framework/org.apache.http.legacy.jar. target_sdk_version=33, uses_libraries=ALL, library_path=/data/app/~~u4vgj-IhtgxANhtVL6WeGw==/driverconnect.latitude247-M38fXJ_f16JPUpHWwASv3A==/lib/x86_64:/data/app/~~u4vgj-IhtgxANhtVL6WeGw==/driverconnect.latitude247-M38fXJ_f16JPUpHWwASv3A==/base.apk!/lib/x86_64, permitted_path=/data:/mnt/expand:/data/user/0/driverconnect.latitude247 2024-01-22 14:51:57.412 21761-21761 ziparchive driverconnect.latitude247 W Unable to open '/data/app/~~u4vgj-IhtgxANhtVL6WeGw==/driverconnect.latitude247-M38fXJ_f16JPUpHWwASv3A==/base.dm': No such file or directory 2024-01-22 14:51:57.412 21761-21761 ziparchive driverconnect.latitude247 W Unable to open '/data/app/~~u4vgj-IhtgxANhtVL6WeGw==/driverconnect.latitude247-M38fXJ_f16JPUpHWwASv3A==/base.dm': No such file or directory 2024-01-22 14:51:57.769 21761-21761 nativeloader driverconnect.latitude247 D Configuring classloader-namespace for other apk /data/app/~~u4vgj-IhtgxANhtVL6WeGw==/driverconnect.latitude247-M38fXJ_f16JPUpHWwASv3A==/base.apk. target_sdk_version=33, uses_libraries=, library_path=/data/app/~~u4vgj-IhtgxANhtVL6WeGw==/driverconnect.latitude247-M38fXJ_f16JPUpHWwASv3A==/lib/x86_64:/data/app/~~u4vgj-IhtgxANhtVL6WeGw==/driverconnect.latitude247-M38fXJ_f16JPUpHWwASv3A==/base.apk!/lib/x86_64, permitted_path=/data:/mnt/expand:/data/user/0/driverconnect.latitude247 2024-01-22 14:51:57.794 21761-21761 GraphicsEnvironment driverconnect.latitude247 V ANGLE Developer option for 'driverconnect.latitude247' set to: 'default' 2024-01-22 14:51:57.795 21761-21761 GraphicsEnvironment driverconnect.latitude247 V ANGLE GameManagerService for driverconnect.latitude247: false 2024-01-22 14:51:57.796 21761-21761 GraphicsEnvironment driverconnect.latitude247 V Neither updatable production driver nor prerelease driver is supported. 2024-01-22 14:51:57.803 21761-21761 NetworkSecurityConfig driverconnect.latitude247 D No Network Security Config specified, using platform default 2024-01-22 14:51:57.807 21761-21761 NetworkSecurityConfig driverconnect.latitude247 D No Network Security Config specified, using platform default 2024-01-22 14:51:57.881 21761-21761 Compatibil...geReporter driverconnect.latitude247 D Compat change id reported: 183155436; UID 10219; state: ENABLED 2024-01-22 14:51:57.883 21761-21761 FirebaseApp driverconnect.latitude247 I Device unlocked: initializing all Firebase APIs for app [DEFAULT] 2024-01-22 14:51:57.960 21761-21798 FirebaseAuth driverconnect.latitude247 I [FirebaseAuth:] Preparing to create service connection to fallback implementation 2024-01-22 14:51:57.981 21761-21808 ziparchive driverconnect.latitude247 W Unable to open '/data/user_de/0/com.google.android.gms/app_chimera/m/00000002/DynamiteLoader.dm': No such file or directory 2024-01-22 14:51:57.981 21761-21808 ziparchive driverconnect.latitude247 W Unable to open '/data/user_de/0/com.google.android.gms/app_chimera/m/00000002/DynamiteLoader.dm': No such file or directory 2024-01-22 14:51:57.991 21761-21808 DynamiteModule driverconnect.latitude247 I Considering local module com.google.android.gms.measurement.dynamite:51 and remote module com.google.android.gms.measurement.dynamite:87 2024-01-22 14:51:57.991 21761-21808 DynamiteModule driverconnect.latitude247 I Selected remote version of com.google.android.gms.measurement.dynamite, version >= 87 2024-01-22 14:51:57.991 21761-21808 DynamiteModule driverconnect.latitude247 V Dynamite loader version >= 2, using loadModule2NoCrashUtils 2024-01-22 14:51:58.041 21761-21808 ziparchive driverconnect.latitude247 W Unable to open '/data/user_de/0/com.google.android.gms/app_chimera/m/00000007/MeasurementDynamite.dm': No such file or directory 2024-01-22 14:51:58.042 21761-21808 ziparchive driverconnect.latitude247 W Unable to open '/data/user_de/0/com.google.android.gms/app_chimera/m/00000007/MeasurementDynamite.dm': No such file or directory 2024-01-22 14:51:58.051 21761-21812 TransportR...oScheduler driverconnect.latitude247 D Upload for context TransportContext(cct, DEFAULT, MSRodHRwczovL2ZpcmViYXNlbG9nZ2luZy1wYS5nb29nbGVhcGlzLmNvbS92MS9maXJlbG9nL2xlZ2FjeS9iYXRjaGxvZ1xBSXphU3lDY2traUg4aTJaQVJ3T3MxTEV6RktsZDE1YU9HOG96S28=) is already scheduled. Returning... 2024-01-22 14:51:58.203 21761-21813 FA driverconnect.latitude247 V App measurement collection enabled 2024-01-22 14:51:58.206 21761-21813 FA driverconnect.latitude247 V App measurement enabled for app package, google app id: driverconnect.latitude247, 1:490224465825:android:9529c8b09cc3b244 2024-01-22 14:51:58.208 21761-21813 FA driverconnect.latitude247 I App measurement initialized, version: 75066 2024-01-22 14:51:58.209 21761-21813 FA driverconnect.latitude247 I To enable debug logging run: adb shell setprop log.tag.FA VERBOSE 2024-01-22 14:51:58.209 21761-21813 FA driverconnect.latitude247 I To enable faster debug mode event logging run: adb shell setprop debug.firebase.analytics.app driverconnect.latitude247 2024-01-22 14:51:58.210 21761-21813 FA driverconnect.latitude247 D Debug-level message logging enabled 2024-01-22 14:51:58.274 21761-21761 FirebaseCrashlytics driverconnect.latitude247 I Initializing Firebase Crashlytics 18.1.0 for driverconnect.latitude247 2024-01-22 14:51:58.396 21761-21825 libcrashlytics driverconnect.latitude247 D Initializing libcrashlytics version 3.0.0 2024-01-22 14:51:58.401 21761-21825 libcrashlytics driverconnect.latitude247 D Initializing native crash handling successful. 2024-01-22 14:51:58.447 21761-21761 ect.latitude247 driverconnect.latitude247 W Accessing hidden method Ldalvik/system/CloseGuard;->get()Ldalvik/system/CloseGuard; (unsupported,core-platform-api, reflection, allowed) 2024-01-22 14:51:58.448 21761-21761 ect.latitude247 driverconnect.latitude247 W Accessing hidden method Ldalvik/system/CloseGuard;->open(Ljava/lang/String;)V (unsupported,core-platform-api, reflection, allowed) 2024-01-22 14:51:58.448 21761-21761 ect.latitude247 driverconnect.latitude247 W Accessing hidden method Ldalvik/system/CloseGuard;->warnIfOpen()V (unsupported,core-platform-api, reflection, allowed) 2024-01-22 14:51:58.503 21761-21761 FirebaseInitProvider driverconnect.latitude247 I FirebaseApp initialization successful 2024-01-22 14:51:58.506 21761-21813 FA driverconnect.latitude247 D Resetting session stitching token to not null 2024-01-22 14:51:58.515 21761-21761 AGConnectProvider driverconnect.latitude247 I AGConnectInitializeProvider#onCreate 2024-01-22 14:51:58.516 21761-21761 AGConnectInstance driverconnect.latitude247 I AGConnectInstance#initialize 2024-01-22 14:51:58.525 21761-21761 ServiceRegistrarParser driverconnect.latitude247 I getServices 2024-01-22 14:51:58.527 21761-21761 ServiceRegistrarParser driverconnect.latitude247 I services:0 2024-01-22 14:51:58.531 21761-21813 FA driverconnect.latitude247 V Connecting to remote service 2024-01-22 14:51:58.537 21761-21761 AGC_Instance driverconnect.latitude247 I AGC SDK initialize end, default route:UNKNOWN 2024-01-22 14:51:58.550 21761-21813 FA driverconnect.latitude247 V Connection attempt already in progress 2024-01-22 14:51:58.556 21761-21813 FA driverconnect.latitude247 V Connection attempt already in progress 2024-01-22 14:51:58.619 21761-21761 HMSSDK_HMS...ageManager driverconnect.latitude247 E resolveInfoList is null or empty 2024-01-22 14:51:58.621 21761-21761 HMSSDK_HMS...ageManager driverconnect.latitude247 E PackagePriorityInfo list is null 2024-01-22 14:51:58.623 21761-21761 HMSSDK_HMS...ageManager driverconnect.latitude247 E