Teichlab / tracer

TraCeR - reconstruction of T cell receptor sequences from single-cell RNAseq data
Other
122 stars 48 forks source link

Bio.Alphabet has been removed from Biopython #103

Closed cramirezs closed 3 years ago

cramirezs commented 3 years ago

Hi,

I installed TraCeR with python 3.6 as follows:

conda create --name tracer python=3.6
conda activate tracer
pip install -r requirements.txt
conda install -c taugspurger statsmodels=0.8.0
python setup.py install
tracer test -p 4 -c tracer.conf
# tools' paths were added to tracer.conf too

But then I got this error.

Traceback (most recent call last):
  File "/home/ciro/bin/miniconda3/envs/tracer/bin/tracer", line 33, in <module>
    sys.exit(load_entry_point('tracer==0.5', 'console_scripts', 'tracer')())
  File "/home/ciro/bin/miniconda3/envs/tracer/lib/python3.6/site-packages/pkg_resources/__init__.py", line 473, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "/home/ciro/bin/miniconda3/envs/tracer/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2843, in load_entry_point
    return ep.load()
  File "/home/ciro/bin/miniconda3/envs/tracer/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2447, in load
    return self.resolve()
  File "/home/ciro/bin/miniconda3/envs/tracer/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2453, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "/home/ciro/bin/miniconda3/envs/tracer/lib/python3.6/site-packages/tracer-0.5-py3.6.egg/tracerlib/launcher.py", line 8, in <module>
    from tracerlib.tasks import Assembler, Summariser, Tester, Builder
  File "/home/ciro/bin/miniconda3/envs/tracer/lib/python3.6/site-packages/tracer-0.5-py3.6.egg/tracerlib/tasks.py", line 11, in <module>
    from tracerlib import io, core
  File "/home/ciro/bin/miniconda3/envs/tracer/lib/python3.6/site-packages/tracer-0.5-py3.6.egg/tracerlib/io.py", line 16, in <module>
    from tracerlib.tracer_func import process_chunk, find_possible_alignments
  File "/home/ciro/bin/miniconda3/envs/tracer/lib/python3.6/site-packages/tracer-0.5-py3.6.egg/tracerlib/tracer_func.py", line 29, in <module>
    from Bio.Alphabet import IUPAC
  File "/home/ciro/bin/miniconda3/envs/tracer/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.

Could you help me with this?

Thank you!

mstubb commented 3 years ago

Hi,

Try installing again with this branch: https://github.com/Teichlab/tracer/tree/fix-biopython-ver

I've changed the version of Biopython in requirements.txt to be v.177 which still contains Bio.Alphabet. That should fix it for now, please let me know if it works.

Thanks!

Mike

cramirezs commented 3 years ago

That worked!

Thank you very much, Ciro

mstubb commented 3 years ago

Great!

diazdc commented 3 years ago

Hello, was this fix merged to master? I'm still getting the same error. Thanks.

mstubb commented 3 years ago

Hi @diazdc,

Yes, this has been merged to master.

Cheers,

Mike