Skip to content

Commit 2130587

Browse files
committed
Version bump 0.1.3
Use **kwargs from __init__ and add set_job_id in ExecutionHandler
1 parent 524e121 commit 2130587

2 files changed

Lines changed: 11 additions & 1 deletion

File tree

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "zoo-runner-common"
7-
version = "0.1.2"
7+
version = "0.1.3"
88
description = "Shared utilities for ZOO-Project CWL runners"
99
readme = "README.md"
1010
requires-python = ">=3.10"

zoo_runner_common/handlers.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,16 @@ class ExecutionHandler(ABC):
1818
methods to provide concrete execution logic.
1919
"""
2020

21+
def __init__(self, **kwargs):
22+
self.__dict__.update(kwargs)
23+
self.job_id = getattr(self, 'job_id', None)
24+
self.outputs = getattr(self, 'outputs', {})
25+
self.results = getattr(self, 'results', None)
26+
27+
def set_job_id(self, job_id):
28+
"""Set the job ID for the execution."""
29+
self.job_id = job_id
30+
2131
@abstractmethod
2232
def pre_execution_hook(self):
2333
"""

0 commit comments

Comments
 (0)