mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-27 00:52:50 +00:00
EIMS_BUYER_REGION_CODES/WEREDA_CODES/CITY_CODES were hand-maintained, empty-by-default env vars — every buyer from a not-yet-seen area crashed filing until someone found the MoR code and redeployed. Happened three times in one afternoon (2026-08-17): Somali region, Fafan zone, Jigjiga woreda, even the Ethiopia country code were all unset on the triaplc.com deployment. Ethiopia's administrative divisions are fixed reference data, not buyer-specific config. Added ethiopia-geo-codes.ts, a static table (source: ethiopia_administrative_hierarchy_master.csv, supplied 2026-08-17 — a representative sample, not all ~1000 real woredas) merged in as the fallback under the existing env vars, which still win on a name collision — for a quick correction without a redeploy, or a buyer profile spelled differently than the table (already hit: DB has zone "Fafen", official spelling "Fafan"). Known limitation, documented in the file: zone/woreda names aren't always unique nationwide (e.g. "North Shewa" is both an Amhara and an Oromia zone) and Company stores region/zone/woreda as three independent strings with no parent linkage, so a flat name map can't always disambiguate. Only affects the optional City field — never blocks filing, unlike Region/Wereda.