BinaryCacheStore no longer implements buildPaths() and ensurePath(), so we need to use copyPath() / copyClosure().
IKJBYIGY3JABFXD2KOAQNA52ULE6VR4PBFKHWAHHBITXX5KC76MAC
BYVRA54QBKHLFOPIRBJKZZI7JYBYHSOK7MIA3TUZTALZQJGG3G7QC
YTAYNN7VNYZNLGUSGY3EF33MGQWMJW76FKV657SBKASQFQC7EB3AC
HB7JA5WVFFZMRRALIQEMD2GKSEXZLE4QZFR2NFMUJTGPHNWVD7XAC
PDI5YPBYHMU4EQM3D45JEUYI4PBU5KGDIWK5O5YEOCM6R3IEAXUQC
KKHVM4KAM6I5B4KZPIKCEBWRB3LNYCFD7XIH4NCPGLNSMRCGJC6AC
4J33F22TRXXW3WRI3KAF7DQZXQ7JH3A5XBNR7BJCKK7OFUF4AHSQC
D3MDJONYWWNXVVZDKTPDQE2H2HGMF263LXKT57B2GYCOXNM3PPOQC
ZYEFL36QOB6KUR276RRT4PSAK7HWUJ6TLLZBEZM7SSGUX2WQTMZQC
4HDPYRJ6OT6WH3U6ZAHXZKI5LBRBDDVVTUZ5TY5UO474ZQ3ZK65AC
5AIYUMTBY6TFQTBRP3MJ2PYWUMRF57I77NIVWYE74UMEVQMBWZVQC
BRAESISHTN4IIWUBVDMPDMY7QLMJDKX7GQ7K6NSJN66L5VPWSX3QC
73YR46NJNYZQKHA3QDJCAZYAKC2CGEF5LIS44NOIPDZU6FX6BDPQC
24BMQDZAWDQ7VNIA7TIROXSOYLOJBNZ2E4264WHWNJAEN6ZB3UOAC
EOO4EFWD2BJCGF3ZKS2QR3XDW4WHUGH2EHSOFVK6GMI5BUBZW6QQC
B2L4T3X63XVYJQXEDU4WT5Y4R6PMDXGC6WN2KGOMHRQILSABNQOAC
GJV2J5HXFKVF7BXNFMTI6ZZMYADXIKTFIQJ3FONJ7DPVCUJZ2L4AC
SOB276BAWH23OUKJUXGDWCLDIM2OISD5NKF743NTQ3L572L4BS3QC
V2UCCYN3B6266BDKGSXQDRSW4HKY673GINM3VI3MORXZ7OYDJBXAC
MHVIT4JYWUYD4UCGB2AHLXWLX6B5SYE22BREERNGANT7RGGDUFOAC
VQISTKOPNAEUS2K2F73CMNNLGZATWUYIURD5CSVNBNF7Q5ZF4PXQC
HJOEIMLRDVQ2KZI5HGL2HKGBM3AHP7YIKGKDAGFUNKRUXVRB24NAC
WE5Q2NVIIK4R2DUUZYLJFQVYK5O26EDEJRPK3CPGWHU3SEAC2DQAC
missingPaths.insert(i.second.path);
}
/* Try to copy the missing paths from the local store or from
substitutes. */
if (!missing.empty()) {
size_t avail = 0;
for (auto & i : missing) {
if (/* localStore != destStore && */ localStore->isValidPath(i.second.path))
avail++;
else if (useSubstitutes) {
SubstitutablePathInfos infos;
localStore->querySubstitutablePathInfos({i.second.path}, infos);
if (infos.size() == 1)
avail++;
}
/* Try to substitute the missing paths. Note: can't use the more
efficient querySubstitutablePaths() here because upstream Hydra
servers don't allow it (they have "WantMassQuery: 0"). */
assert(missing.size() == missingPaths.size());
if (!missing.empty() && settings.useSubstitutes) {
SubstitutablePathInfos infos;
destStore->querySubstitutablePathInfos(missingPaths, infos); // FIXME
if (infos.size() == missingPaths.size()) {
if (missing.size() == avail) {
printMsg(lvlInfo, format("substituting output ‘%1%’ of ‘%2%’") % i.second.path % drvPath);
time_t startTime = time(0);
if (localStore->isValidPath(i.second.path))
printInfo("copying output ‘%1%’ of ‘%2%’ from local store", i.second.path, drvPath);
else {
printInfo("substituting output ‘%1%’ of ‘%2%’", i.second.path, drvPath);
localStore->ensurePath(i.second.path);
// FIXME: should copy directly from substituter to destStore.
}
copyClosure(ref<Store>(localStore), destStore, {i.second.path});