ORIONIS API REFERENCE

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.

module documentation

Reflect dependency metadata from callables, constructors, and methods.

Function _build_dependencies Categorize explicit parameters after descriptor binding has been applied.
Function _cached_resolved_signature Return the cached dependency signature for target.
Function _clear_dependency_caches Invalidate shared signatures and registered derived metadata explicitly.
Function _get_resolved_signature Return dependency metadata without caching a bound method's receiver.
Function _get_signature Return the cached inspect signature for a target.
Function _inspect_annotations Read annotations while preserving unknown native deferred references.
Function _inspect_signature Inspect a signature while preserving unavailable native annotations.
Function _parameter_dependency Describe one non-variadic parameter using its default or annotation.
Function _register_signature_invalidator Register one dependent cache clearer without retaining reloaded callbacks.
Function _resolve_annotation Resolve a parameter annotation into its module, name, and type components.
Function _resolve_future_annotations Resolve available string annotations in a callable signature.
Function _resolve_parameter_hint Resolve one string hint independently of other unavailable references.
Constant _ANY_FULL_PATH Any full path used by reflection.
Constant _ANY_TYPE Any type used by reflection.
Constant _SKIP_KINDS Skip kinds used by reflection.
Variable _signature_invalidators Dependent cache clearers keyed by stable consumer identifiers.
def _build_dependencies(signature: inspect.Signature) -> Signature: (source)

Categorize explicit parameters after descriptor binding has been applied.

Parameters
signature:inspect.SignatureSignature containing only caller-supplied parameters.
Returns
orionis.introspection.dependencies.entities.signature.SignatureResolved and unresolved dependencies in declaration order.
@functools.lru_cache(maxsize=1024)
def _cached_resolved_signature(target: object, *, bound: bool = False) -> Signature: (source)

Return the cached dependency signature for target.

Notes

Cached exceptions are not stored by functools.lru_cache, so failures are raised again on subsequent calls.

Parameters
target:objectObject whose inspectable signature is resolved into dependencies.
bound:bool, optionalWhether the first positional parameter is supplied by method binding.
Returns
orionis.introspection.dependencies.entities.signature.SignatureDependency signature built from the target's inspectable signature.
Raises
ValueErrorRaised when the target signature cannot be inspected.
def _clear_dependency_caches(): (source)

Invalidate shared signatures and registered derived metadata explicitly.

Returns
NoneNo return value.
def _get_resolved_signature(target: object) -> Signature: (source)

Return dependency metadata without caching a bound method's receiver.

Parameters
target:objectCallable whose parameters are inspected.
Returns
orionis.introspection.dependencies.entities.signature.SignatureShared metadata keyed by the underlying function and binding mode.
@functools.lru_cache(maxsize=1024)
def _get_signature(target: object) -> inspect.Signature: (source)

Return the cached inspect signature for a target.

Parameters
target:objectCallable, method, function, or class to inspect.
Returns
inspect.SignatureCached signature object for the provided target.
def _inspect_annotations(target: object) -> dict[str, object]: (source)

Read annotations while preserving unknown native deferred references.

Parameters
target:objectClass, function, or module declaring annotations.
Returns
dict[str, object]Known annotation values and ForwardRef objects for unavailable names.
def _inspect_signature(target: object) -> inspect.Signature: (source)

Inspect a signature while preserving unavailable native annotations.

Parameters
target:objectCallable, method, function, or class to inspect.
Returns
inspect.SignatureRuntime values where available, with ForwardRef values for unknown names.
def _parameter_dependency(parameter: inspect.Parameter) -> Argument: (source)

Describe one non-variadic parameter using its default or annotation.

Parameters
parameter:inspect.ParameterExplicit parameter whose dependency metadata is required.
Returns
orionis.introspection.dependencies.entities.argument.ArgumentResolution metadata preserving the parameter's declared name and kind.
def _register_signature_invalidator(key: str, callback: Callable[[], None]): (source)

Register one dependent cache clearer without retaining reloaded callbacks.

Parameters
key:strStable identifier of the internal cache consumer.
callback:collections.abc.Callable[[], None]Function clearing that consumer's derived metadata.
Returns
NoneNo return value.
def _resolve_annotation(annotation: object) -> tuple[str, str, object]: (source)

Resolve a parameter annotation into its module, name, and type components.

Parameters
annotation:objectThe annotation object from an inspect.Parameter. May be a string (forward reference) or an actual type/class.
Returns
tuple[str, str, object]A three-element tuple (module_name, class_name, type_or_annotation) where module_name and class_name identify the annotation's origin, and type_or_annotation is the resolved type (or str for forward references).
def _resolve_future_annotations(target: object, signature: inspect.Signature) -> inspect.Signature: (source)

Resolve available string annotations in a callable signature.

Parameters
target:objectCallable declaring the annotations.
signature:inspect.SignatureSignature whose parameters may contain string annotations.
Returns
inspect.SignatureSignature with available types substituted and defaults preserved.
def _resolve_parameter_hint(annotation: str, globalns: dict[str, Any]) -> object: (source)

Resolve one string hint independently of other unavailable references.

Parameters
annotation:strParameter annotation requiring evaluation.
globalns:dict[str, typing.Any]Namespace of the callable's defining module.
Returns
objectResolved annotation, or None if the reference cannot be evaluated.
_ANY_FULL_PATH: str = (source)

Any full path used by reflection.

Value
f'{_ANY_MODULE}.{_ANY_NAME}'
_ANY_TYPE: type = (source)

Any type used by reflection.

Value
type(Any)

Skip kinds used by reflection.

Value
frozenset(set([inspect.Parameter.VAR_POSITIONAL, inspect.Parameter.VAR_KEYWORD])↵
)
_signature_invalidators: dict[str, Callable[[], None]] = (source)

Dependent cache clearers keyed by stable consumer identifiers.