Python Environment Variables
This page documents environment variables that affect Python workflows. The Python runtime inherits the full Rust environment variable surface.
The Python runner (cloaca.DefaultRunner) reads the same environment variables as the Rust DefaultRunner — DSN, log level, registry-variable namespace, multi-tenant search path. See the Rust environment variables reference for the full inventory.
There is no distinct CLOACA_* environment-variable namespace. The Python module
reads the same variables as the Rust runtime; the only Cloacina-defined
convention is CLOACINA_VAR_* (the variable registry, below).
The variable registry resolves named connections, secrets, and config from
CLOACINA_VAR_<NAME> environment variables at runtime. From Python:
import cloaca
broker = cloaca.var("KAFKA_BROKER") # reads CLOACINA_VAR_KAFKA_BROKER; raises if unset
threshold = cloaca.var_or("MODEL_THRESHOLD", "0.5") # reads CLOACINA_VAR_MODEL_THRESHOLD, else "0.5"
export CLOACINA_VAR_KAFKA_BROKER=localhost:9092
export CLOACINA_VAR_MODEL_THRESHOLD=0.85
See the Variable Registry how-to for details.