churchmanlab / genewalk

GeneWalk identifies relevant gene functions for a biological context using network representation learning
https://churchman.med.harvard.edu/genewalk
BSD 2-Clause "Simplified" License
127 stars 14 forks source link

AttributeError: module 'typing' has no attribute 'NoReturn #68

Closed ri23 closed 2 years ago

ri23 commented 2 years ago

Command: genewalk --project RNAseq9 --genes cluster9genelist.txt --id_type custom --network_source sif_annot --network_file fullnetwork.txt --base_folder Genewalk --nproc 8

Error:

Traceback (most recent call last):
  File "/n/groups/churchman/Genewalk/genewalkenv/bin/genewalk", line 5, in <module>
    from genewalk.cli import main
  File "/n/groups/churchman/Genewalk/genewalkenv/lib/python3.6/site-packages/genewalk/cli.py", line 20, in <module>
    from genewalk.plot import GW_Plotter
  File "/n/groups/churchman/Genewalk/genewalkenv/lib/python3.6/site-packages/genewalk/plot.py", line 10, in <module>
    import plotly.express as px
  File "/n/groups/churchman/Genewalk/genewalkenv/lib/python3.6/site-packages/plotly/__init__.py", line 34, in <module>
    from plotly import (
  File "/n/groups/churchman/Genewalk/genewalkenv/lib/python3.6/site-packages/plotly/io/__init__.py", line 6, in <module>
    from . import orca, kaleido
  File "/n/groups/churchman/Genewalk/genewalkenv/lib/python3.6/site-packages/plotly/io/orca.py", line 1, in <module>
    from ._orca import (
  File "/n/groups/churchman/Genewalk/genewalkenv/lib/python3.6/site-packages/plotly/io/_orca.py", line 15, in <module>
    import tenacity
  File "/n/groups/churchman/Genewalk/genewalkenv/lib/python3.6/site-packages/tenacity/__init__.py", line 184, in <module>
    class RetryError(Exception):
  File "/n/groups/churchman/Genewalk/genewalkenv/lib/python3.6/site-packages/tenacity/__init__.py", line 191, in RetryError
    def reraise(self) -> t.NoReturn:
AttributeError: module 'typing' has no attribute 'NoReturn'

Genewalk$ pip freeze

certifi==2021.10.8
charset-normalizer==2.0.12
click==8.0.3
cycler==0.10.0
dataclasses==0.8
decorator==4.4.2
docopt==0.6.2
Flask==2.0.3
funcsigs==1.0.2
genewalk==1.5.3
gensim==3.8.3
goatools==1.1.12
idna==3.3
importlib-metadata==4.8.3
itsdangerous==2.0.1
Jinja2==3.0.3
kiwisolver==1.3.1
MarkupSafe==2.0.1
matplotlib==3.3.4
mock==2.0.0
networkx==2.5.1
nose==1.3.7
numpy==1.19.5
package-name==0.1
pandas==0.25.3
patsy==0.5.2
pbr==1.10.0
Pillow==8.4.0
plotly==5.6.0
pydot==1.4.2
pyparsing==2.1.10
python-dateutil==2.8.2
pytz==2021.3
requests==2.27.1
scipy==1.5.4
seaborn==0.11.2
six==1.10.0
smart-open==5.2.1
statsmodels==0.12.2
tenacity==8.0.1
typing_extensions==4.1.1
urllib3==1.26.8
virtualenv==15.1.0
Werkzeug==2.0.3
xlrd==1.2.0
XlsxWriter==3.0.2
zipp==3.6.0
ri23 commented 2 years ago

Problem lies with plotly v5.6.0. Current solution: pip install plotly==4.14.3 Then rerun GeneWalk

bgyori commented 2 years ago

This might also be due to an old Python 3.6 release like 3.6.0 that could be updated at least to a newer 3.6 release.

ri23 commented 2 years ago

Indeed python 3.6.0 was used to run.