bcgsc / mavis

Merging, Annotation, Validation, and Illustration of Structural variants
http://mavis.bcgsc.ca
GNU General Public License v3.0
72 stars 14 forks source link

touble finding samtools version #75

Closed RichardCorbett closed 6 years ago

RichardCorbett commented 6 years ago

MAVIS version: <1.6.10>

Python version: <3.6.1>

OS: <CentOS 6>

Expected Behaviour

SAMTools check success / no error

Actual Behaviour

I'm finding reports like the following in the output logs in the validate folders

Traceback (most recent call last): File "/gsc/pipelines/mavis/v1.6.10/venv/bin/mavis", line 11, in load_entry_point('mavis==1.6.10', 'console_scripts', 'mavis')() File "/gsc/pipelines/mavis/v1.6.10/venv/lib/python3.6/site-packages/mavis-1.6.10-py3.6.egg/mavis/main.py", line 522, in main File "/gsc/pipelines/mavis/v1.6.10/venv/lib/python3.6/site-packages/mavis-1.6.10-py3.6.egg/mavis/bam/read.py", line 169, in get_samtools_version ValueError: unable to parse samtools version number

Steps to Reproduce the Behaviour

ssh numbers
cd /projects/rcorbettprj2/POGHOMD
source /gsc/pipelines/mavis/production/venv/bin/activate
source /gsc/pipelines/mavis/environments/hg19.sh
mavis config -w config.cfg --library A36971 genome diseased False /projects/POG/POG_data/TESTCOLO829STAR/wgs/biop1_t_A36971/merge/hg19a_bwa-mem-0.7.6a/A36971_2_lanes_dupsFlagged.bam --library A36973 genome normal False /projects/POG/POG_data/TESTCOLO829STAR/wgs/blood1_n_A36973/merge/hg19a_bwa-mem-0.7.6a/A36973_1_lane_dupsFlagged.bam --assign A36971 testHOMD.txt --assign A36973 testHOMD.txt 

before and after I submit the jobs to the cluster I get:

which samtools
/projects/trans_scratch/transabyss/trans-ABySS/v1.4.10/bin/samtools

and running samtools without parameters seems to generate the require output for get_samtools_version()

samtools

Program: samtools (Tools for alignments in the SAM format)
Version: 1.2 (using htslib 1.2.1)

Usage:   samtools <command> [options]

Commands:
  -- indexing
         faidx       index/extract FASTA
         index       index alignment
  -- editing

I can't help but wonder if a different samtools is getting run underneath. What do you recommend?

thanks Richard

calchoo commented 6 years ago

Hey Richard,

Could you add a which samtools to one of the submit.sh and try submitting that to the cluster? I wonder if it has to do with the node not being able to see the samtools you're using.

Caleb

RichardCorbett commented 6 years ago

Thanks @calchoo,

before submitting, on the command line on the head node:

which samtools
/projects/trans_scratch/transabyss/trans-ABySS/v1.4.10/bin/samtools

while running on the node within mavis... which: no samtools in (/home/rcorbett/google-cloud-sdk/bin:=/projects/trans_scratch/transabyss/trans-ABySS/v1.4.10/bin/:/gsc/software/linux-x86_64-centos6/git-2.12.0/bin/:/gsc/pipelines/mavis/v1.6.10/venv/bin:/home/rcorbett/google-cloud-sdk/bin:=/usr/lib64/qt-3.3/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/rcorbett/unx_prog/:/usr/local/ubin/:/home/rcorbett/aligners/bedtools/BEDTools-Version-2.15.0/bin:/gsc/software/linux-x86_64-centos7/R-3.3.2/bin/:/home/rcorbett/.local/bin:/home/rcorbett/unx_prog/:/usr/local/ubin/:/home/rcorbett/aligners/bedtools/BEDTools-Version-2.15.0/bin:/gsc/software/linux-x86_64-centos7/R-3.3.2/bin/)

It looks like some old google cloud code I had in my environment was messing with the top PATH entry in my list (ie. the "=" was added somehow). Once I took that out of the picture I was able to run mavis.

I have jobs running now! Thanks!