From d68726efe5e397dd4ed2a4c525dc28d105a50c3e Mon Sep 17 00:00:00 2001 From: Brandon McAnsh Date: Mon, 28 Sep 2026 09:02:09 -0400 Subject: [PATCH] fix(emojis): run generateEmojiList before KSP The Flipcash2 release build on 059570dc9 failed in :libs:emojis:kspReleaseKotlin: Gradle rejected it for reading generateEmojiList's output in src/main/kotlin without depending on it. #1576 added KSP (for Hilt) to libs/emojis. The build already made every compile*Kotlin task depend on generateEmojiList, but not the new ksp*Kotlin tasks, so the two were unordered and the failure depends on which runs first. Extend the same wiring to ksp*Kotlin. --- libs/emojis/build.gradle.kts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libs/emojis/build.gradle.kts b/libs/emojis/build.gradle.kts index 370070ee78..8b9dc57d65 100644 --- a/libs/emojis/build.gradle.kts +++ b/libs/emojis/build.gradle.kts @@ -33,9 +33,10 @@ dependencies { androidTestImplementation(libs.androidx.test.runner) } -// Define the task to fetch and generate emoji data +// Define the task to fetch and generate emoji data. KSP reads src/main/kotlin too, so it +// has to wait for the generated sources as well as the Kotlin compile. afterEvaluate { - tasks.matching { it.name.matches(Regex("compile.*Kotlin")) }.configureEach { + tasks.matching { it.name.matches(Regex("(compile|ksp).*Kotlin")) }.configureEach { dependsOn("generateEmojiList") } }