Don't download miniconda on "./gradlew clean", if already downloaded
Categories
(Data Platform and Tools :: Glean: SDK, enhancement, P1)
Tracking
(Not tracked)
People
(Reporter: Dexter, Assigned: mdroettboom)
References
Details
(Whiteboard: [telemetry:glean-rs:m11])
Attachments
(1 file)
Steps to reproduce
- Build Fenix with
./gradlew clean app:assembleGeckoNightlyDebug
. - Rebuild with the same command.
Actual behavior
The build output shows:
> Task :app:Bootstrap_CONDA_'Miniconda3'
Downloading Miniconda3-4.5.11-Linux-x86_64.sh
on every incremental rebuild, and this step takes a while (~1 minute), adding significant latency to incremental rebuilds.
Expected behavior
Only download it the first time, not for incremental rebuilds.
Device information
- Android device: Moto G5
- Fenix version: recent master branch
Reporter | ||
Updated•5 years ago
|
Comment 1•5 years ago
|
||
The "clean" step in there will clear out everything, including the miniconda install bundled in the build directory, won't it?
Reporter | ||
Comment 2•5 years ago
|
||
(In reply to Jan-Erik Rediger [:janerik] from comment #1)
The "clean" step in there will clear out everything, including the miniconda install bundled in the build directory, won't it?
Exactly (I pointed that out in the Fenix issue). However, Gradle is...well, gradle. There's still the Gradle cache that doesn't get invalidated unless you explicitly request to do that.
Maybe there's a way to catch the "invalidate cache" from the gradle script, so that we can simply skip downloaded unless invalidating. But that's well within the Gradle-hell land. And definitely post gradle plugin migration, IMHO.
Assignee | ||
Comment 3•5 years ago
|
||
including the miniconda install bundled in the build directory, won't it?
In this case, we install miniconda in the ~/.gradle/cache
directory (so it can be shared between multiple components and projects using Glean). So it is somewhat surprising that clean removes it. I think this may be an artifact from when we used to install it in the build directory.
Removing this is probably enough to fix it. The Gradle plugin has a similar issue and a similarly easy fix.
Updated•5 years ago
|
Reporter | ||
Updated•5 years ago
|
Assignee | ||
Comment 4•5 years ago
|
||
It's easy enough to make clean
not clear the miniconda environment. However, having cache invalidation clear it seems to be no longer supported according to this StackOverflow answer. I think we're still better off just removing it from clean
, so I will file a PR for that.
Assignee | ||
Comment 5•5 years ago
|
||
Assignee | ||
Updated•5 years ago
|
Description
•