nextstrain / augur

Pipeline components for real-time phylodynamic analysis
https://docs.nextstrain.org/projects/augur/
GNU Affero General Public License v3.0
268 stars 128 forks source link

Port `translate-genbank-location` to `augur curate parse-genbank-location` [#1485] #1508

Closed genehack closed 6 days ago

genehack commented 1 week ago

Description of proposed changes

This ports translate-genbank-location from nextstrain/ingest to the augur curate sub-command parse-genbank-location.

It adds a command-line flag for providing the field name the location data is stored in; this flag defaults to geo_loc_name to support NCBI's recent change. I provided this to enable the command to also parse older data with the country field name.

Also adds type-hints and tests.

Related issue(s)

Checklist

codecov[bot] commented 1 week ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 69.53%. Comparing base (f6ee377) to head (ee3be71).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #1508 +/- ## ========================================== + Coverage 69.40% 69.53% +0.12% ========================================== Files 72 73 +1 Lines 7755 7788 +33 Branches 1900 1905 +5 ========================================== + Hits 5382 5415 +33 Misses 2087 2087 Partials 286 286 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

genehack commented 1 week ago

The one failing test is expected.