cadrumo.adapters.outbound.storage._google_drive_metadata module

Google Drive response-metadata parsing and terminal-failure contracts.

class DriveStoragePreconditionCondition(*values)[source]

Bases: StrEnum

Closed terminal conditions for observed Google Drive provider failures.

API_CLIENT_AVAILABLE
REQUEST_AUTHORIZED
TARGET_PRESENT
REQUEST_CONFLICT_FREE
REQUEST_WITHIN_QUOTA
REQUEST_AVAILABLE
REQUEST_TRANSPORT_AVAILABLE
RESPONSE_IDENTIFIER_PRESENT
OWNERSHIP_ALIGNED
RESPONSE_MAPPING
NAMESPACE_PRESENT
OBJECT_PRESENT
MEDIA_PAYLOAD_BYTES
METADATA_SIZE_VALID
METADATA_MODIFIED_TIME_VALID
METADATA_APP_PROPERTIES_VALID
drive_external_verdict(condition, *, facts, outcome)[source]

Project an observed Drive-provider refusal through the public no-action authority.

Parameters:
metadata_from_drive_entry(entry, *, namespace, object_key_hmac)[source]

Convert a Drive files().get/list response into provider metadata.

Return type:

ProviderObjectMetadata

Parameters:
drive_storage_app_properties(entry)[source]

Return the validated app-owned metadata for a Drive storage object.

Return type:

DriveAppProperties

Parameters:

entry (dict[str, object])

drive_storage_content_hash(entry)[source]

Return the validated storage content hash for a Drive read.

Return type:

str

Parameters:

entry (dict[str, Any])