_config_schema¶
rhiza_hooks._config_schema
¶
Canonical schema for .rhiza/template.yml — keys, aliases, normalization.
This is the single source of truth for the shape of a rhiza template config. It
owns the canonical key sets (:data:REQUIRED_KEYS, :data:OPTIONAL_KEYS,
:data:VALID_KEYS), the :data:KEY_ALIASES map from accepted alias spellings to
their canonical names, and :func:normalize_config, which rewrites a raw mapping
so every alias becomes its canonical key.
Both the config validator (:mod:rhiza_hooks.check_rhiza_config) and the
template-bundles reader (:mod:rhiza_hooks._bundles_config) import from here so
the alias handling never drifts between them. The module is a leaf: it imports
nothing from the rest of :mod:rhiza_hooks.
normalize_config(config)
¶
Normalize configuration by replacing aliases with canonical keys.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
config
|
dict[str, Any]
|
Raw configuration dictionary |
required |
Returns:
| Type | Description |
|---|---|
dict[str, Any]
|
Normalized configuration with aliases replaced |