pblischak / HyDe

Hybridization detection using phylogenetic invariants
http://hybridization-detection.readthedocs.io
GNU General Public License v3.0
41 stars 15 forks source link

Installation of HyDe : problem in make test #29

Open snehasjoshi opened 1 year ago

snehasjoshi commented 1 year ago

Hi I am trying to install Hyde in virtual linux machine. I created a virtual environment with python3.6. and installed HyDe. The installation was completed but got following error after running: make test

Testing run_hyde.py (full analysis). run_hyde.py -i examples/snake-data.txt -m examples/snake-map.txt -n 52 -t 7 -s 8466 -o out Traceback (most recent call last): File "/home/sneha/venv_3.6/bin/run_hyde.py", line 4, in import('pkg_resources').run_script('phyde==0.4.3', 'run_hyde.py') File "/home/sneha/venv_3.6/lib/python3.6/site-packages/pkg_resources/init.py", line 664, in run_script self.require(requires)[0].run_script(script_name, ns) File "/home/sneha/venv_3.6/lib/python3.6/site-packages/pkg_resources/init.py", line 1435, in run_script .format(**locals()), pkg_resources.ResolutionError: Script 'scripts/run_hyde.py' not found in metadata at '/home/sneha/venv_3.6/lib/python3.6/site-packages/phyde-0.4.3-py3.6.egg-info' make: *** [Makefile:7: test] Error 1

Can anyone help me with this? Where did I go wrong in installation

snehasjoshi commented 1 year ago

I figured out where the problem was, although I am not sure why this happened. The folder "Scripts" was not loaded in the "phyde-0.4.3-py3.6.egg-info" folder but instead was present in another folder labelled "phyde-0.4.3-py3.6-linux-x86_64.egg". I just copied the "Scripts" folder into "phyde-0.4.3-py3.6.egg-info", and it started working smoothly. This could be due to me running the software on python virtual environment on a virtual Linux machine. Putting this here just in case anyone comes across a similar issue

pblischak commented 1 year ago

Thanks for this great comment! I appreciate you sharing your experience to help out other folks

I tried installing HyDe in a clean conda environment on my computer as well (mac) and the only issue that I ran into was that I had to upgrade my version of Python (3.6 didn't work but 3.8 did)

My overall guess is that there may be differences in how environment managers (conda vs. venv) and operating systems (mac vs. linux) treat "installable" scripts like run_hyde.py. I think this is more standardized in recent version of Python, so I think I will may need to revisit the package requirements and build instructions to make sure they are up to date