Open JustinMoser opened 1 month ago
I am sorry for seeing this so late. Something has bugged my GitHub subscriptions and I just now got this in an email that is not my primary.
Nevertheless, I hope that this wasn't super time-sensitive. I will attempt to dig into this on the weekend.
Can I see an example of your issues in action? Specifically the error in the context of the code?
Describe the bug I am attempting to repackage the SMAca package using bamnostic in place of PySam, specifically using your
AlignmentFile
class in place of the PySam version. The problem I am facing is when I runsmaca --reference hg19 <BAM_FILE>
I get the following error:
Open-ended region while
until_eofis set to False
I have debugged the code and this is because in SMAca it iterates over the generator from the
fetch
method inAlignmentFile
for reading the various regions from the file however when it gets into the fetch method, and then into the_parse_region
method, all the arguments seem to beNone
and so for every region there is no start stop index and so it deems in an "Open-Ended" region, withuntil_eof
also defaulting to false. I have run the same BAM file through SMAca with PySam and it seems to run correctly and produce an output. The purpose of this task is to allow the SMAca package to run outside of a linux environment.This is being run on Mac OSX Sonoma with Python 3.10.14
Any idea why it replacing PySam with Bamnostic simply to read the AlignmentFile might cause the regions to not be read correctly?