You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: Android native-client builds lose Gradle history and native compile outputs on every clean prebuild, costing about 22 s of a 68 s build #18161
Every clean Android prebuild deletes the Gradle history and native compile outputs, adding about 22 s to a 68 s build (pull request 18073 measured 67.7 s against 46.2 s).
Area: Build, CI, or release tooling
Steps to reproduce
Build an Android development client with scripts/mobile-native-client.ts (it runs expo prebuild --clean --platform android, then Gradle).
Build again with the app source unchanged.
Expected behavior
The second build reuses Gradle task history and the app's native compilation outputs, since their inputs have not changed.
Actual behavior
The clean prebuild deletes the generated android directory, which also deletes .gradle and app/.cxx. Every repeated build starts those from nothing.
Measured in #18073: a clean prebuild plus ARM64 debug Gradle build on the same unchanged revision took a mean of 67.7 s without the change and 46.2 s with it (21.6 s, 31.8% lower), six runs each in alternating order, with a warm shared Gradle cache. That was Linux (WSL) only, for warm repeated debug builds. It does not cover cold builds, macOS or Windows.
Impact: Minor bug or occasional failure
Version or commit: main at 8d199b4 (scripts/mobile-native-client.ts still runs prebuild --clean)
Environment: Ubuntu on WSL2, Node 24, Java 17
Proposed fix: PR #18073 moves the two directories aside before prebuild and restores them before Gradle runs, and keeps them recoverable if prebuild fails or is interrupted.
changed the title [-][Bug]: Android native-client builds lose Gradle history and native compile outputs on every clean prebuild[/-][+][Bug]: Android native-client builds lose Gradle history and native compile outputs on every clean prebuild, costing about 22 s of a 68 s build[/+]on Oct 12, 2026
Activity
[-][Bug]: Android native-client builds lose Gradle history and native compile outputs on every clean prebuild[/-][+][Bug]: Android native-client builds lose Gradle history and native compile outputs on every clean prebuild, costing about 22 s of a 68 s build[/+]bompus commentedon Oct 13, 2026
Superseded by #18921, which has the same report filed through the triage form. Tracked there; PR #18073 now links it.