Closed kriemo closed 7 years ago
I think if such a change would be included, it also requires an update to setup.py
by including something like install_requires(['pysam>=0.9']
, otherwise people with pysam 0.8.* that now have a working version of htseq suddenly become incompatible after upgrading htseq only. Maybe even better try to use try: and except: to make it compatible with both? Could you add the change and make a pull request? If @simon-anders accepts your change you will then get the credits for it as it will be linked to your account and you're pretty close already :)
we are working on pysam 0.9+ compatibility. for now we have a version that works with pysam 0.9 and python3 but not python2: check out the python3 branch.
Not sure whether pysam 0.9+ compatibility will be backported to python2 anytime soon.
@kriemo: Pull requests #14 and #15 make htseq compatible with pysam 0.9+ for both python2 and python3. Support for pysam<=0.8.x will probably drop because of their API changes. You can try the code in those PRs.
I recently upgraded to Pysam v. 0.9.0 and now HTSeq fails to correctly search for alignments within a genomicInterval from a BAM_Reader object.
Here's the error code and an example.
I tracked down the
_hasIndex
function in pysam and the problem is that the_hasIndex
function was renamed tohas_index
in thecalignmentfile.pyx
. This change happened in pysam version 0.8.4 I believe.I edited the
HTSeq/__init__.py
script line 977to
reinstalled HTSeq and then the error went away and my scripts ran normally again. I issued a pull request which fixes this error.