Skip to main content
Version: 0.7

config_settings

superduper.base.config_settings

Source code

load_secrets​

load_secrets(secrets_dir: str | None = None)
ParameterDescription
secrets_dirThe directory containing the secrets.

Load secrets directory into env vars.

ConfigError​

ConfigError(self,
/,
*args,
**kwargs)
ParameterDescription
args*args for Exception
kwargs**kwargs for Exception

An exception raised when there is an error in the configuration.

ConfigSettings​

ConfigSettings(self,
cls: Type,
environ: Optional[Dict] = None,
base: Optional[str] = None) -> None
ParameterDescription
clsThe Pydantic class to read.
environThe environment variables to read from.
baseThe base field of a loaded config file to use (e.g. "cluster" loads from r["cluster"])

Helper class to read a configuration from a dataclass.

Reads a dataclass class from a configuration file and environment variables.