aeat.adapters.persistence.storage.runtime_repository module

Runtime-owned SecureObjectRepository factories.

Builds SecureObjectRepository instances bound to the active profile’s unlocked storage route, so callers obtain a repository without resolving the storage namespace or key material themselves.

secure_object_repository_for_bucket(bucket_id, settings=None)[source]

Return a bucket-attached SecureObjectRepository through storage runtime.

Return type:

SecureObjectRepository

Parameters:
secure_object_repository_for_active_bucket()[source]

Return a SecureObjectRepository attached to the selected active profile bucket.

Return type:

SecureObjectRepository

secure_object_repository_for_active_bucket_or_default_route(settings=None)[source]

Return a SecureObjectRepository for the active bucket, or the process default.

This lower-level storage helper is for repository base classes that still support explicit injected/default SQL engines in tests and bootstrap-adjacent code. It does not catch active-bucket runtime errors: once a bucket is selected, route/session failures surface from secure_object_repository_for_bucket instead of falling back to a bare repository.

Return type:

SecureObjectRepository

Parameters:

settings (Settings | None)

secure_object_repository_for_cold_bootstrap_state(settings=None)[source]

Return a SecureObjectRepository for cold-root recovery reads.

This is the narrow bootstrap exception used before any active profile bucket pointer exists. Normal profile-bound code must use secure_object_repository_for_active_bucket or secure_object_repository_for_bucket so route/session mismatches fail closed at the storage runtime boundary.

Return type:

SecureObjectRepository

Parameters:

settings (Settings | None)