Phillip Smyth pushed to branch richardmaw/cache-fail at BuildStream / buildstream
Commits:
-
60261e20
by knownexus at 2018-07-31T11:14:21Z
1 changed file:
Changes:
... | ... | @@ -231,6 +231,7 @@ class Element(Plugin): |
231 | 231 |
self.__required = False # Whether the artifact is required in the current session
|
232 | 232 |
self.__artifact_size = None # The size of data committed to the artifact cache
|
233 | 233 |
self.__build_result = None # The result of assembling this Element
|
234 |
+ self._build_log_path = None # The path of the build log for this Element
|
|
234 | 235 |
|
235 | 236 |
# hash tables of loaded artifact metadata, hashed by key
|
236 | 237 |
self.__metadata_keys = {} # Strong and weak keys for this key
|
... | ... | @@ -1580,8 +1581,9 @@ class Element(Plugin): |
1580 | 1581 |
|
1581 | 1582 |
# Copy build log
|
1582 | 1583 |
log_filename = context.get_log_filename()
|
1584 |
+ self._build_log_path = os.path.join(logsdir, 'build.log')
|
|
1583 | 1585 |
if log_filename:
|
1584 |
- shutil.copyfile(log_filename, os.path.join(logsdir, 'build.log'))
|
|
1586 |
+ shutil.copyfile(log_filename, self._build_log_path)
|
|
1585 | 1587 |
|
1586 | 1588 |
# Store public data
|
1587 | 1589 |
_yaml.dump(_yaml.node_sanitize(self.__dynamic_public), os.path.join(metadir, 'public.yaml'))
|
... | ... | @@ -1632,6 +1634,9 @@ class Element(Plugin): |
1632 | 1634 |
# Finally cleanup the build dir
|
1633 | 1635 |
cleanup_rootdir()
|
1634 | 1636 |
|
1637 |
+ def _get_build_log(self):
|
|
1638 |
+ return self._build_log_path
|
|
1639 |
+ |
|
1635 | 1640 |
# _pull_pending()
|
1636 | 1641 |
#
|
1637 | 1642 |
# Check whether the artifact will be pulled.
|