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
Trying to run gtf2bed from GFFUtils, release v. 0.12.0, with Python 3.10 which I have in my conda environment, results in the following error:
$ gtf2bed -h
Traceback (most recent call last):
File "/XXX/bin/gtf2bed", line 5, in <module>
from GFFUtils.cli.gtf2bed import main
File "/ZZZ/lib/python3.10/site-packages/GFFUtils/cli/gtf2bed.py", line 9, in <module>
from ..GTFFile import GTFIterator
File "/ZZZ/lib/python3.10/site-packages/GFFUtils/GTFFile.py", line 83, in <module>
from .GFFFile import GFFFile
File "/ZZZ/lib/python3.10/site-packages/GFFUtils/GFFFile.py", line 93, in <module>
from collections import Iterator
ImportError: cannot import name 'Iterator' from 'collections' (/ZZZ/lib/python3.10/collections/__init__.py)
The text was updated successfully, but these errors were encountered:
Hello @january3 sorry you've encountered a problem with this package. I'm doing minimal support for GFFUtils now, as it doesn't seem to be used much and other projects are taking up most of my time these days.
As you say that you're using conda, you might consider trying the gtf2bed utility provided by the BEDOPS package instead - this can be installed directly into a conda environment using e.g. conda install -c bioconda bedops (see https://anaconda.org/bioconda/bedops - the BEDOPS documentation can be found at https://bedops.readthedocs.io/en/latest/index.html).
Alternatively if you wanted to persevere with GFFUtils (and are confident with editing the Python source code) then I think you would need to edit the import of Iterator in GFFUtils/GFFFile.py to be:
from collections.abc import Iterator
and then reinstall. However I haven't had an opportunity to test this out yet, so if you did take this approach then please let me know how you get on.
Otherwise if it is very important than I can take a look next week at trying to update the package so that it works with more up-to-date Python.
Sorry not to be more helpful right now - good luck!
Trying to run gtf2bed from GFFUtils, release v. 0.12.0, with Python 3.10 which I have in my conda environment, results in the following error:
The text was updated successfully, but these errors were encountered: