Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Biopython 1.78 not compatible because of Alphabet missing #307

Open
besnarda opened this issue Sep 30, 2020 · 2 comments
Open

Biopython 1.78 not compatible because of Alphabet missing #307

besnarda opened this issue Sep 30, 2020 · 2 comments

Comments

@besnarda
Copy link

besnarda commented Sep 30, 2020

Using ARIBA for gene detection, I tried to download the ncbi database with the following line

ariba getref ncbi out.ncbi

E-fetching 5795 genbank records from BioProject PRJNA313047 and writing to.  This may take a while.
Traceback (most recent call last):
  File "/appli/conda-env/bioinfo/ariba-2.14.6/bin/ariba", line 312, in <module>
    args.func(args)
  File "/appli/conda-env/bioinfo/ariba-2.14.6/lib/python3.6/site-packages/ariba/tasks/getref.py", line 11, in run
    getter.run(options.outprefix)
  File "/appli/conda-env/bioinfo/ariba-2.14.6/lib/python3.6/site-packages/ariba/ref_genes_getter.py", line 664, in run
    exec('self._get_from_' + self.ref_db + '(outprefix)')
  File "<string>", line 1, in <module>
  File "/appli/conda-env/bioinfo/ariba-2.14.6/lib/python3.6/site-packages/ariba/ref_genes_getter.py", line 620, in _get_from_ncbi
    from Bio.Alphabet import generic_dna
  File "/appli/conda-env/bioinfo/ariba-2.14.6/lib/python3.6/site-packages/Bio/Alphabet/__init__.py", line 21, in <module>
    "Bio.Alphabet has been removed from Biopython. In many cases, the alphabet can simply be ignored and removed from scripts. In a few cases, you may need to specify the ``molecule_type`` as an annotation on a SeqRecord for your script to work correctly. Please see https://biopython.org/wiki/Alphabet for more information."
ImportError: Bio.Alphabet has been removed from Biopython. In many cases, the alphabet can simply be ignored and removed from scripts. In a few cases, you may need to specify the ``molecule_type`` as an annotation on a SeqRecord for your script to work correctly. Please see https://biopython.org/wiki/Alphabet for more information.

As reported there it seems to be because of Biopython 1.78.
I will try downgrading to Biopython 1.77 to see if it solves the issue.

@Jonathan-Abrahams
Copy link

Did this work for you? If possible, could you provide a few lines on how to downgrade biopython?

@besnarda
Copy link
Author

besnarda commented Nov 1, 2020

Sorry for the late response! In case you are still stuck:
It did work for the Alphabet issue, but i encountered other issues that I wasn't able to solve so I didn't explore this tool further.
I didn't made the downgrade myself so I can't point you how to do it for sure.
If you are using conda, I believe you can try (I have not try it though).
conda install Biopython=1.77

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

No branches or pull requests

2 participants