Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Moments When Things Go Wrong

Sponsored · Your Podcast. Everywhere. Effortlessly. Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.

Moments When Things Go Wrong

Talk by Aurimas Liutikas at KotlinConf 2026

Avatar for Aurimas Liutikas

Aurimas Liutikas

May 22, 2026

More Decks by Aurimas Liutikas

Other Decks in Programming

Transcript

  1. Why listen to me? 🤔 Hate broken things 14 years

    @ Google working on OSS 10 years on AndroidX
  2. Why listen to me? 🤔 Hate broken things 14 years

    @ Google working on OSS 10 years on AndroidX Regularly test pre-release Gradle and KGP catching issues before they ship to you
  3. Why listen to me? 🤔 Hate broken things 14 years

    @ Google working on OSS 10 years on AndroidX Regularly test pre-release Gradle and KGP catching issues before they ship to you 130 issues reported on Gradle issue tracker 77 issues reported on YouTrack
  4. Why care about things going wrong? Blocker for progress 🛑

    Distraction / wasted engineering time / LLM token cost 💰🔥
  5. Why care about things going wrong? Blocker for progress 🛑

    Distraction / wasted engineering time / LLM token cost 💰🔥 Training to ignore issues 🫣
  6. Why care about things going wrong? Blocker for progress 🛑

    Distraction / wasted engineering time / LLM token cost 💰🔥 Training to ignore issues 🫣 Corrupted product / false confidence in output quality 💔
  7. How to know things went wrong? Unexpected logs Unexpected artifact

    contents Unexpectedly slow Non-deterministic behavior
  8. Flaky build failure > Task :sqlite:sqlite-framework:commonizeCInterop Exception in thread "main"

    java.lang.IllegalStateException: Unresolved classifier: platform/linux/va_list at org.jetbrains.kotlin.commonizer.metadata.CirTypeAliasExpansion$Companion.cre ate(CirTypeAliasExpander.kt:183) at org.jetbrains.kotlin.commonizer.metadata.CirDeserializers.type(CirDeserializ ers.kt:348) at org.jetbrains.kotlin.commonizer.metadata.CirDeserializers.valueParameter(Cir Deserializers.kt:180) ...
  9. Caused by: org.gradle.process.ProcessExecutionException: Process 'command '/mnt/disks/build-disk/src/android/androidx-main/prebuilts/jdk/jdk21/linux-x86/bin/java'' finished with non-zero exit

    value 1 at org.gradle.process.internal.DefaultExecHandle$ExecResultImpl.assertNormalExitValue(DefaultExecHandle.java:450) at org.gradle.process.internal.DefaultJavaExecAction.execute(DefaultJavaExecAction.java:58) at org.gradle.process.internal.DefaultExecActionFactory.javaexec(DefaultExecActionFactory.java:209) at org.gradle.process.internal.DefaultExecOperations.javaexec(DefaultExecOperations.java:42) at org.jetbrains.kotlin.internal.compilerRunner.native.KotlinNativeToolRunner.runViaExec(KotlinNativeToolRunner.kt:117) at org.jetbrains.kotlin.internal.compilerRunner.native.KotlinNativeToolRunner.runTool(KotlinNativeToolRunner.kt:70) at org.jetbrains.kotlin.compilerRunner.GradleCliCommonizerKt$GradleCliCommonizer$1.invoke(GradleCliCommonizer.kt:39) at org.jetbrains.kotlin.commonizer.CliCommonizer.commonizeLibraries(CliCommonizer.kt:49) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask.commonize(CInteropCommonizerTask.kt:244) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask.access$commonize(CInteropCommonizerTask.kt:50) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask$commonizeCInteropLibraries$1.invoke(CInteropCommonizerTask.kt:231) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask$commonizeCInteropLibraries$1.invoke(CInteropCommonizerTask.kt:230) at org.jetbrains.kotlin.compilerRunner.ReportUtilsKt.addBuildMetricsForTaskAction(reportUtils.kt:283) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask.commonizeCInteropLibraries(CInteropCommonizerTask.kt:230) at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:125) at org.gradle.api.internal.project.taskfactory.StandardTaskAction.doExecute(StandardTaskAction.java:58)
  10. Caused by: org.gradle.process.ProcessExecutionException: Process 'command '/mnt/disks/build-disk/src/android/androidx-main/prebuilts/jdk/jdk21/linux-x86/bin/java'' finished with non-zero exit

    value 1 at org.gradle.process.internal.DefaultExecHandle$ExecResultImpl.assertNormalExitValue(DefaultExecHandle.java:450) at org.gradle.process.internal.DefaultJavaExecAction.execute(DefaultJavaExecAction.java:58) at org.gradle.process.internal.DefaultExecActionFactory.javaexec(DefaultExecActionFactory.java:209) at org.gradle.process.internal.DefaultExecOperations.javaexec(DefaultExecOperations.java:42) at org.jetbrains.kotlin.internal.compilerRunner.native.KotlinNativeToolRunner.runViaExec(KotlinNativeToolRunner.kt:117) at org.jetbrains.kotlin.internal.compilerRunner.native.KotlinNativeToolRunner.runTool(KotlinNativeToolRunner.kt:70) at org.jetbrains.kotlin.compilerRunner.GradleCliCommonizerKt$GradleCliCommonizer$1.invoke(GradleCliCommonizer.kt:39) at org.jetbrains.kotlin.commonizer.CliCommonizer.commonizeLibraries(CliCommonizer.kt:49) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask.commonize(CInteropCommonizerTask.kt:244) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask.access$commonize(CInteropCommonizerTask.kt:50) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask$commonizeCInteropLibraries$1.invoke(CInteropCommonizerTask.kt:231) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask$commonizeCInteropLibraries$1.invoke(CInteropCommonizerTask.kt:230) at org.jetbrains.kotlin.compilerRunner.ReportUtilsKt.addBuildMetricsForTaskAction(reportUtils.kt:283) at org.jetbrains.kotlin.gradle.targets.native.internal.CInteropCommonizerTask.commonizeCInteropLibraries(CInteropCommonizerTask.kt:230) at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:125) at org.gradle.api.internal.project.taskfactory.StandardTaskAction.doExecute(StandardTaskAction.java:58) CInteropCommonizerTask.commonize(CInteropCommonizerTask.kt:244)
  11. Tool to query failed builds Mock of an Internal Tool

    Unresolved classifier: platform/ Search Last 365 days Time range aosp-androidx-main Branch * Target Count 2 4 6 8 Build type Branch Target Link Creation time Time Presubmit aosp-androidx-main androidx ab/1234 20251216 2229 Presubmit aosp-androidx-main androidx ab/1236 20251216 2223
  12. Running locally Looking at :sqlite:sqlite-framework:commonizeCInterop inputs we find commonizerDependenciesClasspath assume

    that to get platform/linux/va_list we use ~/.konan/kotlin-native-prebuilt-linux-x86_64-2.3.0/klib/ platform/linux_x64/org.jetbrains.kotlin.native.platform.linux
  13. Forcing a failure? rm -fr out/.konan/kotlin-native-prebuilt-linux-x86_64-2.3.0/klib/pl atform/linux_arm64/org.jetbrains.kotlin.native.platform.linu x rm -fr

    out/.konan/kotlin-native-prebuilt-linux-x86_64-2.3.0/klib/pl atform/linux_x64/org.jetbrains.kotlin.native.platform.linux ./gradlew :sqlite:sqlite-framework:commonizeCInterop
  14. Forcing a failure? rm -fr out/.konan/kotlin-native-prebuilt-linux-x86_64-2.3.0/klib/pl atform/linux_arm64/org.jetbrains.kotlin.native.platform.linu x rm -fr

    out/.konan/kotlin-native-prebuilt-linux-x86_64-2.3.0/klib/pl atform/linux_x64/org.jetbrains.kotlin.native.platform.linux ./gradlew :sqlite:sqlite-framework:commonizeCInterop Bingo! The same failure stacktrace
  15. Forcing a failure? There are two problems here: Why does

    KGP not put back this missing dependency? It looks like there is missing task output/input tracking
  16. Forcing a failure? There are two problems here: Why does

    KGP not put back this missing dependency? It looks like there is missing task output/input tracking How do we end up in this situation where cinterop task runs but the dependencies are not yet prepared for us?
  17. KotlinNativeDownloadTask build caching is unsafe Workaround: tasks.named { it ==

    "downloadKotlinNativeDistribution" } .configureEach { outputs.cacheIf { false } }
  18. Missing task dependency Workaround: tasks.named { it == "commonizeNativeDistribution" }

    .configureEach { dependsOn("downloadKotlinNativeDistribution") }
  19. Tool to query failed builds Estimate impact Finding failed build

    examples Visualize occurrences by time Which build targets are affected
  20. Creating reproduction projects Start with empty project and add (preferred,

    not always possible) vs Start with full project and reduce (only doable for open source projects)
  21. [KOTLIN] [IC] Incremental compilation was attempted but failed: Failed to

    compute files to recompile: java.lang.IllegalStateException: The following FqNames can't be derived from DirtyData.dirtyLookupSymbols: androidx.compose.ui.text.style.TextDecoration. DirtyData = DirtyData(dirtyLookupSymbols=[LookupSymbol(name=hashCode, scope=kotlinx.coroutines.channels.ChannelResult), LookupSymbol(... at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.toProgramSymbols(ClasspathChangesComputer.kt:364) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeFineGrainedKotlinClassChanges(ClasspathChangesComputer.kt:264) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeKotlinClassChanges(ClasspathChangesComputer.kt:164) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeClassChanges(ClasspathChangesComputer.kt:137) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeChangedAndImpactedSet(ClasspathChangesComputer.kt:87) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeClasspathChanges(ClasspathChangesComputer.kt:55) at org.jetbrains.kotlin.incremental.dirtyFiles.ClasspathSnapshotBasedImpactDeterminer.determineChangedAndImpactedSymbols(ClasspathSnapshotBasedImpact Determiner.kt:42) at org.jetbrains.kotlin.incremental.dirtyFiles.JvmSourcesToCompileCalculator.calculateSourcesToCompileImpl(JvmSourcesToCompileCalculator.kt:41) at org.jetbrains.kotlin.incremental.dirtyFiles.JvmSourcesToCompileCalculator.calculateWithClasspathSnapshot(JvmSourcesToCompileCalculator.kt:97) at org.jetbrains.kotlin.incremental.IncrementalJvmCompilerRunner.calculateSourcesToCompile(IncrementalJvmCompilerRunner.kt:60)
  22. [KOTLIN] [IC] Incremental compilation was attempted but failed: Failed to

    compute files to recompile: java.lang.IllegalStateException: The following FqNames can't be derived from DirtyData.dirtyLookupSymbols: androidx.compose.ui.text.style.TextDecoration. DirtyData = DirtyData(dirtyLookupSymbols=[LookupSymbol(name=hashCode, scope=kotlinx.coroutines.channels.ChannelResult), LookupSymbol(... at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.toProgramSymbols(ClasspathChangesComputer.kt:364) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeFineGrainedKotlinClassChanges(ClasspathChangesComputer.kt:264) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeKotlinClassChanges(ClasspathChangesComputer.kt:164) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeClassChanges(ClasspathChangesComputer.kt:137) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeChangedAndImpactedSet(ClasspathChangesComputer.kt:87) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeClasspathChanges(ClasspathChangesComputer.kt:55) at org.jetbrains.kotlin.incremental.dirtyFiles.ClasspathSnapshotBasedImpactDeterminer.determineChangedAndImpactedSymbols(ClasspathSnapshotBasedImpact Determiner.kt:42) at org.jetbrains.kotlin.incremental.dirtyFiles.JvmSourcesToCompileCalculator.calculateSourcesToCompileImpl(JvmSourcesToCompileCalculator.kt:41) at org.jetbrains.kotlin.incremental.dirtyFiles.JvmSourcesToCompileCalculator.calculateWithClasspathSnapshot(JvmSourcesToCompileCalculator.kt:97) at org.jetbrains.kotlin.incremental.IncrementalJvmCompilerRunner.calculateSourcesToCompile(IncrementalJvmCompilerRunner.kt:60) Failed to compute files to recompile: java.lang.IllegalStateException: The following FqNames can't be derived from DirtyData.dirtyLookupSymbols: androidx.compose.ui.text.style.TextDecoration.
  23. What do we know? Mock of an Internal Tool The

    following fqNames canʼt be Search Last 720 days Time range aosp-androidx-main Branch * Target Count 2 4 6 8 July 2024 April 2026
  24. What do we know? Relatively low frequency Only happens on

    incremental builders Gradle exits with success, but the log is printed out
  25. Time cost dilemma Cost of investigating the issue vs Cost

    of wasted time in retries, nuisance to developers
  26. Attempt to reproduce it rm -fr compose/material3/material3/material3-samples/build/ git co aosp/androidx-main

    ./gradlew :compose:material3:material3:material3-samples:compileReleaseKotlin --no-build-cache git co testincremental ./gradlew :compose:material3:material3:material3-samples:compileReleaseKotlin --no-build-cache
  27. Attempt to reproduce it rm -fr compose/material3/material3/material3-samples/build/ git co aosp/androidx-main

    ./gradlew :compose:material3:material3:material3-samples:compileReleaseKotlin --no-build-cache git co testincremental ./gradlew :compose:material3:material3:material3-samples:compileReleaseKotlin --no-build-cache BINGO! [KOTLIN] [IC] Incremental compilation was attempted but failed: Failed to compute files to recompile: java.lang.IllegalStateException: The following FqNames can't be derived from DirtyData.dirtyLookupSymbols:
  28. Kotlin Gradle Plugin Self-Recovery Falling back to non-incremental compilation (reason

    = IC_FAILED_TO_COMPUTE_FILES_TO_RECOMPILE) To help us fix this issue, please file a bug at https://youtrack.jetbrains.com/issues/KT with the above stack trace. (Be sure to search for the above exception in existing issues first to avoid filing duplicated bugs.)
  29. Kotlin Gradle Plugin Self-Recovery Falling back to non-incremental compilation (reason

    = IC_FAILED_TO_COMPUTE_FILES_TO_RECOMPILE) To help us fix this issue, please file a bug at https://youtrack.jetbrains.com/issues/KT with the above stack trace. (Be sure to search for the above exception in existing issues first to avoid filing duplicated bugs.) 🆕 youtrack.jetbrains.com/issue/KT84271
  30. project vs maven coordinates Lowest version of a dependency that

    has all required APIs Sometimes bleeding edge APIs are needed implementation("androidx.foo:foo:1.0.0") ↓ implementation(project(":foo:foo"))
  31. Gradle build logs are chatty Gradle output can be very

    verbose (especially with --stacktrace) A needle in the haystack for the important messages
  32. 20260504 184436.212270  Task :wear:compose:compose-material3-macrobenchmark-target:checkReleaseAarMetadata UPTODATE 20260504 184436.212272  Task

    :wear:compose:compose-foundation:compileReleaseLibraryResources UPTODATE 20260504 184436.212274  Task :wear:compose:compose-material3:extractDeepLinksRelease UPTODATE 20260504 184436.212276  Task :wear:compose:compose-material-core:extractDeepLinksRelease UPTODATE 20260504 184436.212278  Task :wear:compose:compose-material3-integration-tests:extractDeepLinksRelease UPTODATE 20260504 184436.212280  Task :wear:compose:compose-material:extractDeepLinksRelease UPTODATE 20260504 184436.212282  Task :wear:compose:compose-material3-macrobenchmark-target:extractDeepLinksRelease UPTODATE 20260504 184436.212284  Task :wear:compose:compose-material3-macrobenchmark-common:extractDeepLinksRelease UPTODATE 20260504 184436.212286  Task :viewpager2:integration-tests:testapp:generateDebugUnitTestLintModel UPTODATE 20260504 184436.212288  Task :wear:compose:compose-material3-macrobenchmark-common:compileReleaseLibraryResources UPTODATE 20260504 184436.212291  Task :tv:integration-tests:playground:generateDebugAndroidTestLintModel 20260504 184436.212293  Task :wear:compose:compose-material3:generateReleaseAndroidTestLintModel 20260504 184436.212295  Task :wear:compose:compose-material3:compileReleaseLibraryResources UPTODATE 20260504 184436.212297  Task :wear:compose:integration-tests:demos:common:packageReleaseResources UPTODATE 20260504 184436.212298  Task :wear:compose:compose-material3-macrobenchmark-target:mergeReleaseJniLibFolders UPTODATE 20260504 184436.212300  Task :wear:compose:compose-material3-integration-tests:compileReleaseLibraryResources UPTODATE 20260504 184436.212306  Task :wear:compose:compose-material3-macrobenchmark-target:generateReleaseAssets UPTODATE 20260504 184436.212309  Task :wear:compose:compose-material:compileReleaseLibraryResources UPTODATE 20260504 184436.212310  Task :wear:compose:compose-material-core:compileReleaseLibraryResources UPTODATE 20260504 184436.212312  Task :wear:compose:compose-foundation-benchmark:lintAnalyzeReleaseAndroidTest FROMCACHE 20260504 184436.212314  Task :viewpager2:integration-tests:testapp:lintAnalyzeDebugUnitTest UPTODATE 20260504 184436.212316  Task :wear:compose:compose-material3-samples:extractDeepLinksRelease UPTODATE 20260504 184436.212318  Task :tv:integration-tests:playground:generateDebugUnitTestLintModel 20260504 184436.212320  Task :wear:compose:integration-tests:demos:common:extractDeepLinksRelease UPTODATE 20260504 184436.212322  Task :tv:integration-tests:playground:generateDebugLintReportModel 20260504 184436.212324  Task :wear:compose:compose-ui-tooling:extractDeepLinksRelease UPTODATE 20260504 184436.212326  Task :wear:compose:compose-navigation:extractDeepLinksRelease UPTODATE 20260504 184436.212328  Task :wear:compose:compose-navigation:lintAnalyzeReleaseAndroidTest FROMCACHE 20260504 184436.212333  Task :tv:integration-tests:macrobenchmark-target:optimizeReleaseResources UPTODATE 20260504 184436.212335  Task :tv:integration-tests:macrobenchmark-target:compileReleaseArtProfile UPTODATE 20260504 184436.212339  Task :wear:compose:compose-material3-macrobenchmark-target:preDebugBuild UPTODATE 20260504 184436.212343  Task :wear:compose:compose-material3-macrobenchmark-target:extractProguardFiles UPTODATE 20260504 184436.212369  Task :wear:compose:compose-ui-tooling:mapReleaseSourceSetPaths UPTODATE 20260504 184436.212371  Task :wear:compose:integration-tests:demos:common:parseReleaseLocalResources UPTODATE 20260504 184436.212373  Task :wear:compose:compose-material-benchmark:generateReleaseAndroidTestLintModel 20260504 184436.212375  Task :wear:compose:integration-tests:demos:common:mapReleaseSourceSetPaths UPTODATE 20260504 184436.212379  Task :wear:compose:compose-material3-macrobenchmark-target:extractReleaseVersionControlInfo UPTODATE 20260504 184436.212405  Task :wear:compose:compose-navigation:mapReleaseSourceSetPaths UPTODATE 20260504 184436.212408  Task :wear:compose:compose-material3-benchmark:generateReleaseUnitTestLintModel UPTODATE
  33. 20260504 184436.212410  Task :wear:compose:compose-material3-macrobenchmark-target:preDebugAndroidTestBuild SKIPPED 20260504 184436.212412  Task

    :wear:compose:compose-material3-benchmark:lintAnalyzeReleaseUnitTest UPTODATE 20260504 184436.212446  Task :wear:compose:compose-material3-macrobenchmark-target:preDebugUnitTestBuild UPTODATE 20260504 184436.212448  Task :wear:compose:compose-material3-samples:assembleRelease UPTODATE 20260504 184436.212450  Task :wear:compose:compose-material3-macrobenchmark-target:validateSigningRelease UPTODATE 20260504 184436.212452  Task :wear:compose:compose-material3-samples:mapReleaseSourceSetPaths UPTODATE 20260504 184436.212810 20260504 184436.212824  Task :pdf:pdf-viewer:generateApi 20260504 184436.212828 src/main/kotlin/androidx/pdf/annotation/models/PdfAnnotation.kt:30: error: Parcelable requires a `CREATOR` field; missing in androidx.pdf.annotation.models.PdfAnnotation ParcelCreator] 20260504 184436.212831 src/main/kotlin/androidx/pdf/annotation/models/PdfAnnotation.kt:30: error: Parcelable classes must be final: androidx.pdf.annotation.models.PdfAnnotation is not final ParcelNotFinal] 20260504 184436.212834 20260504 184436.212836 Your change has API lint issues. Fix the code according to the messages above. 20260504 184436.212838 20260504 184436.212841 If a check is broken, suppress it in code in Kotlin with Suppress("id")/@get:Suppress("id") 20260504 184436.212843 and in Java with SuppressWarnings("id") and file bug to 20260504 184436.212846 https://issuetracker.google.com/issues/new?component=739152&template=1344623 20260504 184436.212848 20260504 184436.212850 If you are doing a refactoring or suppression above does not work, use ./gradlew updateApiLintBaseline 20260504 184436.212872 20260504 184436.311075 20260504 184436.311104  Task :pdf:pdf-viewer:generateApi FAILED 20260504 184436.311145  Task :wear:compose:compose-material3-samples:createLibraryBuildInfoFilesAnchor 20260504 184436.311149  Task :wear:compose:compose-material3-macrobenchmark:processReleaseNavigationResources UPTODATE 20260504 184436.311166  Task :wear:compose:compose-material3-macrobenchmark-target:processReleaseNavigationResources UPTODATE 20260504 184436.311179  Task :wear:compose:compose-material3-macrobenchmark-target:mergeReleaseStartupProfile UPTODATE 20260504 184436.311182  Task :wear:compose:compose-material3-macrobenchmark-target:writeReleaseSigningConfigVersions UPTODATE 20260504 184436.311224  Task :wear:compose:compose-material3-macrobenchmark-target:writeReleaseAppMetadata UPTODATE 20260504 184436.311228  Task :tv:integration-tests:playground:mergeReleaseJavaResource UPTODATE 20260504 184436.311230  Task :wear:compose:compose-material3-macrobenchmark-target:checkDocsTipOfTree UPTODATE 20260504 184436.311235  Task :wear:compose:compose-material3:lintAnalyzeReleaseAndroidTest FROMCACHE 20260504 184436.311252  Task :wear:compose:compose-material3-macrobenchmark-target:generateDebugResources UPTODATE
  34. 20260504 184436.311255  Task :viewpager2:integration-tests:testapp:lintReportDebug UPTODATE 20260504 184436.311257  Task

    :wear:compose:compose-material3-macrobenchmark-target:mergeReleaseArtProfile UPTODATE 20260504 184436.311272  Task :tv:integration-tests:playground:lintAnalyzeDebugUnitTest FROMCACHE 20260504 184436.311284  Task :wear:compose:compose-material3-benchmark:generateReleaseAndroidTestLintModel 20260504 184436.311287  Task :tv:integration-tests:playground:lintAnalyzeDebugAndroidTest FROMCACHE 20260504 184436.311298  Task :wear:compose:compose-material3-macrobenchmark-target:javaPreCompileDebug UPTODATE 20260504 184436.311300  Task :wear:compose:compose-material3-macrobenchmark-target:mapDebugSourceSetPaths UPTODATE 20260504 184436.311309  Task :wear:compose:compose-material3-macrobenchmark-target:processDebugNavigationResources UPTODATE 20260504 184436.311312  Task :wear:compose:compose-material3-macrobenchmark-target:checkDebugAarMetadata UPTODATE 20260504 184436.311328  Task :wear:compose:compose-ui-tooling:compileReleaseLibraryResources UPTODATE 20260504 184436.311330  Task :wear:compose:compose-material3-macrobenchmark-target:extractDeepLinksDebug UPTODATE 20260504 184436.311371  Task :wear:compose:compose-material3-macrobenchmark-target:createDebugCompatibleScreenManifests UPTODATE 20260504 184436.311374  Task :wear:compose:compose-material3-macrobenchmark-target:ktCheck UPTODATE 20260504 184436.311380  Task :wear:compose:compose-material3-samples:checkKotlinApiTarget UPTODATE 20260504 184436.311382  Task :wear:compose:compose-material-benchmark:lintAnalyzeReleaseAndroidTest FROMCACHE 20260504 184436.311385  Task :wear:compose:compose-material3-samples:checkDocsTipOfTree UPTODATE 20260504 184436.311387  Task :wear:compose:compose-navigation:compileReleaseLibraryResources UPTODATE 20260504 184436.311391  Task :wear:compose:compose-material3-samples:compileReleaseLibraryResources UPTODATE 20260504 184436.311394  Task :wear:compose:compose-material3-samples:ktCheck UPTODATE 20260504 184436.311401  Task :tv:integration-tests:macrobenchmark-target:packageRelease UPTODATE 20260504 184436.311406  Task :wear:compose:integration-tests:demos:common:compileReleaseLibraryResources UPTODATE 20260504 184436.311419  Task :wear:compose:integration-tests:demos:common:generateReleaseRFile UPTODATE 20260504 184436.311421  Task :wear:compose:compose-material3-samples:releaseVerifyELFRegionAlignment NOSOURCE 20260504 184436.311425  Task :wear:compose:compose-material3-samples:runErrorProneRelease NOSOURCE 20260504 184436.311428  Task :wear:compose:compose-material3-macrobenchmark:parseReleaseLocalResources UPTODATE 20260504 184436.311433  Task :wear:compose:compose-material3-macrobenchmark-target:compileReleaseNavigationResources UPTODATE 20260504 184436.311436  Task :wear:compose:compose-material3-macrobenchmark-target:parseReleaseLocalResources UPTODATE 20260504 184436.311447  Task :wear:compose:compose-material3-macrobenchmark-target:mergeReleaseAssets UPTODATE 20260504 184436.311449  Task :wear:compose:compose-material3-samples:generateReleaseLintReportModel UPTODATE 20260504 184436.311453  Task :wear:compose:compose-material3-macrobenchmark-target:mergeReleaseNativeLibs UPTODATE 20260504 184436.311499  Task :wear:compose:compose-material3-benchmark:lintAnalyzeReleaseAndroidTest FROMCACHE 20260504 184436.311510  Task :tv:integration-tests:playground:lintAnalyzeDebug FROMCACHE 20260504 184436.311513  Task :wear:compose:compose-material3-macrobenchmark-target:processReleaseMainManifest UPTODATE
  35. 20260504 184436.511026  Task :wear:compose:compose-material3-macrobenchmark-target:mergeReleaseResources UPTODATE 20260504 184436.611038  Task

    :compose:ui:ui:compileAndroidDeviceTest FROMCACHE 20260504 184436.611064  Task :wear:compose:compose-material-samples:lintReportRelease 20260504 184436.611068  Task :tv:integration-tests:macrobenchmark-target:createReleaseApkListingFileRedirect UPTODATE 20260504 184436.611070  Task :wear:compose:compose-material3-macrobenchmark-target:checkReleaseDuplicateClasses UPTODATE 20260504 184436.611073  Task :graphics:integration-tests:testapp-compose:packageRelease 20260504 184436.611075  Task :graphics:integration-tests:testapp-compose:createReleaseApkListingFileRedirect UPTODATE 20260504 184436.611077  Task :wear:compose:compose-foundation-benchmark:lintReportRelease 20260504 184436.611080  Task :wear:compose:compose-foundation:lintReportRelease 20260504 184436.711036  Task :wear:compose:compose-material:lintReportRelease 20260504 184436.711063  Task :tv:integration-tests:macrobenchmark-target:lintReportDebug 20260504 184437.410979  Task :pdf:integration-tests:testapp:compileDebugKotlin 20260504 184437.411003  Task :pdf:integration-tests:testapp:compileReleaseKotlin 20260504 184437.811032  Task :pdf:pdf-viewer:lintAnalyzeReleaseAndroidTest 20260504 184438.711030  Task :pdf:pdf-viewer:lintAnalyzeReleaseUnitTest 20260504 184438.911056  Task :pdf:pdf-ink:generateApi 20260504 184439.311011  Task :docs-public:zipDocs 20260504 184446.010981  Task :pdf:pdf-viewer:lintAnalyzeRelease 20260504 184446.111027 20260504 184446.111052 FAILURE Build failed with an exception. 20260504 184446.111055 20260504 184446.111058  What went wrong: 20260504 184446.111061 Execution failed for task ':pdf:pdf-viewer:generateApi' (registered by plugin 'com.android.internal.library'). 20260504 184446.111063  A failure occurred while executing androidx.build.metalava.MetalavaWorkAction 20260504 184446.111066 > Process 'command '/mnt/disks/build-disk/src/android/androidx-main/prebuilts/jdk/jdk21/linux-x86/bin/java'' finished with non-zero exit value 255 20260504 184446.111069 20260504 184446.111071  Try: 20260504 184446.111074  Run with --info or --debug option to get more log output. 20260504 184446.111077  Get more help at https://help.gradle.org.
  36. 20260504 184446.111082  Exception is: 20260504 184446.111085 org.gradle.api.tasks.TaskExecutionException: Execution failed

    for task ':pdf:pdf-viewer:generateApi' (registered by plugin 'com.android.internal.library'). 20260504 184446.111088 at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.lambda$executeIfValid$1ExecuteActionsTaskExecuter.java:135 20260504 184446.111098 at org.gradle.internal.Try$Failure.ifSuccessfulOrElse(Try.java:288 20260504 184446.111126 at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeIfValid(ExecuteActionsTaskExecuter.java:133 20260504 184446.111129 at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:121 20260504 184446.111131 at org.gradle.api.internal.tasks.execution.ProblemsTaskPathTrackingTaskExecuter.execute(ProblemsTaskPathTrackingTaskExecuter.java:41 20260504 184446.111134 at org.gradle.api.internal.tasks.execution.ResolveTaskExecutionModeExecuter.execute(ResolveTaskExecutionModeExecuter.java:51 20260504 184446.111136 at org.gradle.api.internal.tasks.execution.FinalizePropertiesTaskExecuter.execute(FinalizePropertiesTaskExecuter.java:46 20260504 184446.111139 at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:57 20260504 184446.111141 at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:74 20260504 184446.111144 at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:36 20260504 184446.111146 at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.executeTask(EventFiringTaskExecuter.java:77 20260504 184446.111149 at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:55 20260504 184446.111151 at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:52 20260504 184446.111153 at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:210 20260504 184446.111156 at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:205 20260504 184446.111158 at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:67 20260504 184446.111161 at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:60 20260504 184446.111163 at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:167 20260504 184446.111165 at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:60 20260504 184446.111168 at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:54 20260504 184446.111170 at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter.execute(EventFiringTaskExecuter.java:52 20260504 184446.111172 at org.gradle.execution.plan.DefaultNodeExecutor.executeLocalTaskNode(DefaultNodeExecutor.java:55 20260504 184446.111175 at org.gradle.execution.plan.DefaultNodeExecutor.execute(DefaultNodeExecutor.java:34 20260504 184446.111177 at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:355 20260504 184446.111180 at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:343
  37. 20260504 184446.111183 at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.lambda$execute$0DefaultTaskExecutionGraph.java:339 20260504 184446.111189 at org.gradle.internal.operations.CurrentBuildOperationRef.with(CurrentBuildOperationRef.java:84 20260504 184446.111191

    at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:339 20260504 184446.111194 at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:328 20260504 184446.111197 at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.execute(DefaultPlanExecutor.java:459 20260504 184446.111199 at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.run(DefaultPlanExecutor.java:376 20260504 184446.111202 at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:64 20260504 184446.111204 at org.gradle.internal.concurrent.AbstractManagedExecutor$1.run(AbstractManagedExecutor.java:47 20260504 184446.111207 Caused by: org.gradle.workers.internal.DefaultWorkerExecutor$WorkExecutionException: A failure occurred while executing androidx.build.metalava.MetalavaWorkAction 20260504 184446.111210 at org.gradle.workers.internal.DefaultWorkerExecutor$WorkItemExecution.waitForCompletion(DefaultWorkerExecutor.java:278 20260504 184446.111212 at org.gradle.internal.work.DefaultAsyncWorkTracker.lambda$waitForItemsAndGatherFailures$2DefaultAsyncWorkTracker.java:132 20260504 184446.111215 at org.gradle.internal.Factories$1.create(Factories.java:30 20260504 184446.111217 at org.gradle.internal.work.DefaultWorkerLeaseService.lambda$withoutLocksBlocking$3DefaultWorkerLeaseService.java:390 20260504 184446.111220 at org.gradle.internal.work.ResourceLockStatistics$1.measure(ResourceLockStatistics.java:43 20260504 184446.111222 at org.gradle.internal.work.DefaultWorkerLeaseService.withoutLocksBlocking(DefaultWorkerLeaseService.java:385 20260504 184446.111225 at org.gradle.internal.work.DefaultWorkerLeaseService.blocking(DefaultWorkerLeaseService.java:239 20260504 184446.111228 at org.gradle.internal.work.DefaultWorkerLeaseService.blocking(DefaultWorkerLeaseService.java:221 20260504 184446.111230 at org.gradle.internal.work.DefaultAsyncWorkTracker.lambda$waitForItemsAndGatherFailures$3DefaultAsyncWorkTracker.java:128 20260504 184446.111232 at org.gradle.internal.Factories$1.create(Factories.java:30 20260504 184446.111235 at org.gradle.internal.resources.AbstractResourceLockRegistry.whileDisallowingLockChanges(AbstractResourceLockRegistry.java:50 20260504 184446.111240 at org.gradle.internal.work.DefaultWorkerLeaseService.whileDisallowingProjectLockChanges(DefaultWorkerLeaseService.java:244 20260504 184446.111243 at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForItemsAndGatherFailures(DefaultAsyncWorkTracker.java:127 20260504 184446.111245 at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForItemsAndGatherFailures(DefaultAsyncWorkTracker.java:93 20260504 184446.111247 at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForAll(DefaultAsyncWorkTracker.java:79 20260504 184446.111250 at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForCompletion(DefaultAsyncWorkTracker.java:67 20260504 184446.111252 at org.gradle.api.internal.tasks.execution.TaskExecution$3.run(TaskExecution.java:267 20260504 184446.111254 at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:30 20260504 184446.111257 at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:27 20260504 184446.111259 at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:67
  38. Interesting log pattern Thousands of lines of logs> Failed task

    logs Hundreds of lines of logs> FAILURE Build failed with an exception. 180+ lines of exception stacktrace> BUILD FAILED in 1m 13s 47292 actionable tasks: 7630 executed, 912 from cache, 38750 up-to-date
  39. > Task :pdf:pdf-viewer:generateApi src/main/kotlin/androidx/pdf/annotation/models/PdfAnnotation.kt:30: error: Parcelable requires a `CREATOR` field;

    missing in androidx.pdf.annotation.models.PdfAnnotation [ParcelCreator] src/main/kotlin/androidx/pdf/annotation/models/PdfAnnotation.kt:30: error: Parcelable classes must be final: androidx.pdf.annotation.models.PdfAnnotation is not final [ParcelNotFinal] Your change has API lint issues. Fix the code according to the messages above. If you are doing a refactoring, use ./gradlew updateApiLintBaseline
  40. Execution failed for task ':pdf:pdf-viewer:generateApi'. > A failure occurred while

    executing androidx.build.metalava.MetalavaWorkAction > Process 'command '$CHECKOUT/prebuilts/jdk/jdk21/linux-x86/bin/java'' finished with non-zero exit value 255 * Exception is: org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':pdf:pdf-viewer:generateApi). Caused by: org.gradle.workers.internal.DefaultWorkerExecutor$WorkExecutionException: A failure occurred while executing androidx.build.metalava.MetalavaWorkAction Caused by: org.gradle.process.ProcessExecutionException: Process 'command '$CHECKOUT/prebuilts/jdk/jdk21/linux-x86/bin/java'' finished with non-zero exit value 255 at androidx.build.metalava.MetalavaWorkAction.execute(MetalavaRunner.kt:106) BUILD FAILED in 1m 13s
  41. Expecting the unexpected For example: Daemon will be stopped at

    the end of the build \[Incubating\] Problems report is available at\:.* [0-9]+ actionable tasks: [0-9]+ executed, [0-9]+ up\-to\-date Configuration cache entry reused\. Configuration cache entry stored\. Configuration on demand is an incubating feature\. Parallel Configuration Cache is an incubating feature\.
  42. [KOTLIN] [IC] Incremental compilation was attempted but failed: Failed to

    compute files to recompile: java.lang.IllegalStateException: The following FqNames can't be derived from DirtyData.dirtyLookupSymbols: androidx.compose.ui.text.style.TextDecoration. DirtyData = DirtyData(dirtyLookupSymbols=[LookupSymbol(name=hashCode, scope=kotlinx.coroutines.channels.ChannelResult), LookupSymbol(... at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.toProgramSymbols(ClasspathChangesComputer.kt:364) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeFineGrainedKotlinClassChanges(ClasspathChangesComputer.kt:264) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeKotlinClassChanges(ClasspathChangesComputer.kt:164) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeClassChanges(ClasspathChangesComputer.kt:137) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeChangedAndImpactedSet(ClasspathChangesComputer.kt:87) at org.jetbrains.kotlin.incremental.classpathDiff.ClasspathChangesComputer.computeClasspathChanges(ClasspathChangesComputer.kt:55) at org.jetbrains.kotlin.incremental.dirtyFiles.ClasspathSnapshotBasedImpactDeterminer.determineChangedAndImpactedSymbols(ClasspathSnapshotBasedImpact Determiner.kt:42) at org.jetbrains.kotlin.incremental.dirtyFiles.JvmSourcesToCompileCalculator.calculateSourcesToCompileImpl(JvmSourcesToCompileCalculator.kt:41) at org.jetbrains.kotlin.incremental.dirtyFiles.JvmSourcesToCompileCalculator.calculateWithClasspathSnapshot(JvmSourcesToCompileCalculator.kt:97) at org.jetbrains.kotlin.incremental.IncrementalJvmCompilerRunner.calculateSourcesToCompile(IncrementalJvmCompilerRunner.kt:60) Failed to compute files to recompile: java.lang.IllegalStateException: The following FqNames can't be derived from DirtyData.dirtyLookupSymbols: androidx.compose.ui.text.style.TextDecoration.
  43. An AndroidX Library Developer Report XXX, YYY, ZZZ started failing

    after the two changes back to back landed at r.android.com/3818967 and r.android.com/3818966. Temporarily disabled a few but surprised they passed presubmit. They all fail locally as reported in fully synced repo.
  44. Figure out the scope Passing locally Reporting in CI Device

    tests ✅ ✅ Host tests on Linux ❌ ❌ Host tests on Mac ✅ ✅
  45. Figure out the timeline Find when test reports stopped, down

    to two changes: - r.android.com/3916953 - r.android.com/3923957
  46. Figure out the timeline Find when test reports stopped, down

    to two changes: - r.android.com/3916953 - r.android.com/3923957
  47. Digging into the build log Unexpectedly found these files generated

    or modified by the build: ./compose/runtime/runtime/core Generated files should go in OUT_DIR instead because that is where developers expect to find them (to make it easier to diagnose build problems: inspect or delete these files) Copied these generated files into /mnt/disks/build-disk/src/android/androidx-main/out/dist/new_files
  48. Unexpected files Build have predictable outputs Regular build should write

    only to build/ directories There should be no modifications of sources or build.gradle.kts There should be no new files
  49. Unexpected files Unexpected files mean something went wrong We wrote

    verify_no_caches_in_source_repo.sh to ensure there are no unexpected new files or modifications to existing ones
  50. Unexpected files Unexpected files mean something went wrong We wrote

    verify_no_caches_in_source_repo.sh to ensure there are no unexpected new files or modifications to existing ones Unexpectedly found these files generated or modified by the build: ./compose/runtime/runtime/core
  51. Unexpectedly found these files In our case, compose/runtime/runtime/core showed that

    Kotlin native tests were crashing the test process org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':compose:runtime:runtime:linuxX64Test'. Caused by: java.lang.Error: Test running process exited unexpectedly. Current test: hostDefault_throwsForMissingNonNullableKey
  52. Why does this break test reporting? busytown/impl/build.sh calls busytown/impl/verify_no_caches_in_source_repo.sh that

    has set -e and exists when files are found with exit 1 This skips our test report processing.
  53. Presubmit failure for PR upgrading to KGP 2.0.0 Ran two

    consecutive builds of the same tasks, and in the second build, observed: task :compose:material:material:compileTestKotlinDesktop not UP-TO-DATE. It was out-of-date because: Value of input property 'friendPathsSet$kotlin_gradle_plugin_common' has changed for task ':compose:material:material:compileTestKotlinDesktop'. * Exception is: org.gradle.api.GradleException: Ran two consecutive builds of the same tasks, and in the second build, observed: task :compose:material:material:compileTestKotlinDesktop not UP-TO-DATE. It was out-of-date because: Value of input property 'friendPathsSet$kotlin_gradle_plugin_common' has changed for task ':compose:material:material:compileTestKotlinDesktop'. at androidx.build.uptodatedness.TaskUpToDateValidator.onFinish(TaskUpToDateValidator.kt:192)
  54. Task up-to-date validation Running build 2x should result in second

    build being no-op 100 actionable tasks: 100 executed 100 actionable tasks: 100 up-to-date
  55. Task up-to-date validation Automated CI workflow to prevent regressions Start

    with an allowlist for tasks that are allowed to rerun
  56. Figure out timeline Never seen before based on our failed

    build log search Must be new in KGP 2.0.0, as 1.9.21 passes.
  57. Reason for the task rerun Value of input property 'friendPathsSet$kotlin_gradle_plugin_common'

    has changed for task ':compose:material:material:compileTestKotlinDesktop'.
  58. A good repro is worth a thousand words 5 days

    from sharing a repro to a fix
  59. Validating the contents of artifacts Write validation tasks that check

    your AAR/JAR/APK Make sure that your vital configuration files, API keys, string translations are present
  60. Validating the contents of artifacts AndroidX has a check to

    validate META-INF/androidx.foo_foo.version is included in the JARs.
  61. Takeaways Invest in your tools to detect and investigate -

    Log grep and occurrence graphing - Develocity - Unexpected logs - Unexpected files - Unexpected runtime length - Unexpected reruns