zheminzhou / PEPPAN

Phylogeny Enhanded Prediction of PAN-genome
https://doi.org/10.1101/2020.01.03.894154
GNU General Public License v3.0
39 stars 10 forks source link

Bug in "PEPPA.py" #5

Closed EnriqueDoster closed 4 years ago

EnriqueDoster commented 4 years ago

Hello and thank you in advance for your time.

I am attempting to use your PEPPA tool, but I tried running the "PEPPA.py" script on a few samples and I'm getting the following error:

$ python3 /usr/local/PEPPA/PEPPA.py -p peppa_output -t 20 --metagenome *assemble.result.gff.gz
2020-05-09 00:44:27.765050      COMMAND: /usr/local/PEPPA/PEPPA.py -p peppa_output -t 20 align_out.SRR9879519_assemble.result.1.gff.gz align_out.SRR9879537_assemble.result.2.gff.gz align_out.SRR9879542_assemble.result.3.gff.gz align_out.SRR9879548_assemble.result.4.gff.gz align_out.SRR9879577_assemble.result.5.gff.gz
Traceback (most recent call last):
  File "/usr/local/PEPPA/PEPPA.py", line 1909, in <module>
    ortho()
  File "/usr/local/PEPPA/PEPPA.py", line 1839, in ortho
    del old_predictions, n, g
UnboundLocalError: local variable 'n' referenced before assignment

Could this be a bug in the script or could I have complicated things by trying to containerize PEPPA with Singularity? Thank you so much for your help!

Best, Enrique

zheminzhou commented 4 years ago

This error was triggered because there was no valid gene in your inputs (GFF files). I have updated the script such that the problem can be reported correctly. Meanwhile, please update to the latest version of PEPPA using 'pip install --upgrade bio-peppa', and try 'PEPPA --testunit' to check whether the program runs correctly.