Skip to content

Add cohort_geometries() to access cohort GeoJSON metadata#1053

Open
adilraza99 wants to merge 4 commits intomalariagen:masterfrom
adilraza99:GH435-cohort-geometries
Open

Add cohort_geometries() to access cohort GeoJSON metadata#1053
adilraza99 wants to merge 4 commits intomalariagen:masterfrom
adilraza99:GH435-cohort-geometries

Conversation

@adilraza99
Copy link
Contributor

@adilraza99 adilraza99 commented Mar 5, 2026

Summary

Add a new cohort_geometries() method to expose cohort boundary geometries through the API.

Changes

  • add cohort_geometries() to AnophelesSampleMetadata
  • load GeoJSON cohort boundary data using the standard json library
  • add caching consistent with existing metadata access patterns
  • validate accepted cohort_set values
  • add tests and minimal GeoJSON fixtures

Impact

Provides access to cohort geometry metadata while keeping the API simple and dependency-free.

Part of #435

@codecov
Copy link

codecov bot commented Mar 6, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.28%. Comparing base (ab59c87) to head (cb24212).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1053      +/-   ##
==========================================
+ Coverage   90.25%   90.28%   +0.03%     
==========================================
  Files          51       51              
  Lines        5631     5650      +19     
==========================================
+ Hits         5082     5101      +19     
  Misses        549      549              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant