This is an automated email from the ASF dual-hosted git repository.

tvb pushed a commit to branch ctolentino/test
in repository https://gitbox.apache.org/repos/asf/buildstream.git

commit f4da9998de28f25d49ca549da789adf0352e0bbe
Author: ctolentino8 <[email protected]>
AuthorDate: Thu Apr 9 15:25:40 2020 +0100

    casdprocessmanager.py: Relax timeout for establishing buildbox-casd 
connection
---
 src/buildstream/_cas/casdprocessmanager.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/buildstream/_cas/casdprocessmanager.py 
b/src/buildstream/_cas/casdprocessmanager.py
index 4c9d802..8948869 100644
--- a/src/buildstream/_cas/casdprocessmanager.py
+++ b/src/buildstream/_cas/casdprocessmanager.py
@@ -37,6 +37,7 @@ from .._exceptions import CASCacheError
 from .._message import Message, MessageType
 
 _CASD_MAX_LOGFILES = 10
+_CASD_TIMEOUT = 300  # in seconds
 
 
 # CASDProcessManager
@@ -240,8 +241,8 @@ class CASDChannel:
 
         while not os.path.exists(self._socket_path):
             # casd is not ready yet, try again after a 10ms delay,
-            # but don't wait for more than 15s
-            if time.time() > self._start_time + 15:
+            # but don't wait for more than specified timeout period
+            if time.time() > self._start_time + _CASD_TIMEOUT:
                 raise CASCacheError("Timed out waiting for buildbox-casd to 
become ready")
 
             time.sleep(0.01)

Reply via email to