energy_data_retrieval.hydro_catalogue.aha_reviewed#
Apply frozen, manually reviewed AHA aliases as historical observations only.
- energy_data_retrieval.hydro_catalogue.aha_reviewed.validate_inventory_review(batch, inventory)[source]#
Check source-row exclusivity and complete frozen partition before any write.
Accepted and held decisions must be disjoint. A source row cannot be assigned to multiple canonical plants. Older batches without selected_rows retain their existing row-equality contract.
- Parameters:
batch (dict[str, Any])
inventory (list[dict[str, Any]])
- Return type:
None
- energy_data_retrieval.hydro_catalogue.aha_reviewed.enrich_reviewed(existing, entry, *, source_id, now)[source]#
Reject changed identities and shared scopes; never match names automatically.
Capacity disagreements remain historical source observations, with separate review-ledger quarantines. No scalar rating, status or coordinate is changed.
- Parameters:
existing (dict[str, Any])
entry (dict[str, Any])
source_id (str)
now (str)
- Return type:
dict[str, Any]