I'm trying to optimize LFS pulls in tests, by fixt...
# general
r
I'm trying to optimize LFS pulls in tests, by fixtures that run
git lfs pull --include=...
only for required files only when required by selected tests. The problem is that when running
pants test
, it is run inside an isolated pex environment, so there is no
.git
directory to run
git
against. Would there be a solution for this?
If I run
git lfs pull
command on the build root, Pants detects filesystem changes and interrupt + retry running the test module. This makes the CI to pass, but I'm now worried about the future: what if there are multiple test modules depending on the same LFS file and races between them?
b
One idea would be working out which tests will run and running the relevant
git lfs
for only those tests, all outside the
pants test ...
invocation
s
I am a newb at this, but could the tests depend on an adhoc call for git lfs?
👍 1