summaryrefslogtreecommitdiff
path: root/src/buildstream/_project.py
diff options
context:
space:
mode:
authorTristan van Berkom <tristan@codethink.co.uk>2020-08-30 18:41:48 +0900
committerbst-marge-bot <marge-bot@buildstream.build>2020-08-30 17:25:07 +0000
commitb758505b6f1d82d839cee4b870a7fa5a8ce7422b (patch)
tree9b49ecb988c018e64b88691282edfc11d860cf1a /src/buildstream/_project.py
parentfd80d4903eb28845ca9a67d5730254d93dbd0c24 (diff)
downloadbuildstream-b758505b6f1d82d839cee4b870a7fa5a8ce7422b.tar.gz
Remove unused Scope argument from artifact name related APIs.tristan/artifact-dependency-names
Additionally, this reverts terminology back to calling these "artifact names", and not "artifact refs", which is a terminology which crept in from various underlying implementations. Summary of changes: * _artifact.py: - get_dependency_refs() renamed to get_dependency_artifact_names() - get_dependency_artifact_names() loses the Scope argument - Consequently, a huge and needless XXX comment is removed * _artifactelement.py: - _new_from_artifact_ref() renamed to _new_from_artifact_name() - get_dependency_refs() renamed to get_dependency_artifact_names() - get_dependency_artifact_names() loses the Scope argument * _project.py: - Now call _new_from_artifact_name() - Removes a legacy XXX comment which is not particularly relevant * element.py: - __get_dependency_refs() renamed to __get_dependency_artifact_names() - Adapt __get_last_build_artifact() to updated API names.
Diffstat (limited to 'src/buildstream/_project.py')
-rw-r--r--src/buildstream/_project.py9
1 files changed, 1 insertions, 8 deletions
diff --git a/src/buildstream/_project.py b/src/buildstream/_project.py
index 87772995a..209ba516c 100644
--- a/src/buildstream/_project.py
+++ b/src/buildstream/_project.py
@@ -467,16 +467,9 @@ class Project:
#
def load_artifacts(self, targets):
with self._context.messenger.simple_task("Loading artifacts") as task:
- # XXX: Here, we are explicitly checking for refs in the artifactdir
- # for two reasons:
- # 1. The Project, or the Context, do not currently have
- # access to the ArtifactCache
- # 2. The ArtifactCache.contains() method expects an Element
- # and a key, not a ref.
- #
artifacts = []
for ref in targets:
- artifacts.append(ArtifactElement._new_from_artifact_ref(ref, self._context, task))
+ artifacts.append(ArtifactElement._new_from_artifact_name(ref, self._context, task))
ArtifactElement._clear_artifact_refs_cache()