Epic: #51 · S5 · depends on #61 (S0); uses #53 counts · supersedes #12 · story implementation
Problem (C-15)
Upload metadata lacks structured provenance (lookup version is only in a free-text description; no region, cell/unmapped counts, fill count). FAO can't audit what produced their data.
Build shape (per the epic design contract)
delivery/provenance.py (representation-free): build_provenance(...) -> dict from primitives — lookup_version, region, expected_cell_count, actual_cell_count, unmapped_count (+ fill_count if S2 provides it). No pandas.
- Manager: attach the dict to both
dsm.upload_data(...) metadata payloads (_save).
Acceptance criteria
Files
views_postprocessing/delivery/provenance.py (new), unfao/managers/unfao.py (_save), tests/.
Epic: #51 · S5 · depends on #61 (S0); uses #53 counts · supersedes #12 ·
storyimplementationProblem (C-15)
Upload metadata lacks structured provenance (lookup version is only in a free-text description; no region, cell/unmapped counts, fill count). FAO can't audit what produced their data.
Build shape (per the epic design contract)
delivery/provenance.py(representation-free):build_provenance(...) -> dictfrom primitives —lookup_version,region,expected_cell_count,actual_cell_count,unmapped_count(+fill_countif S2 provides it). No pandas.dsm.upload_data(...)metadata payloads (_save).Acceptance criteria
delivery/provenance.pypure + pandas-free; unit-tested on the metadata dict.Files
views_postprocessing/delivery/provenance.py(new),unfao/managers/unfao.py(_save),tests/.