CommandInvokationFailure: Gradle build failed.
C:/Program Files/Java/jdk1.8.0_172\bin\java.exe -classpath “E:\unity\Editor\Data\PlaybackEngines\AndroidPlayer\Tools\gradle\lib\gradle-launcher-5.1.1.jar” org.gradle.launcher.GradleMain “-Dorg.gradle.jvmargs=-Xmx4096m” “assembleRelease”
stderr[
FAILURE: Build failed with an exception.
- What went wrong:
A problem occurred configuring root project ‘gradleOut’.
Could not resolve all artifacts for configuration ‘:classpath’.
Could not resolve com.android.tools.build:gradle:3.4.0.
Required by:
project :
Could not resolve com.android.tools.build:gradle:3.4.0.
Could not get resource ‘https://repo.maven.apache.org/maven2/com/android/tools/build/gradle/3.4.0/gradle-3.4.0.pom’.
Could not GET ‘https://repo.maven.apache.org/maven2/com/android/tools/build/gradle/3.4.0/gradle-3.4.0.pom’.
repo.maven.apache.org
Could not resolve com.android.tools.build:gradle:3.4.0.
Could not get resource ‘https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/3.4.0/gradle-3.4.0.pom’.
Could not GET ‘https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/3.4.0/gradle-3.4.0.pom’.
dl.google.com
Could not resolve com.android.tools.build:gradle:3.4.0.
Could not get resource ‘https://jcenter.bintray.com/com/android/tools/build/gradle/3.4.0/gradle-3.4.0.pom’.
Could not GET ‘https://jcenter.bintray.com/com/android/tools/build/gradle/3.4.0/gradle-3.4.0.pom’.
jcenter.bintray.com
-
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. -
Get more help at https://help.gradle.org
BUILD FAILED in 1s
]
stdout[
]
exit code: 1
UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.Command.Run (System.String command, System.String args, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.AndroidJavaTools.RunJava (System.String args, System.String workingdir, System.Action1 progress, System.String error) UnityEditor.Android.GradleWrapper.Run (UnityEditor.Android.AndroidJavaTools javaTools, System.String workingdir, System.String task, System.Action
1 progress)
Rethrow as GradleInvokationException: Gradle build failed
UnityEditor.Android.GradleWrapper.Run (UnityEditor.Android.AndroidJavaTools javaTools, System.String workingdir, System.String task, System.Action`1 progress)
UnityEditor.Android.PostProcessor.Tasks.BuildGradleProject.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context)
UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context)
UnityEditor.BuildPlayerWindow:BuildPlayerAndRun()