0 Replies - 860 Views - Last Post: 11 March 2018 - 02:29 PM

#1 yellow_snake   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 16
  • Joined: 01-December 15

Cordova: can't run project on Android.

Posted 11 March 2018 - 02:29 PM

I'm trying to run cordova project on Android.
After I've got this problem I put
gradile 4.6
in my Ubuntu, with path to it in
.bashrc
. (I didn't forget
source ~.bashrc
) Also I edited
classpath 'com.android.tools.build:gradle:3.0.0'
to...
gradile:4.6`
and still getting this problem.

cordova run android --stacktrace`
    Android Studio project detected
    ANDROID_HOME=/home/joe/Android/SDK
    JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
    studio
    Subproject Path: CordovaLib
    Subproject Path: app

    FAILURE: Build failed with an exception.

    * What went wrong:
    A problem occurred configuring root project 'android'.
    > Could not resolve all files for configuration ':classpath'.
       > Could not resolve com.android.tools.build:gradle:4.6.
         Required by:
             project :
          > Could not resolve com.android.tools.build:gradle:4.6.
             > Could not get resource 'https://jcenter.bintray.com/com/android/tools/build/gradle/4.6/gradle-4.6.pom'.
                > Could not GET 'https://jcenter.bintray.com/com/android/tools/build/gradle/4.6/gradle-4.6.pom'.
                   > java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty
          > Could not resolve com.android.tools.build:gradle:4.6.
             > Could not get resource 'https://maven.google.com/com/android/tools/build/gradle/4.6/gradle-4.6.pom'.
                > Could not GET 'https://maven.google.com/com/android/tools/build/gradle/4.6/gradle-4.6.pom'.
                   > java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty

    * Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

    * Get more help at https://help.gradle.org

    BUILD FAILED in 1s
    (node:23645) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: /home/joe/CordovaProjects/TestApp/platforms/android/gradlew: Command failed with exit code 1 Error output:
    FAILURE: Build failed with an exception.

    * What went wrong:
    A problem occurred configuring root project 'android'.
    > Could not resolve all files for configuration ':classpath'.
       > Could not resolve com.android.tools.build:gradle:4.6.
         Required by:
             project :
          > Could not resolve com.android.tools.build:gradle:4.6.
             > Could not get resource 'https://jcenter.bintray.com/com/android/tools/build/gradle/4.6/gradle-4.6.pom'.
                > Could not GET 'https://jcenter.bintray.com/com/android/tools/build/gradle/4.6/gradle-4.6.pom'.
                   > java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty
          > Could not resolve com.android.tools.build:gradle:4.6.
             > Could not get resource 'https://maven.google.com/com/android/tools/build/gradle/4.6/gradle-4.6.pom'.
                > Could not GET 'https://maven.google.com/com/android/tools/build/gradle/4.6/gradle-4.6.pom'.
                   > java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty


Is This A Good Question/Topic? 0
  • +

Page 1 of 1