diff --git a/maestrowf/abstracts/interfaces/scriptadapter.py b/maestrowf/abstracts/interfaces/scriptadapter.py index 7bfff7c4f..85b01a686 100644 --- a/maestrowf/abstracts/interfaces/scriptadapter.py +++ b/maestrowf/abstracts/interfaces/scriptadapter.py @@ -147,7 +147,7 @@ def submit(self, step, path, cwd, job_map=None, env=None): @abstractmethod def key(self): """ - The key to be used in workflow specification to describe the adapter. + Return the key name for a ScriptAdapter.. This is used to register the adapter in the ScriptAdapterFactory and when writing the workflow specification. diff --git a/maestrowf/interfaces/script/fluxscriptadapter.py b/maestrowf/interfaces/script/fluxscriptadapter.py index cb3ab9b55..dd860a69a 100644 --- a/maestrowf/interfaces/script/fluxscriptadapter.py +++ b/maestrowf/interfaces/script/fluxscriptadapter.py @@ -501,7 +501,7 @@ def __init__(self, **kwargs): :param **kwargs: A dictionary with default settings for the adapter. """ - super(FluxScriptAdapter, self).__init__() + super(FluxScriptAdapter, self).__init__(**kwargs) # NOTE: These libraries are compiled at runtime when an allocation # is spun up. @@ -513,7 +513,6 @@ def __init__(self, **kwargs): self.add_batch_parameter("nodes", kwargs.pop("nodes", "1")) self._addl_args = kwargs.get("args", []) - self._exec = "#!/bin/bash" # Header is only for informational purposes. self._header = { "nodes": "#INFO (nodes) {nodes}", diff --git a/maestrowf/interfaces/script/localscriptadapter.py b/maestrowf/interfaces/script/localscriptadapter.py index d80da6fa3..b55722c43 100644 --- a/maestrowf/interfaces/script/localscriptadapter.py +++ b/maestrowf/interfaces/script/localscriptadapter.py @@ -56,9 +56,8 @@ def __init__(self, **kwargs): :param **kwargs: A dictionary with default settings for the adapter. """ - super(LocalScriptAdapter, self).__init__() - - self._exec = kwargs.pop("shell", "/bin/bash") + LOGGER.debug("kwargs\n--------------------------\n%s", kwargs) + super(LocalScriptAdapter, self).__init__(**kwargs) def _write_script(self, ws_path, step): """ diff --git a/maestrowf/maestro.py b/maestrowf/maestro.py index 74c6ba3b2..c9f349811 100644 --- a/maestrowf/maestro.py +++ b/maestrowf/maestro.py @@ -245,14 +245,11 @@ def run_study(args): # If performing a dry run, drive sleep time down to generate scripts. sleeptime = 1 else: - # else, use args to decide sleeptime - sleeptime = args.sleeptime - - batch = {"type": "local"} - if spec.batch: - batch = spec.batch - if "type" not in batch: - batch["type"] = "local" + if "type" not in spec.batch: + spec.batch["type"] = "local" + + exec_dag.set_adapter(spec.batch) + # Copy the spec to the output directory shutil.copy(args.specification, study.output_path) diff --git a/samples/lulesh/lulesh_sample1_macosx.yaml b/samples/lulesh/lulesh_sample1_macosx.yaml index 4c30dc12c..4dfa9612e 100644 --- a/samples/lulesh/lulesh_sample1_macosx.yaml +++ b/samples/lulesh/lulesh_sample1_macosx.yaml @@ -22,6 +22,9 @@ env: url: https://github.com/LLNL/LULESH.git tag: 2.0.3 +batch: + shell: /bin/bash + study: - name: make-lulesh description: Build the serial version of LULESH.