summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJürg Billeter <j@bitron.ch>2019-03-02 12:07:10 +0100
committerJürg Billeter <j@bitron.ch>2019-03-06 11:30:51 +0100
commitecd4b1f7ededef5bda167ddebf211402d4d6530a (patch)
tree96abf1312492aac521a3bf2dcae464a0e5749bd8
parent6df7d7b8a32ee2b67bcf4dbbe0802317b0b54e70 (diff)
downloadbuildstream-ecd4b1f7ededef5bda167ddebf211402d4d6530a.tar.gz
_sandboxremote.py: Process job output for failed commands
The sandbox directory should be updated even for commands with non-zero exit code. This allows caching the failed buildtree for debugging.
-rw-r--r--buildstream/sandbox/_sandboxremote.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/buildstream/sandbox/_sandboxremote.py b/buildstream/sandbox/_sandboxremote.py
index 9e58b095a..d49f31133 100644
--- a/buildstream/sandbox/_sandboxremote.py
+++ b/buildstream/sandbox/_sandboxremote.py
@@ -354,6 +354,9 @@ class SandboxRemote(Sandbox):
operation = self.run_remote_command(channel, action_digest)
action_result = self._extract_action_result(operation)
+ # Get output of build
+ self.process_job_output(action_result.output_directories, action_result.output_files)
+
if action_result.exit_code != 0:
# A normal error during the build: the remote execution system
# has worked correctly but the command failed.
@@ -361,9 +364,6 @@ class SandboxRemote(Sandbox):
# build command outputs which we ignore at the moment.
return action_result.exit_code
- # Get output of build
- self.process_job_output(action_result.output_directories, action_result.output_files)
-
return 0
def _check_action_cache(self, action_digest):