You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, cljam's BAM writer supports simultaneous writing of a BAM file and its index file. This feature can be enabled by specifying true as the second argument of cljam.io.sam/writer. There are two problematic behaviors around this:
Index file writing is only performed if SO:coordinate is specified in the BAM file header
If SO:coordinate is not specified, enabling index file writing is ignored, and no index file is created without any error
The BAM indexer can also create BAM index files although it does not check for SO:coordinate in the BAM file header and always creates an index file
This is not only inconsistent with the BAM writer's behavior but also can result in invalid index files if the input BAM file is not sorted
I think the following changes can be made to improve usability and consistency:
If index file writing is enabled for the BAM writer and SO:coordinate is not specified in the BAM file header, an error should be raised to tell the user that the BAM writer didn't succeed in generating an index file
The BAM indexer should also check for SO:coordinate in the input BAM file header and raise an error if SO:coordinate is not specified, ensuring consistency with the BAM writer
Note that these changes will introduce breaking changes in that they will cause errors in situations where no errors were found previously.
The text was updated successfully, but these errors were encountered:
Currently, cljam's BAM writer supports simultaneous writing of a BAM file and its index file. This feature can be enabled by specifying
true
as the second argument ofcljam.io.sam/writer
. There are two problematic behaviors around this:SO:coordinate
is specified in the BAM file headerSO:coordinate
is not specified, enabling index file writing is ignored, and no index file is created without any errorSO:coordinate
in the BAM file header and always creates an index fileI think the following changes can be made to improve usability and consistency:
SO:coordinate
is not specified in the BAM file header, an error should be raised to tell the user that the BAM writer didn't succeed in generating an index fileSO:coordinate
in the input BAM file header and raise an error ifSO:coordinate
is not specified, ensuring consistency with the BAM writerNote that these changes will introduce breaking changes in that they will cause errors in situations where no errors were found previously.
The text was updated successfully, but these errors were encountered: