diff options
author | Jim MacArthur <jim.macarthur@codethink.co.uk> | 2018-06-29 16:34:13 +0100 |
---|---|---|
committer | Jim MacArthur <jim.macarthur@codethink.co.uk> | 2018-06-29 16:34:21 +0100 |
commit | 67010c49dfb468f8705b41e55b366979a5897037 (patch) | |
tree | 952b181dd5c1434ade792b6672c9a24d5684b7ea | |
parent | bf562f4fcddaf9a93ba896706860bcbfd50be3c9 (diff) | |
download | buildstream-67010c49dfb468f8705b41e55b366979a5897037.tar.gz |
_sandboxremote.py: Fix some compile errors in the last commit and exit with failure if we get the wrong response from the server
-rw-r--r-- | buildstream/sandbox/_sandboxremote.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/buildstream/sandbox/_sandboxremote.py b/buildstream/sandbox/_sandboxremote.py index 3a398894f..19e142bee 100644 --- a/buildstream/sandbox/_sandboxremote.py +++ b/buildstream/sandbox/_sandboxremote.py @@ -39,7 +39,7 @@ from google.devtools.remoteexecution.v1test import remote_execution_pb2, remote_ from google.longrunning import operations_pb2, operations_pb2_grpc from .._artifactcache.cascache import CASCache -class SandboxError(Error): +class SandboxError(Exception): pass # SandboxRemote() @@ -131,7 +131,7 @@ class SandboxRemote(Sandbox): # Now do a pull to ensure we have the necessary parts cascache.pull_key_only(digest.hash, self._get_project()) - directory_head = os.path.join(path_components([:-1])) + directory_head = os.path.join(path_components[:-1]) directory_tail = path_components([-1]) containing_dir = self.get_virtual_directory().descend(directory_head) @@ -183,6 +183,7 @@ class SandboxRemote(Sandbox): self.process_job_output(actionResult.output_directories, actionResult.output_files) else: sys.stderr.write("Received unknown message from server.\n") + return 1 else: sys.stderr.write("Failed to verify source on remote artifact cache.\n") return 1 |