diff options
author | Jürg Billeter <j@bitron.ch> | 2020-04-07 18:26:57 +0200 |
---|---|---|
committer | Jürg Billeter <j@bitron.ch> | 2020-04-07 18:27:19 +0200 |
commit | 958ddebf9057f0e16f396589f62ace66e6e67f53 (patch) | |
tree | c6afbc0c954851308aaa0667117ef94972906ffc | |
parent | 2f9acf50abe8f776988ff8d90e90be6e80f866d7 (diff) | |
download | buildstream-juerg/public-data.tar.gz |
_artifact.py: Use CASCache.contains_directory_and_blobs()juerg/public-data
-rw-r--r-- | src/buildstream/_artifact.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/buildstream/_artifact.py b/src/buildstream/_artifact.py index 0e1355f34..10885f7dc 100644 --- a/src/buildstream/_artifact.py +++ b/src/buildstream/_artifact.py @@ -433,12 +433,10 @@ class Artifact: require_files = context.require_artifact_files or self._element._artifact_files_required() # Check whether 'files' subdirectory is available, with or without file contents - if str(artifact.files) and not self._cas.contains_directory(artifact.files, with_files=require_files): - self._cached = False - return False - # Check whether public data is available - if not self._cas.contains_file(artifact.public_data): + if not self._cas.contains_directory_and_blobs( + artifact.files, [artifact.public_data], with_files=require_files + ): self._cached = False return False |