summaryrefslogtreecommitdiff
path: root/buildstream/_pipeline.py
diff options
context:
space:
mode:
Diffstat (limited to 'buildstream/_pipeline.py')
-rw-r--r--buildstream/_pipeline.py13
1 files changed, 12 insertions, 1 deletions
diff --git a/buildstream/_pipeline.py b/buildstream/_pipeline.py
index 4e5f4d0e9..1f75b2e9e 100644
--- a/buildstream/_pipeline.py
+++ b/buildstream/_pipeline.py
@@ -355,10 +355,14 @@ class Pipeline():
#
def assert_consistent(self, elements):
inconsistent = []
+ inconsistent_workspaced = []
with self._context.timed_activity("Checking sources"):
for element in elements:
if element._get_consistency() == Consistency.INCONSISTENT:
- inconsistent.append(element)
+ if element._get_workspace():
+ inconsistent_workspaced.append(element)
+ else:
+ inconsistent.append(element)
if inconsistent:
detail = "Exact versions are missing for the following elements:\n\n"
@@ -372,6 +376,13 @@ class Pipeline():
raise PipelineError("Inconsistent pipeline", detail=detail, reason="inconsistent-pipeline")
+ if inconsistent_workspaced:
+ detail = "Some workspaces do not exist but are not closed\n" + \
+ "Try closing them with `bst workspace close`\n\n"
+ for element in inconsistent_workspaced:
+ detail += " " + element._get_full_name() + "\n"
+ raise PipelineError("Inconsistent pipeline", detail=detail, reason="inconsistent-pipeline-workspaced")
+
#############################################################
# Private Methods #
#############################################################