Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix silent parse bug #1712

Merged
merged 3 commits into from
Jan 14, 2025
Merged

Fix silent parse bug #1712

merged 3 commits into from
Jan 14, 2025

Conversation

huddlej
Copy link
Contributor

@huddlej huddlej commented Jan 8, 2025

Description of proposed changes

Transforms the strain name in the metadata, fixing a bug where augur parse only transformed invalid characters in the sequence output and not the metadata output, causing records with those characters to become unlinked in downstream analyses.

Related issue(s)

Closes #1427

Checklist

  • Automated checks pass
  • Check if you need to add a changelog message
  • Check if you need to add tests
  • Check if you need to update docs

Copy link

codecov bot commented Jan 8, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 72.90%. Comparing base (1688855) to head (a4c79c2).
Report is 4 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1712   +/-   ##
=======================================
  Coverage   72.90%   72.90%           
=======================================
  Files          79       79           
  Lines        8299     8299           
  Branches     1694     1694           
=======================================
  Hits         6050     6050           
  Misses       1961     1961           
  Partials      288      288           

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

augur/parse.py Outdated Show resolved Hide resolved
Modifies the existing functional tests for parse by adding invalid
characters (spaces and parentheses) which augur parse converts to either
nothing or underscores, respectively. Since parse only transforms strain
names in the sequence output and not the metadata, this change to the
input data causes the functional test to fail. This commit adds a
parallel copy of the metadata ("other") for use in the test where the id
column is an accession and not the strain name and we don't expect the
strain name to get transformed.
Transforms the strain name in the metadata, fixing a bug where augur
parse only transformed invalid characters in the sequence output and not
the metadata output, causing records with those characters to become
unlinked in downstream analyses.

Fixes #1427
Co-authored-by: Victor Lin <[email protected]>
@huddlej huddlej force-pushed the fix-silent-parse-bug branch from 4b0a2c3 to a4c79c2 Compare January 14, 2025 20:53
@huddlej huddlej merged commit 53a14a1 into master Jan 14, 2025
36 checks passed
@huddlej huddlej deleted the fix-silent-parse-bug branch January 14, 2025 21:23
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.

parse silently removes spaces from record ids in the sequence output but not in the metadata output
3 participants