RasmussenLab / phamb

Downstream processing of VAMB binning for Viral Elucidation
MIT License
46 stars 8 forks source link

Update shebang lines in phamb python scripts #46

Closed jmtsuji closed 2 years ago

jmtsuji commented 2 years ago

Thanks for making this helpful viral binning tool! I have a minor request to improve the usability of the python scripts in the phamb directory, based on an issue I ran into while running the test data for phamb. See below:

Problem description

Using phamb 1.0.1, installed via conda on a linux server, I got the following error when running the test command:

Command:

phamb/run_RF.py test/contigs.fna.gz test/clusters.tsv test testout

Error:

phamb/run_RF.py: /usr/bin/python: bad interpreter: No such file or directory

Possible causes

I think the issue is caused by the shebang line in phamb/run_RF.py:

#!/usr/bin/python

Because I am running phamb in a conda env, my python is located in ${CONDA_PREFIX}/bin/python. I'm running a very clean system and don't have python installed globally.

Proposed solution

Change the shebang line of phamb/run_RF.py to a more universal shebang (discussed here):

#!/usr/bin/env python

Similarly, phamb/run_RF_modules.py and phamb/split_contigs.py could be changed to use the same shebang (they are currently using #!/bin/python).

I'm happy to make a PR for this minor change, if it helps. Thanks again!

joacjo commented 2 years ago

Hi Jackson

Thanks for reporting this and your suggestion. I tested your solution and it resolved the issue, so I will update the Master asap :) Please let me know if it's not working in your env.

Best, Joachim

jmtsuji commented 2 years ago

Thanks @joacjo !