diff options
-rw-r--r-- | buildstream/_pipeline.py | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/buildstream/_pipeline.py b/buildstream/_pipeline.py index f1e51a05e..cc462c21a 100644 --- a/buildstream/_pipeline.py +++ b/buildstream/_pipeline.py @@ -359,23 +359,14 @@ class Pipeline(): if inconsistent: detail = "Exact versions are missing for the following elements:\n\n" - - missingTrack = 0 for element in inconsistent: - detail += " " + element._get_full_name() + detail += " Element: {} is inconsistent\n".format(element._get_full_name()) for source in element.sources(): - if not source._get_consistency() and not source.get_ref(): - if hasattr(source, 'tracking') and source.tracking is None: - detail += ": Source {} is missing ref and track. ".format(source._get_full_name()) + \ - "Please specify a ref or branch/tag to track." - missingTrack = 1 - - detail += "\n" + if source._get_consistency() == Consistency.INCONSISTENT: + detail += " Source {} is missing ref\n".format(source) + detail += '\n' + detail += "Try tracking these elements first with `bst track`\n" - if missingTrack: - detail += "\nThen track these elements with `bst track`\n" - else: - detail += "\nTry tracking these elements first with `bst track`\n" raise PipelineError("Inconsistent pipeline", detail=detail, reason="inconsistent-pipeline") ############################################################# |