Metadata-Version: 2.4
Name: tketool.pipeline
Version: 1.3.5
Summary: Stage-based processing pipeline and injection decorators for tketool
Author-email: Ke <jiangke1207@icloud.com>
License-Expression: MIT
Project-URL: Homepage, https://pypi.org/project/tketool.pipeline/
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Operating System :: OS Independent
Requires-Python: >=3.10
Description-Content-Type: text/markdown
Requires-Dist: tketool.core[console]==1.3.5
Provides-Extra: test
Requires-Dist: pytest<9,>=8; extra == "test"

# tketool.pipeline

Small stage-based processing pipelines with ordered decorators, optional
parallel item processing, and local buffering.

```bash
pip install tketool.pipeline
```

```python
from enum import Enum

from tketool.pipeline import Pipeline, invoke_all


class Stage(Enum):
    PREPARE = "prepare"
    RUN = "run"


class Steps:
    @invoke_all(Stage.PREPARE.value, priority=10)
    def prepare(self, board):
        board.current_data = {"ready": True}


pipeline = Pipeline(Stage, acts=[Steps()])
result = pipeline()
```

The retired `tketool.injections` path is not shipped.
