soe-ai 0.1.0__py3-none-any.whl → 0.1.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- soe/broker.py +4 -5
- soe/docs_index.py +1 -1
- soe/init.py +2 -2
- soe/types.py +40 -28
- {soe_ai-0.1.0.dist-info → soe_ai-0.1.1.dist-info}/METADATA +70 -7
- soe_ai-0.1.1.dist-info/RECORD +10 -0
- soe/validation.py +0 -8
- soe_ai-0.1.0.dist-info/RECORD +0 -11
- {soe_ai-0.1.0.dist-info → soe_ai-0.1.1.dist-info}/WHEEL +0 -0
- {soe_ai-0.1.0.dist-info → soe_ai-0.1.1.dist-info}/licenses/LICENSE +0 -0
- {soe_ai-0.1.0.dist-info → soe_ai-0.1.1.dist-info}/top_level.txt +0 -0
soe/broker.py
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
from uuid import uuid4
|
|
2
|
-
from typing import Dict, List, Any, Union,
|
|
3
|
-
from .types import Backends, BroadcastSignalsCaller
|
|
4
|
-
from .local_backends import EventTypes
|
|
2
|
+
from typing import Dict, List, Any, Union, Optional
|
|
3
|
+
from .types import Backends, BroadcastSignalsCaller, NodeCaller, EventTypes, WorkflowValidationError
|
|
5
4
|
from .lib.register_event import register_event
|
|
6
5
|
from .lib.yaml_parser import parse_yaml
|
|
7
6
|
from .lib.operational import add_operational_state
|
|
@@ -131,7 +130,7 @@ def orchestrate(
|
|
|
131
130
|
def broadcast_signals(
|
|
132
131
|
id: str,
|
|
133
132
|
signals: List[str],
|
|
134
|
-
nodes: Dict[str,
|
|
133
|
+
nodes: Dict[str, NodeCaller],
|
|
135
134
|
backends: Backends,
|
|
136
135
|
) -> None:
|
|
137
136
|
"""Broadcast signals to matching nodes in the current workflow"""
|
|
@@ -139,7 +138,7 @@ def broadcast_signals(
|
|
|
139
138
|
|
|
140
139
|
register_event(backends, id, EventTypes.SIGNALS_BROADCAST, {"signals": signals})
|
|
141
140
|
|
|
142
|
-
workflows_registry = backends.workflow.
|
|
141
|
+
workflows_registry = backends.workflow.get_workflows_registry(id)
|
|
143
142
|
|
|
144
143
|
workflow_name = backends.workflow.get_current_workflow_name(id)
|
|
145
144
|
workflow = workflows_registry.get(workflow_name, {})
|