Skip to content

fix #154#176

Merged
ravibandaru-lab merged 1 commit into
mainfrom
fix-154-dropped-chromosomes
May 26, 2026
Merged

fix #154#176
ravibandaru-lab merged 1 commit into
mainfrom
fix-154-dropped-chromosomes

Conversation

@jamesli124
Copy link
Copy Markdown
Collaborator

Fix for issue where multi_wps output is missing data when BED chromosomes and BAM header are sorted differently. multi_wps uses the header of input_file if it is a BAM or CRAM file. This means it was possible to write data out of order if the order of the BED was different from the input. Previous commits improved the error handling leading to TypeError: 'NoneType' object is not iterable, however the affected chromosomes were still being dropped.

  • intervals in site_bed are resorted to the order of the fragment file
  • tests added to verify change works. Will fail under old behavior
  • added test_wps._make_two_chrom_bam helper function to generate synthetic BAM files for test purposes

…omes and BAM header are sorted differently

    - intervals in site_bed are resorted to the order of the fragment file
    - tests added to verify change works. Will fail under old behavior
    - added test_wps._make_two_chrom_bam helper function to generate synthetic BAM files for test purposes
@jamesli124 jamesli124 linked an issue May 26, 2026 that may be closed by this pull request
Copy link
Copy Markdown
Collaborator

@ravibandaru-lab ravibandaru-lab left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great fix

@ravibandaru-lab ravibandaru-lab merged commit 19570b2 into main May 26, 2026
8 checks passed
@jamesli124 jamesli124 deleted the fix-154-dropped-chromosomes branch May 28, 2026 16:08
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.

Adjust WPS: TypeError: 'NoneType' object is not iterable

2 participants