Skip to content

Commit ec6c0b0

Browse files
michalharakalclaude
andcommitted
ci: opt out of AGP config-time dependency-resolution check (real fix for JS NPM)
My previous commit (config-cache=false) was the wrong lever — the check still fired. The throw is com.android.build.gradle.internal.DependencyResolutionChecks (registerDependencyCheck), which AGP installs independent of the config cache and which rejects KGP's KotlinPackageJsonTask resolving the Kotlin/JS + Wasm `*NpmAggregated` configs at configuration time (gradle#31483). transformers has real JS npm deps (ktor-client-js, kotlinx-browser) so this resolution happens; the engine repo runs the same `assemble allTests` green only because it has none. Revert config cache to true (matches the engine CI; not the cause) and set `android.dependencyResolutionAtConfigurationTime.disallow=false` to opt out of AGP's check, letting the JS npm resolution proceed as it does off-CI. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent 2cc5f5f commit ec6c0b0

1 file changed

Lines changed: 11 additions & 8 deletions

File tree

.github/ci-gradle.properties

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,7 @@ org.gradle.workers.max=2
44
# Disable parallel execution to reduce memory pressure and AAPT2 flakiness
55
org.gradle.parallel=false
66
org.gradle.caching=true
7-
# Config cache OFF in CI (genuinely, at the property level — not just via the
8-
# `--no-configuration-cache` CLI flag in build.yml). With it ON, AGP's
9-
# DependencyResolutionChecks is installed and rejects KGP's KotlinPackageJsonTask
10-
# resolving the JS `*NpmAggregated` configs at configuration time on a cold build
11-
# (`Configuration 'jsTestNpmAggregated' was resolved during configuration time`),
12-
# which the CLI override does not reliably suppress. See gradle#31483. Local dev
13-
# keeps config cache ON via the repo gradle.properties.
14-
org.gradle.configuration-cache=false
7+
org.gradle.configuration-cache=true
158

169
# Memory tuning
1710
org.gradle.jvmargs=-Xmx4g -Dfile.encoding=UTF-8
@@ -23,3 +16,13 @@ kotlin.compiler.execution.strategy=daemon
2316

2417
# Disable AAPT2 daemon to prevent "daemon unexpectedly exit" crashes
2518
android.aapt2.daemon=false
19+
20+
# AGP's DependencyResolutionChecks (com.android.build.gradle.internal) fails the
21+
# build when a configuration is resolved at configuration time. KGP's
22+
# KotlinPackageJsonTask resolves the Kotlin/JS + Wasm `*NpmAggregated` configs at
23+
# config time (we DO have JS npm deps: ktor-client-js, kotlinx-browser), so on a
24+
# cold CI build it throws `Configuration 'jsNpmAggregated' was resolved during
25+
# configuration time` (gradle#31483). It's a false positive against KGP's known
26+
# behaviour — the engine repo doesn't hit it only because it has no JS npm deps.
27+
# Opt out of AGP's check so the JS npm resolution proceeds as it does off-CI.
28+
android.dependencyResolutionAtConfigurationTime.disallow=false

0 commit comments

Comments
 (0)