Hi all. I'm sorry if this has been answered before, but I've searched and cannot find a solution other than "add SAMtools to your PATH", which I already have done. I can invoke samtools from BASH while logged in as the "galaxy" user I set up according to the production installation guide. When I try to add .bam files to a shared data library, I get the following message:
Traceback (most recent call last):
File "/home/galaxy/galaxy-dist/tools/data_source/upload.py", line 394, in
__main__()
File "/home/galaxy/galaxy-dist/tools/data_source/upload.py", line 386, in __main__
add_file( dataset, registry, json_file, output_path )
File "/home/galaxy/galaxy-dist/tools/data_source/upload.py", line 327, in add_file
if link_data_only == 'copy_files' and datatype.dataset_content_needs_grooming( output_path ):
File "/home/galaxy/galaxy-dist/lib/galaxy/datatypes/binary.py", line 79, in dataset_content_needs_grooming
version = self._get_samtools_version()
File "/home/galaxy/galaxy-dist/lib/galaxy/datatypes/binary.py", line 63, in _get_samtools_version
output = subprocess.Popen( [ 'samtools' ], stderr=subprocess.PIPE, stdout=subprocess.PIPE ).communicate()[1]
File "/usr/lib64/python2.6/subprocess.py", line 639, in __init__
errread, errwrite)
File "/usr/lib64/python2.6/subprocess.py", line 1220, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
I've taken a peek at the "dataset_content_needs_grooming" function and it looks like there is an OS call that executes "$ samtools" and splits the resulting string to access the version number of samtools (why couldn't the developers add a --version flag?). It seems to me like samtools cannot be executed, but I can't think of any reason why. Invoking samtools as user "galaxy" (with the user's associated PATH) gives:
Program: samtools (Tools for alignments in the SAM format)
Version: 0.1.12a (r862)
Usage: samtools <command> [options]
Command: view SAM<->BAM conversion
sort sort alignment file
pileup generate pileup output
mpileup multi-way pileup
faidx index/extract FASTA
tview text alignment viewer
index index alignment
idxstats BAM index stats (r595 or later)
fixmate fix mate information
glfview print GLFv3 file
flagstat simple stats
calmd recalculate MD/NM tags and '=' bases
merge merge sorted alignments
rmdup remove PCR duplicates
reheader replace BAM header
Does anyone know where I've gone wrong?
--
Matt Shirley
Ph.D Candidate - BCMB