Bug 1383880: --from-build is a dev tool, not for automation; r?glandium draft
authorDustin J. Mitchell <dustin@mozilla.com>
Fri, 15 Sep 2017 12:26:14 +0000
changeset 668278 330938f303906e1ebd5c96a08acbf9e0acac3ea8
parent 668277 d3eabcbd8cd9c01db3a3528f6a34ad755407e30d
child 668279 ad896d3a555405848f1f9f4a89ac9c6f2ddb4e75
push id80998
push userdmitchell@mozilla.com
push dateThu, 21 Sep 2017 12:49:52 +0000
reviewersglandium
bugs1383880
milestone57.0a1
Bug 1383880: --from-build is a dev tool, not for automation; r?glandium MozReview-Commit-ID: EGs3Zy012JA
python/mozbuild/mozbuild/mach_commands.py
--- a/python/mozbuild/mozbuild/mach_commands.py
+++ b/python/mozbuild/mozbuild/mach_commands.py
@@ -1877,16 +1877,21 @@ class PackageFrontend(MachCommandBase):
                                         record.digest)
                 records[record.filename] = DownloadRecord(
                     url, record.filename, record.size, record.digest,
                     record.algorithm, unpack=record.unpack,
                     version=record.version, visibility=record.visibility,
                     setup=record.setup)
 
         if from_build:
+            if 'TASK_ID' in os.environ:
+                self.log(logging.ERROR, 'artifact', {},
+                         'Do not use --from-build in automation; all dependencies '
+                         'should be determined in the decision task.')
+                return 1
             from taskgraph.optimize import IndexSearch
             params = {
                 'message': '',
                 'project': '',
                 'level': os.environ.get('MOZ_SCM_LEVEL', '3'),
                 'base_repository': '',
                 'head_repository': '',
                 'head_rev': '',