Skip to content
This repository was archived by the owner on Nov 8, 2023. It is now read-only.
This repository was archived by the owner on Nov 8, 2023. It is now read-only.

Location Request Error : Error: Cannot enable the location service. Error: java.lang.NoClassDefFoundError: com.google.android.gms.location.LocationRequest #173

Closed

Description

@JaganJonnala

JS: Location Request Error : Error: Cannot enable the location service. Error: java.lang.NoClassDefFoundError: com.google.android.gms.location.LocationRequest
JS: java.lang.Class.classForName(Native Method)
JS: java.lang.Class.forName(Class.java:324)
JS: java.lang.Class.forName(Class.java:285)
JS: com.tns.Runtime.getClassForName(Runtime.java:1036)
JS: com.tns.ClassResolver.resolveClass(ClassResolver.java:27)
JS: com.tns.Runtime.resolveClass(Runtime.java:604)
JS: com.tns.Runtime.callJSMethodNative(Native Method)
JS: com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1116)
JS: com.tns.Runtime.callJSMethodImpl(Runtime.java:996)
JS: com.tns.Runtime.callJSMethod(Runtime.java:983)
JS: com.tns.Runtime.callJSMethod(Runtime.java:967)
JS: com.tns.Runtime.callJSMethod(Runtime.java:959)
JS: com.tns.gen.java.lang.Object_button_19_32_ClickListenerImpl.onClick(Object_button_19_32_ClickListenerImpl.java:17)
JS: android.view.View.performClick(View.java:5233)
JS: android.view.View$PerformClick.run(View.java:21209)
JS: androi...
ActivityManager: Killing 1836:org.nativescript.qwipo/u0a163 (adj 9): remove task
ActivityManager: killProcessGroupAsync took 3 ms for PID 1836 on thread 14
ActivityManager: cleanUpApplicationRecord -- 1836

Activity

  1. JaganJonnala commented on Nov 21, 2018

    @JaganJonnala
    Author

    Facing this issue to enable request with nativescript-geolocation.After i have upgraded to nativescript 5.0.1.
    with my local machine and my master cahnges not related to new plugin but not working as expected.

  2. sivamamidi-REISys commented on Nov 21, 2018

    @sivamamidi-REISys

    +1

  3. DomResc commented on Nov 22, 2018

    @DomResc

    +1

  4. safaldas commented on Nov 22, 2018

    @safaldas

    nativescript 5 has problems with this plugin
    "Error: Cannot enable the location service. Error: java.lang.NoClassDefFoundError:

    Fixed it by downgrading my android to 4.1.3
    tns platform add android@4.1.3
    I know it sucks but no option that i know of now

  5. JaganJonnala commented on Nov 22, 2018

    @JaganJonnala
    Author

    I have Included the below code in my app.gradle
    to fix the issue

    dependencies {
      compile "com.google.android.gms:play-services-base:15.0.1" 
    }
    
    project.ext {
           googlePlayServicesVersion = "15.0.1"
    }
    dependencies {
       def googlePlayServicesVersion = project.googlePlayServicesVersion
       compile "com.google.android.gms:play-services-location:$googlePlayServicesVersion"
    }
    
  6. safaldas commented on Nov 22, 2018

    @safaldas

    I have Included the below code in my app.gradle
    to fix the issue

    dependencies {
      compile "com.google.android.gms:play-services-base:15.0.1" 
    }
    
    project.ext {
           googlePlayServicesVersion = "15.0.1"
    }
    dependencies {
       def googlePlayServicesVersion = project.googlePlayServicesVersion
       compile "com.google.android.gms:play-services-location:$googlePlayServicesVersion"
    }
    

    and fixed for 5.0?

  7. JaganJonnala commented on Nov 22, 2018

    @JaganJonnala
    Author

    I have Included the below code in my app.gradle
    to fix the issue

    dependencies {
      compile "com.google.android.gms:play-services-base:15.0.1" 
    }
    
    project.ext {
           googlePlayServicesVersion = "15.0.1"
    }
    dependencies {
       def googlePlayServicesVersion = project.googlePlayServicesVersion
       compile "com.google.android.gms:play-services-location:$googlePlayServicesVersion"
    }
    

    and fixed for 5.0?

    Yes.

  8. DimitarTodorov commented on Nov 23, 2018

    @DimitarTodorov
    Contributor

    Related to the last closed issue.
    You can find solution here:
    #172

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions