The app Buildig makes an error with no error message
Gradle error like this:
Configuration on demand is an incubating feature.
Configuration 'compile' in project ':app' is deprecated. Use 'implementation' instead.
Configuration 'androidTestCompile' in project ':app' is deprecated. Use 'androidTestImplementation' instead.
Configuration 'testCompile' in project ':app' is deprecated. Use 'testImplementation' instead.
AGPBI: {"kind":"warning","text":"Transform \u0027FirebasePerformancePlugin\u0027 uses scope PROJECT_LOCAL_DEPS which is deprecated and replaced with EXTERNAL_LIBRARIES","sources":[{},{}]}
AGPBI: {"kind":"warning","text":"Transform \u0027FirebasePerformancePlugin\u0027 uses scope SUB_PROJECTS_LOCAL_DEPS which is deprecated and replaced with EXTERNAL_LIBRARIES","sources":[{},{}]}
AGPBI: {"kind":"warning","text":"Transform \u0027FirebasePerformancePlugin\u0027 uses scope PROJECT_LOCAL_DEPS which is deprecated and replaced with EXTERNAL_LIBRARIES","sources":[{},{}]}
AGPBI: {"kind":"warning","text":"Transform \u0027FirebasePerformancePlugin\u0027 uses scope SUB_PROJECTS_LOCAL_DEPS which is deprecated and replaced with EXTERNAL_LIBRARIES","sources":[{},{}]}
AGPBI: {"kind":"warning","text":"Transform \u0027FirebasePerformancePlugin\u0027 uses scope PROJECT_LOCAL_DEPS which is deprecated and replaced with EXTERNAL_LIBRARIES","sources":[{},{}]}
AGPBI: {"kind":"warning","text":"Transform \u0027FirebasePerformancePlugin\u0027 uses scope SUB_PROJECTS_LOCAL_DEPS which is deprecated and replaced with EXTERNAL_LIBRARIES","sources":[{},{}]}
The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead.
registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection)
:clean
:app:clean
:app:preBuild UP-TO-DATE
:app:preReleaseBuild
:app:compileReleaseAidl
:app:compileReleaseRenderscript
:app:checkReleaseManifest
:app:generateReleaseBuildConfig
:app:mergeReleaseShaders
:app:compileReleaseShaders
:app:generateReleaseAssets
:app:mergeReleaseAssets
:app:createReleaseCompatibleScreenManifests
:app:processReleaseManifest
:app:fabricGenerateResourcesRelease
:app:generateReleaseResValues
:app:generateReleaseResources
:app:processReleaseGoogleServices
Parsing json file: D:\Users\Tobin\AndroidStudioProjects\Anlagenstammblatt\app\google-services.json
:app:mergeReleaseResources
:app:splitsDiscoveryTaskRelease
:app:processReleaseResources
:app:generateReleaseSources
:app:mockableAndroidJar FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:mockableAndroidJar'.
> java.lang.ExceptionInInitializerError (no error message)
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED in 20s
19 actionable tasks: 19 executed, 0 avoided (0%)
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED in 20s
19 actionable tasks: 19 executed, 0 avoided (0%)
That it Runns the App without an error
build.gradle(Module: app):
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.0.0-alpha1'
classpath 'com.google.gms:google-services:3.1.0'
classpath 'com.google.firebase:firebase-plugins:1.1.0'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
Can you try running ./gradlew --stop and then building again? I think some running gradle daemons may be causing this (fixed it for me)
@samtstern
This doesn't work for me
but it throws an other error
Error:Execution failed for task ':app:packageInstantRunResourcesDebug'.
org.gradle.tooling.BuildException (no error message)
Which sample are you trying to build? Also can you get a more detailed error message?
by just adding classpath 'com.google.firebase:firebase-plugins:1.1.0' in project gradle, we will receive following when build.
Error:java.lang.NoSuchMethodError: com.google.common.util.concurrent.MoreExecutors.directExecutor()Ljava/util/concurrent/Executor;
Google has sent me the following bug fix:
We've got it to work by replacing聽classpath 'com.google.firebase:firebase-plugins:1.1.0'聽with the following:
classpath ('com.google.firebase:firebase-plugins:1.1.0') {
exclude group: 'com.google.guava', module: 'guava-jdk5'
}
This crash occurs when there are different guava dependencies and will be fixed in the next plugin version.
Looks like @Nibot1 found the fix for this issue a while ago. Closing, thanks!
I think that is just a workaround. And this issue should be closed only if confirmed fixed in the next release.
@seventhmoon the issue is closed here for a few reasons:
However we agree with you that this is not "solved" and we are certainly tracking it internally
Most helpful comment
Google has sent me the following bug fix:
We've got it to work by replacing聽classpath 'com.google.firebase:firebase-plugins:1.1.0'聽with the following:
classpath ('com.google.firebase:firebase-plugins:1.1.0') {
exclude group: 'com.google.guava', module: 'guava-jdk5'
}
This crash occurs when there are different guava dependencies and will be fixed in the next plugin version.