summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAbderrahim Kitouni <akitouni@gnome.org>2020-06-20 07:45:31 +0100
committerbst-marge-bot <marge-bot@buildstream.build>2020-07-17 20:04:20 +0000
commit65db30aa99c4b1619c798dda541436e5bb2f7007 (patch)
tree57d1e6d30b9737eb45d63d457cb334b29d0344e6
parentbcb789d9221c53fda4b151615560591dda38ef29 (diff)
downloadbuildstream-65db30aa99c4b1619c798dda541436e5bb2f7007.tar.gz
element.py: don't use timed activity for staging every artifactabderrahim/timed
Staging now takes very little time, so we have two lines per artifact with no benefit. Use a STATUS line instead.
-rw-r--r--src/buildstream/element.py24
1 files changed, 11 insertions, 13 deletions
diff --git a/src/buildstream/element.py b/src/buildstream/element.py
index 6a0fa5fab..45c3735fd 100644
--- a/src/buildstream/element.py
+++ b/src/buildstream/element.py
@@ -661,23 +661,21 @@ class Element(Plugin):
# Time to use the artifact, check once more that it's there
self.__assert_cached()
- with self.timed_activity("Staging {}/{}".format(self.name, self._get_brief_display_key())):
- # Disable type checking since we can't easily tell mypy that
- # `self.__artifact` can't be None at this stage.
- files_vdir = self.__artifact.get_files() # type: ignore
+ self.status("Staging {}/{}".format(self.name, self._get_brief_display_key()))
+ # Disable type checking since we can't easily tell mypy that
+ # `self.__artifact` can't be None at this stage.
+ files_vdir = self.__artifact.get_files() # type: ignore
- # Hard link it into the staging area
- #
- vbasedir = sandbox.get_virtual_directory()
- vstagedir = vbasedir if path is None else vbasedir.descend(*path.lstrip(os.sep).split(os.sep), create=True)
+ # Hard link it into the staging area
+ #
+ vbasedir = sandbox.get_virtual_directory()
+ vstagedir = vbasedir if path is None else vbasedir.descend(*path.lstrip(os.sep).split(os.sep), create=True)
- split_filter = self.__split_filter_func(include, exclude, orphans)
+ split_filter = self.__split_filter_func(include, exclude, orphans)
- result = vstagedir.import_files(
- files_vdir, filter_callback=split_filter, report_written=True, can_link=True
- )
+ result = vstagedir.import_files(files_vdir, filter_callback=split_filter, report_written=True, can_link=True)
- return result
+ return result
def stage_dependency_artifacts(
self,