Adds logging in light stuff, minor changes in config/string.
[python_utils.git] / executors.py
index 63efd812e54b5b796daff892f9ff1e75fd4e6569..ddd62f1b8a3998fa85a4fb456538eabd54e3d206 100644 (file)
@@ -64,7 +64,7 @@ SSH = 'ssh -oForwardX11=no'
 
 
 def make_cloud_pickle(fun, *args, **kwargs):
-    logger.info(f"Making cloudpickled bundle at {fun.__name__}")
+    logger.debug(f"Making cloudpickled bundle at {fun.__name__}")
     return cloudpickle.dumps((fun, args, kwargs))
 
 
@@ -610,7 +610,7 @@ class RemoteExecutor(BaseExecutor):
 
         # Do it.
         cmd = (f'{SSH} {bundle.username}@{bundle.machine} '
-               f'"source remote-execution/bin/activate &&'
+               f'"source py39-venv/bin/activate &&'
                f' /home/scott/lib/python_modules/remote_worker.py'
                f' --code_file {bundle.code_file} --result_file {bundle.result_file}"')
         p = cmd_in_background(cmd, silent=True)
@@ -619,7 +619,7 @@ class RemoteExecutor(BaseExecutor):
 
         while True:
             try:
-                p.wait(timeout=0.5)
+                p.wait(timeout=0.25)
             except subprocess.TimeoutExpired:
                 self.heartbeat()
 
@@ -882,7 +882,7 @@ class DefaultExecutors(object):
                     RemoteWorkerRecord(
                         username = 'scott',
                         machine = 'meerkat.cabin',
-                        weight = 7,
+                        weight = 6,
                         count = 2,
                     ),
                 )