From 4d93c9b01a1a0b5d1ef888b0a1c1ecb160c0c93d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrg=20Billeter?= Date: Tue, 1 Aug 2017 16:57:04 +0100 Subject: _artifactcache: Fix pull in non-strict mode Strong ref was not created. --- buildstream/_artifactcache/artifactcache.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'buildstream/_artifactcache/artifactcache.py') diff --git a/buildstream/_artifactcache/artifactcache.py b/buildstream/_artifactcache/artifactcache.py index a7208e8f2..4ebc79848 100644 --- a/buildstream/_artifactcache/artifactcache.py +++ b/buildstream/_artifactcache/artifactcache.py @@ -277,13 +277,13 @@ class ArtifactCache(): _ostree.fetch(self.repo, remote=remote, ref=weak_ref, progress=progress) + # resolve weak_ref to checksum + rev = _ostree.checksum(self.repo, weak_ref) + # extract strong cache key from this newly fetched artifact element._cached(recalculate=True) ref = buildref(element, element._get_cache_key_from_artifact()) - # resolve ref to checksum - rev = _ostree.checksum(self.repo, ref) - # create tag for strong cache key _ostree.set_ref(self.repo, ref, rev) else: -- cgit v1.2.1