Moved derive units to registry architectur
DeriveUnits are now owned by a DeriveRegistry which has its own routing thread to handle routing values to the different DeriveUnits
This commit is contained in:
+6
-5
@@ -123,7 +123,8 @@ representation.
|
||||
### `get_all_signal_descriptors() -> list[SignalDescriptor]`
|
||||
|
||||
Returns descriptors for every signal currently registered by connected
|
||||
connectors. The list is empty when no connectors have completed a handshake.
|
||||
connectors and bound derive units. The list is empty when no connectors have
|
||||
completed a handshake and no derive units are bound.
|
||||
|
||||
Connector membership is dynamic: a disconnected connector's signals are no
|
||||
longer returned.
|
||||
@@ -233,9 +234,9 @@ The parameter annotations must use the imported `ValueDescriptor` and
|
||||
`SignalDescriptor` classes shown above. The source string is executed with
|
||||
`exec()`, so only bind code from trusted sources.
|
||||
|
||||
The returned UUID identifies the bound unit. Binding invalid source or more
|
||||
than one function raises `CoreMultipleFunctionsFoundError`; an invalid function
|
||||
signature raises `DeriveUnitInvalidSignatureError`.
|
||||
The returned UUID identifies the bound unit. Binding source that defines more
|
||||
or fewer than one function raises `DeriveUnitMultipleFunctionsFoundError`; an
|
||||
invalid function signature raises `DeriveUnitInvalidSignatureError`.
|
||||
|
||||
### `unbind_derive_unit(unit_id: UUID) -> None`
|
||||
|
||||
@@ -252,5 +253,5 @@ Core-specific exceptions are defined in `dynalab_core.errors`.
|
||||
| Exception | Raised when |
|
||||
| --- | --- |
|
||||
| `CoreStateMismatchError` | `start()` is called after the core has already started or stopped. |
|
||||
| `CoreMultipleFunctionsFoundError` | A derive-unit source string does not define exactly one function. |
|
||||
| `DeriveUnitMultipleFunctionsFoundError` | A derive-unit source string does not define exactly one function. |
|
||||
| `DeriveUnitInvalidSignatureError` | A derive function's annotations or parameter order are invalid. |
|
||||
|
||||
Reference in New Issue
Block a user