Skip to content

Canonicalize + register Guatemala food_acquired (Phase 3 of #218) #571

Description

@ligon

Goal

Modernize Guatemala's food pipeline so Country('Guatemala').food_acquired() is canonical and the derived food_{expenditures,prices,quantities} surface via _FOOD_DERIVED — then retire the dead legacy food_prices_quantities_and_expenditures.py.

Why

Guatemala has food_acquired.py (country + 2000 wave) but in the legacy (j,t,i,units) shape (units='lbs' hardcoded), and food_acquired is unregistered → modern API returns empty (0,0). The legacy food_prices_quantities_and_expenditures.py is dead (KeyError('m')m came from the retired other_features).

Readiness: SMALLER

Has a sample table + data_scheme.yml. v is the region (degenerate cluster — fine for the v-join). So this is a straight canonicalize + register (Cambodia #108 pattern).

Steps

  1. Rewrite wave food_acquired.py → canonical (t,i,j,u,s) + [Quantity, Expenditure] (un-swap i/j, add acquisition-source s, real u).
  2. Register food_acquired (materialize: make) in data_scheme.yml.
  3. Acceptance bar (NOT equivalence-vs-legacy — that baseline doesn't build): canonical shape + is_this_feature_sane; derived food_* populate; Feature assembles named; source-traceable reconciliation against the raw .dta (sum all sources) + coverage counts.
  4. Retire the legacy script + Makefile rule + CONTENTS.org refs (same PR; coupled rollback).

Parent: #218. Design: slurm_logs/DESIGN_218_food_legacy_retirement.org (rev-2). Adversarial review: workflow wuiofz6p0 (11 confirmed findings).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions