From 541cd76022ca7e9ef8e4114495b908943fe3e8b1 Mon Sep 17 00:00:00 2001 From: Tristan Van Berkom Date: Mon, 30 Apr 2018 20:11:30 +0900 Subject: _stream.py, _frontend: Call Stream() APIs with CLI arguments directly. This shifts the whole responsibility of interpreting command line targets etc to the Stream() object itself. With this commit, the Pipeline() truly becomes slaved to the Stream(). --- buildstream/_pipeline.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'buildstream/_pipeline.py') diff --git a/buildstream/_pipeline.py b/buildstream/_pipeline.py index 52bae2e5c..7f3c657fa 100644 --- a/buildstream/_pipeline.py +++ b/buildstream/_pipeline.py @@ -27,7 +27,6 @@ from ._message import Message, MessageType from ._loader import Loader from .element import Element from . import Scope, Consistency -from ._platform import Platform from ._project import ProjectRefStorage from ._artifactcache.artifactcache import ArtifactCacheSpec, configured_remote_artifact_cache_specs @@ -87,7 +86,7 @@ class PipelineSelection(): # class Pipeline(): - def __init__(self, context, project, targets, except_, rewritable=False): + def __init__(self, context, project, artifacts, targets, except_, rewritable=False): self.context = context # The Context self.project = project # The toplevel project @@ -96,7 +95,7 @@ class Pipeline(): # # Private members # - self._artifacts = None + self._artifacts = artifacts self._loader = None self._exceptions = None self._track_cross_junctions = False @@ -106,10 +105,6 @@ class Pipeline(): # Early initialization # - # Load selected platform - Platform.create_instance(context, project) - platform = Platform.get_platform() - self._artifacts = platform.artifactcache self._loader = Loader(self.context, self.project, targets + except_) with self.context.timed_activity("Loading pipeline", silent_nested=True): -- cgit v1.2.1