Write side effect to the context.
(data: str | bytes)
| 34 | |
| 35 | |
| 36 | def write_side_effect(data: str | bytes) -> None: |
| 37 | """Write side effect to the context.""" |
| 38 | try: |
| 39 | ctx = get_context() |
| 40 | except ContextNotInitializedError: |
| 41 | # Context is not initialized, nothing we can do |
| 42 | return |
| 43 | ctx.cell_lifecycle_registry.add(SideEffect(data)) |
| 44 | |
| 45 | |
| 46 | class PathState(State[Path]): |
no test coverage detected
searching dependent graphs…