Skip to main content

Module uuid_hex

Module uuid_hex 

Source
Expand description

UUID ↔ 32-char hex string conversions.

Python’s SQLAlchemy stores UUIDs as 32-character hex strings (no hyphens) in SQLite. These helpers ensure the Rust database layer uses the same format, so the two SDKs can share a database file.

Functions§

from_hex
Parse a 32-char hex string (or hyphenated UUID) back to Uuid.
from_hex_opt
Parse an optional hex string back to Option<Uuid>.
to_hex
Convert a Uuid to the 32-char hex format used by Python’s SQLAlchemy.
to_hex_opt
Convert an Option<Uuid> to an optional hex string.