THE ORIONIS API
Build with clarity.
Explore the building blocks of an async-first Python framework. Every module, class, and method — connected, searchable, and ready to build with.
class documentation
Define the contract for catch implementations.
| Async Method | capture |
Observe an exception through the active failure runtime. |
| Async Method | exception |
Handle an exception in the current kernel context. |
async def capture(self, exception:
BaseException, *, context: FailureContext) -> FailureReceipt | None:
(source)
¶
overridden in
orionis.failure.CatchObserve an exception through the active failure runtime.
Preserve compatibility by delegating to the active runtime without requiring a dependency-injection scope.
| Parameters | |
exception:BaseException | Original exception instance to observe. |
context:orionis.failure.entities.context.FailureContext | Immutable execution metadata for the failure. |
| Returns | |
orionis.failure.entities.context.FailureReceipt or None | Delivery status, or None if no runtime is active or the exception represents cancellation or process control. |
@abstractmethod
async def exception(self, exception: BaseException, request: Request | TransportAdapter | None = None) -> Response | None:
(source)
¶
overridden in
orionis.failure.CatchHandle an exception in the current kernel context.
| Parameters | |
exception:BaseException | Original exception instance to handle. |
request:Request or TransportAdapter or None, optional | HTTP request or transport adapter used for presentation, when available. |
| Returns | |
orionis.http.responses.Response or None | Response produced by presentation, or None when no response is available. |
| Raises | |
RuntimeError | If no application scope or kernel context is active. |
BaseException | The primary failure if presentation fails or times out. Genuine caller cancellation and process-control signals remain unchanged. |