Your builds (debug builds too) frequently fail for no apparent reason. Resubmitting the
same build succeeds. Occasionally there is a likely reason in the error log, such as
"out of memory". More often, there's just a mysterious error code.
Here's an example from this afternoon. Note that the error log itself seems to be incomplete.
Executing: /home/ec2-user/android-sdk/tools/android create project --target android-21 --name Launch --path /tmp/build293239726091506034xxx/Launch --activity LaunchStub --package com.boardspace --gradle --gradle-version 1.3.1 Created directory /tmp/build293239726091506034xxx/Launch/src/main/java
Created directory /tmp/build293239726091506034xxx/Launch/src/main/java/com/boardspace
Added file /tmp/build293239726091506034xxx/Launch/src/main/java/com/boardspace/LaunchStub.java
Created directory /tmp/build293239726091506034xxx/Launch/src/androidTest/java
Created directory /tmp/build293239726091506034xxx/Launch/src/androidTest/java/com/boardspace
Added file /tmp/build293239726091506034xxx/Launch/src/androidTest/java/com/boardspace/LaunchStubTest.java
Created directory /tmp/build293239726091506034xxx/Launch/src/main/res
Created directory /tmp/build293239726091506034xxx/Launch/src/main/res/values
Added file /tmp/build293239726091506034xxx/Launch/src/main/res/values/strings.xml
Created directory /tmp/build293239726091506034xxx/Launch/src/main/res/layout
Added file /tmp/build293239726091506034xxx/Launch/src/main/res/layout/main.xml
Created directory /tmp/build293239726091506034xxx/Launch/src/main/res/drawable-xhdpi
Created directory /tmp/build293239726091506034xxx/Launch/src/main/res/drawable-hdpi
Created directory /tmp/build293239726091506034xxx/Launch/src/main/res/drawable-mdpi
Created directory /tmp/build293239726091506034xxx/Launch/src/main/res/drawable-ldpi
Added file /tmp/build293239726091506034xxx/Launch/src/main/AndroidManifest.xml
Added file /tmp/build293239726091506034xxx/Launch/build.gradle
Created directory /tmp/build293239726091506034xxx/Launch/gradle/wrapper
Executing: /home/ec2-user/android/gradle-2.8/bin/gradle assembleDebug --no-daemon --stacktrace --info To honour the JVM settings for this build a new JVM will be forked. Please consider using the daemon: https://docs.gradle.org/2.8/userguide/gradle_daemon.html.
Starting daemon process: workingDir = /home/ec2-user/.gradle/daemon/2.8, daemonArgs: [/usr/java/jdk1.7.0_67/bin/java, -XX:MaxPermSize=400m, -XX:+HeapDumpOnOutOfMemoryError, -Xmx800m, -Dfile.encoding=UTF-8, -Duser.country=US, -Duser.language=en, -Duser.variant, -cp, /home/ec2-user/android/gradle-2.8/lib/gradle-launcher-2.8.jar, org.gradle.launcher.daemon.bootstrap.GradleDaemon, 2.8]
Starting process 'Gradle build daemon'. Working directory: /home/ec2-user/.gradle/daemon/2.8 Command: /usr/java/jdk1.7.0_67/bin/java -XX:MaxPermSize=400m -XX:+HeapDumpOnOutOfMemoryError -Xmx800m -Dfile.encoding=UTF-8 -Duser.country=US -Duser.language=en -Duser.variant -cp /home/ec2-user/android/gradle-2.8/lib/gradle-launcher-2.8.jar org.gradle.launcher.daemon.bootstrap.GradleDaemon 2.8
Successfully started process 'Gradle build daemon'
An attempt to start the daemon took 1.274 secs.
Connected to daemon DaemonInfo{pid=1390, address=[08ccfb8c-6ae7-4059-8d8a-71a34918bf36 port:42727, addresses:[/0:0:0:0:0:0:0:1%1, /127.0.0.1]], idle=false, context=DefaultDaemonContext[uid=e819866e-a8a9-405c-9c63-873bc154d95f,javaHome=/usr/java/jdk1.7.0_67,daemonRegistryDir=/home/ec2-user/.gradle/daemon,pid=1390,idleTimeout=120000,daemonOpts=-XX:MaxPermSize=400m,-XX:+HeapDumpOnOutOfMemoryError,-Xmx800m,-Dfile.encoding=UTF-8,-Duser.country=US,-Duser.language=en,-Duser.variant]}. Dispatching request BuildAndStop{id=b1ff4a95-396a-48de-9d8d-df41567aa1f1.1, currentDir=/tmp/build293239726091506034xxx/Launch}.
Received result org.gradle.launcher.daemon.protocol.BuildStarted@36c3af8c from daemon DaemonInfo{pid=1390, address=[08ccfb8c-6ae7-4059-8d8a-71a34918bf36 port:42727, addresses:[/0:0:0:0:0:0:0:1%1, /127.0.0.1]], idle=false, context=DefaultDaemonContext[uid=e819866e-a8a9-405c-9c63-873bc154d95f,javaHome=/usr/java/jdk1.7.0_67,daemonRegistryDir=/home/ec2-user/.gradle/daemon,pid=1390,idleTimeout=120000,daemonOpts=-XX:MaxPermSize=400m,-XX:+HeapDumpOnOutOfMemoryError,-Xmx800m,-Dfile.encoding=UTF-8,-Duser.country=US,-Duser.language=en,-Duser.variant]} (build should be starting).
The client will now receive all logging from the daemon (pid: 1390). The daemon log file: /home/ec2-user/.gradle/daemon/2.8/daemon-1390.out.log
Executing build with daemon context: DefaultDaemonContext[uid=e819866e-a8a9-405c-9c63-873bc154d95f,javaHome=/usr/java/jdk1.7.0_67,daemonRegistryDir=/home/ec2-user/.gradle/daemon,pid=1390,idleTimeout=120000,daemonOpts=-XX:MaxPermSize=400m,-XX:+HeapDumpOnOutOfMemoryError,-Xmx800m,-Dfile.encoding=UTF-8,-Duser.country=US,-Duser.language=en,-Duser.variant]
Starting Build
Settings evaluated using settings file '/master/settings.gradle'.
Projects loaded. Root project using build file '/tmp/build293239726091506034xxx/Launch/build.gradle'.
Included projects: [root project 'Launch']
Evaluating root project 'Launch' using build file '/tmp/build293239726091506034xxx/Launch/build.gradle'.
Compiling build file '/tmp/build293239726091506034xxx/Launch/build.gradle' using SubsetScriptTransformer.
Compiling build file '/tmp/build293239726091506034xxx/Launch/build.gradle' using BuildScriptTransformer.
Creating configuration compile.
Creating configuration apk.
Creating configuration provided.
Creating configuration wearApp.
Creating configuration androidTestCompile.
Creating configuration androidTestApk.
Creating configuration androidTestProvided.
Creating configuration androidTestWearApp.
Creating configuration testCompile.
Creating configuration testApk.
Creating configuration testProvided.
Creating configuration testWearApp.
Creating configuration debugCompile.
Creating configuration debugApk.
Creating configuration debugProvided.
Creating configuration debugWearApp.
Creating configuration testDebugCompile.
Creating configuration testDebugApk.
Creating configuration testDebugProvided.
Creating configuration testDebugWearApp.
Creating configuration releaseCompile.
Creating configuration releaseApk.
Creating configuration releaseProvided.
Creating configuration releaseWearApp.
Creating configuration testReleaseCompile.
Creating configuration testReleaseApk.
Creating configuration testReleaseProvided.
Creating configuration testReleaseWearApp.
All projects evaluated.
Selected primary task 'assembleDebug' from project :
file or directory '/tmp/build293239726091506034xxx/Launch/build/intermediates/pre-dexed/debug', not found
Tasks to be executed: [task ':preBuild', task ':preDebugBuild', task ':checkDebugManifest', task ':preReleaseBuild', task ':prepareComGoogleAndroidGmsPlayServices6587Library', task ':prepareDebugDependencies', task ':compileDebugAidl', task ':compileDebugRenderscript', task ':generateDebugBuildConfig', task ':generateDebugAssets', task ':mergeDebugAssets', task ':generateDebugResValues', task ':generateDebugResources', task ':mergeDebugResources', task ':processDebugManifest', task ':processDebugResources', task ':generateDebugSources', task ':processDebugJavaRes', task ':compileDebugJavaWithJavac', task ':compileDebugNdk', task ':compileDebugSources', task ':preDexDebug', task ':dexDebug', task ':validateDebugSigning', task ':packageDebug', task ':zipalignDebug', task ':assembleDebug']
Creating In-memory cache of /tmp/build293239726091506034xxx/Launch/.gradle/2.8/taskArtifacts/fileHashes.bin: MaxSize{295200}
Creating In-memory cache of /tmp/build293239726091506034xxx/Launch/.gradle/2.8/taskArtifacts/outputFileStates.bin: MaxSize{2200}
Creating In-memory cache of /tmp/build293239726091506034xxx/Launch/.gradle/2.8/taskArtifacts/fileSnapshots.bin: MaxSize{7300}
Creating In-memory cache of /tmp/build293239726091506034xxx/Launch/.gradle/2.8/taskArtifacts/taskArtifacts.bin: MaxSize{1400}
:preBuild (Thread[Daemon worker,5,main]) started.
:preBuild
Skipping task ':preBuild' as it has no actions.
:preBuild UP-TO-DATE
:preBuild (Thread[Daemon worker,5,main]) completed. Took 0.074 secs.
:preDebugBuild (Thread[Daemon worker,5,main]) started.
:preDebugBuild
Skipping task ':preDebugBuild' as it has no actions.
:preDebugBuild UP-TO-DATE
:preDebugBuild (Thread[Daemon worker,5,main]) completed. Took 0.002 secs.
:checkDebugManifest (Thread[Daemon worker,5,main]) started.
:checkDebugManifest
Executing task ':checkDebugManifest' (up-to-date check took 0.001 secs) due to:
Task has not declared any outputs.
:checkDebugManifest (Thread[Daemon worker,5,main]) completed. Took 0.006 secs.
:preReleaseBuild (Thread[Daemon worker,5,main]) started.
:preReleaseBuild
Skipping task ':preReleaseBuild' as it has no actions.
:preReleaseBuild UP-TO-DATE
:preReleaseBuild (Thread[Daemon worker,5,main]) completed. Took 0.002 secs.
:prepareComGoogleAndroidGmsPlayServices6587Library (Thread[Daemon worker,5,main]) started.
:prepareComGoogleAndroidGmsPlayServices6587Library
Invalidating in-memory cache of /tmp/build293239726091506034xxx/Launch/.gradle/2.8/taskArtifacts/taskArtifacts.bin
Invalidating in-memory cache of /tmp/build293239726091506034xxx/Launch/.gradle/2.8/taskArtifacts/fileSnapshots.bin
Invalidating in-memory cache of /tmp/build293239726091506034xxx/Launch/.gradle/2.8/taskArtifacts/fileHashes.bin
Invalidating in-memory cache of /tmp/build293239726091506034xxx/Launch/.gradle/2.8/taskArtifacts/outputFileStates.bin
Executing task ':prepareComGoogleAndroidGmsPlayServices6587Library' (up-to-date check took 0.078 secs) due to:
No history is available.
:prepareComGoogleAndroidGmsPlayServices6587Library (Thread[Daemon worker,5,main]) completed. Took 1.48 secs.
:prepareDebugDependencies (Thread[Daemon worker,5,main]) started.
:prepareDebugDependencies
Executing task ':prepareDebugDependencies' (up-to-date check took 0.0 secs) due to:
Task has not declared any outputs.
:prepareDebugDependencies (Thread[Daemon worker,5,main]) completed. Took 0.011 secs.
:compileDebugAidl (Thread[Daemon worker,5,main]) started.
:compileDebugAidl
Executing task ':compileDebugAidl' (up-to-date check took 0.222 secs) due to:
No history is available.
All input files are considered out-of-date for incremental task ':compileDebugAidl'.
deleteDir(/tmp/build293239726091506034xxx/Launch/build/generated/source/aidl/debug) returned: true
:compileDebugAidl (Thread[Daemon worker,5,main]) completed. Took 0.332 secs.
:compileDebugRenderscript (Thread[Daemon worker,5,main]) started.
:compileDebugRenderscript
Executing task ':compileDebugRenderscript' (up-to-date check took 0.005 secs) due to:
No history is available.
deleteDir(/tmp/build293239726091506034xxx/Launch/build/generated/source/rs/debug) returned: true
deleteDir(/tmp/build293239726091506034xxx/Launch/build/generated/res/rs/debug) returned: true
deleteDir(/tmp/build293239726091506034xxx/Launch/build/intermediates/rs/debug/obj) returned: true
deleteDir(/tmp/build293239726091506034xxx/Launch/build/intermediates/rs/debug/lib) returned: true
:compileDebugRenderscript (Thread[Daemon worker,5,main]) completed. Took 0.091 secs.
:generateDebugBuildConfig (Thread[Daemon worker,5,main]) started.
:generateDebugBuildConfig
Executing task ':generateDebugBuildConfig' (up-to-date check took 0.01 secs) due to:
No history is available.
deleteDir(/tmp/build293239726091506034xxx/Launch/build/generated/source/buildConfig/debug) returned: true
:generateDebugBuildConfig (Thread[Daemon worker,5,main]) completed. Took 0.237 secs.
:generateDebugAssets (Thread[Daemon worker,5,main]) started.
:generateDebugAssets
Skipping task ':generateDebugAssets' as it has no actions.
:generateDebugAssets UP-TO-DATE
:generateDebugAssets (Thread[Daemon worker,5,main]) completed. Took 0.001 secs.
:mergeDebugAssets (Thread[Daemon worker,5,main]) started.
:mergeDebugAssets
Executing task ':mergeDebugAssets' (up-to-date check took 1.325 secs) due to:
No history is available.
All input files are considered out-of-date for incremental task ':mergeDebugAssets'.
Unable do incremental execution: full task run
deleteDir(/tmp/build293239726091506034xxx/Launch/build/intermediates/assets/debug) returned: true
:mergeDebugAssets (Thread[Daemon worker,5,main]) completed. Took 1.953 secs.
:generateDebugResValues (Thread[Daemon worker,5,main]) started.
:generateDebugResValues
Executing task ':generateDebugResValues' (up-to-date check took 0.002 secs) due to:
No history is available.
:generateDebugResValues (Thread[Daemon worker,5,main]) completed. Took 0.007 secs.
:generateDebugResources (Thread[Daemon worker,5,main]) started.
:generateDebugResources
Skipping task ':generateDebugResources' as it has no actions.
:generateDebugResources (Thread[Daemon worker,5,main]) completed. Took 0.002 secs.
:mergeDebugResources (Thread[Daemon worker,5,main]) started.
:mergeDebugResources
Executing task ':mergeDebugResources' (up-to-date check took 0.033 secs) due to:
No history is available.
All input files are considered out-of-date for incremental task ':mergeDebugResources'.
Unable do incremental execution: full task run
deleteDir(/tmp/build293239726091506034xxx/Launch/build/intermediates/res/merged/debug) returned: true
QueuedCruncher is using /home/ec2-user/android-sdk/build-tools/23.0.1/aapt
Slave 810739629 is ready
Slave 36440253 is ready
Slave 314541400 is ready
Slave 1882899698 is ready
Slave 803616854 is ready
Slave 1296710841 is ready
Slave 1155054931 is ready
Slave 1035045486 is ready
Slave 1504678832 is ready
Slave 1403179285 is ready
Slave 1716315288 is ready
Slave 1177669669 is ready
Slave 1046922944 is ready
Slave 1300399937 is ready
Slave 880665640 is ready
Slave 890116356 is ready
Slave 1413678052 is ready
Slave 2075433203 is ready
Slave 814510290 is ready
Slave 1575615903 is ready
:mergeDebugResources (Thread[Daemon worker,5,main]) completed. Took 2.038 secs.
:processDebugManifest (Thread[Daemon worker,5,main]) started.
:processDebugManifest
Executing task ':processDebugManifest' (up-to-date check took 0.004 secs) due to:
No history is available.
All input files are considered out-of-date for incremental task ':processDebugManifest'.
Loading library manifest /tmp/build293239726091506034xxx/Launch/build/intermediates/exploded-aar/com.google.android.gms/play-services/6.5.87/AndroidManifest.xml
Merging main manifest /tmp/build293239726091506034xxx/Launch/src/main/AndroidManifest.xml
Merging library manifest /tmp/build293239726091506034xxx/Launch/build/intermediates/exploded-aar/com.google.android.gms/play-services/6.5.87/AndroidManifest.xml
Merging manifest with lower [com.google.android.gms:play-services:6.5.87] AndroidManifest.xml:16:1-26:12
Merging uses-sdk with lower [com.google.android.gms:play-services:6.5.87] AndroidManifest.xml:18:5-42
Merging application with lower [com.google.android.gms:play-services:6.5.87] AndroidManifest.xml:20:5-24:19
Merging meta-data#com.google.android.gms.version with lower [com.google.android.gms:play-services:6.5.87] AndroidManifest.xml:21:9-23:69
Merging result:SUCCESS
Merged manifest saved to /tmp/build293239726091506034xxx/Launch/build/intermediates/manifests/full/debug/AndroidManifest.xml
:processDebugManifest (Thread[Daemon worker,5,main]) completed. Took 0.245 secs.
:processDebugResources (Thread[Daemon worker,5,main]) started.
:processDebugResources
Executing task ':processDebugResources' (up-to-date check took 0.113 secs) due to:
No history is available.
All input files are considered out-of-date for incremental task ':processDebugResources'.
deleteDir(/tmp/build293239726091506034xxx/Launch/build/generated/source/r/debug) returned: true
Starting process 'command '/home/ec2-user/android-sdk/build-tools/23.0.1/aapt''. Working directory: /tmp/build293239726091506034xxx/Launch Command: /home/ec2-user/android-sdk/build-tools/23.0.1/aapt package -f --no-crunch -I /home/ec2-user/android-sdk/platforms/android-21/android.jar -M /tmp/build293239726091506034xxx/Launch/build/intermediates/manifests/full/debug/AndroidManifest.xml -S /tmp/build293239726091506034xxx/Launch/build/intermediates/res/merged/debug -A /tmp/build293239726091506034xxx/Launch/build/intermediates/assets/debug -m -J /tmp/build293239726091506034xxx/Launch/build/generated/source/r/debug -F /tmp/build293239726091506034xxx/Launch/build/intermediates/res/resources-debug.ap_ --debug-mode --custom-package com.boardspace -0 apk --output-text-symbols /tmp/build293239726091506034xxx/Launch/build/intermediates/symbols/debug
Successfully started process 'command '/home/ec2-user/android-sdk/build-tools/23.0.1/aapt''
:processDebugResources (Thread[Daemon worker,5,main]) completed. Took 2.364 secs.
:generateDebugSources (Thread[Daemon worker,5,main]) started.
:generateDebugSources
Skipping task ':generateDebugSources' as it has no actions.
:generateDebugSources (Thread[Daemon worker,5,main]) completed. Took 0.002 secs.
:processDebugJavaRes (Thread[Daemon worker,5,main]) started.
:processDebugJavaRes
Skipping task ':processDebugJavaRes' as it has no source files.
:processDebugJavaRes UP-TO-DATE
:processDebugJavaRes (Thread[Daemon worker,5,main]) completed. Took 0.002 secs.
:compileDebugJavaWithJavac (Thread[Daemon worker,5,main]) started.
:compileDebugJavaWithJavac
Executing task ':compileDebugJavaWithJavac' (up-to-date check took 0.328 secs) due to:
No history is available.
All input files are considered out-of-date for incremental task ':compileDebugJavaWithJavac'.
Compiling with JDK Java compiler API.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
:compileDebugJavaWithJavac (Thread[Daemon worker,5,main]) completed. Took 15.837 secs.
:compileDebugNdk (Thread[Daemon worker,5,main]) started.
:compileDebugNdk
Skipping task ':compileDebugNdk' as it has no source files.
:compileDebugNdk UP-TO-DATE
:compileDebugNdk (Thread[Daemon worker,5,main]) completed. Took 0.002 secs.
:compileDebugSources (Thread[Daemon worker,5,main]) started.
:compileDebugSources
Skipping task ':compileDebugSources' as it has no actions.
:compileDebugSources (Thread[Daemon worker,5,main]) completed. Took 0.001 secs.
:preDexDebug (Thread[Daemon worker,5,main]) started.
:preDexDebug
Executing task ':preDexDebug' (up-to-date check took 0.002 secs) due to:
No history is available.
All input files are considered out-of-date for incremental task ':preDexDebug'.
deleteDir(/tmp/build293239726091506034xxx/Launch/build/intermediates/pre-dexed/debug) returned: true
Starting process 'command '/usr/java/jdk1.7.0_67/bin/java''. Working directory: /tmp/build293239726091506034xxx/Launch Command: /usr/java/jdk1.7.0_67/bin/java -Xmx2048M -Dfile.encoding=UTF-8 -Duser.country=US -Duser.language=en -Duser.variant -cp /home/ec2-user/android-sdk/build-tools/23.0.1/lib/dx.jar com.android.dx.command.Main --dex --verbose --force-jumbo --num-threads=4 --output /tmp/build293239726091506034xxx/Launch/build/intermediates/pre-dexed/debug/classes-79f191ef872ede889990f8e718771a838fd22a31.jar /tmp/build293239726091506034xxx/Launch/build/intermediates/exploded-aar/com.google.android.gms/play-services/6.5.87/jars/classes.jar
Starting process 'command '/usr/java/jdk1.7.0_67/bin/java''. Working directory: /tmp/build293239726091506034xxx/Launch Command: /usr/java/jdk1.7.0_67/bin/java -Xmx2048M -Dfile.encoding=UTF-8 -Duser.country=US -Duser.language=en -Duser.variant -cp /home/ec2-user/android-sdk/build-tools/23.0.1/lib/dx.jar com.android.dx.command.Main --dex --verbose --force-jumbo --num-threads=4 --output /tmp/build293239726091506034xxx/Launch/build/intermediates/pre-dexed/debug/userClasses-7b684336095d8b090049ac8255b69561a2837a3b.jar /tmp/build293239726091506034xxx/Launch/libs/userClasses.jar
Successfully started process 'command '/usr/java/jdk1.7.0_67/bin/java''
Successfully started process 'command '/usr/java/jdk1.7.0_67/bin/java''
You need better monitoring of your build servers.