Annotate rule fails
Hi,
I'm having some issues with the annotate
rule. Any ideas on what might be wrong, or any pointers I could investigate?
(IMP_pipeline) [imp_test]$ impy -e "IMP_SUDO=sudo" --threads 20 -d /db/IMP -a megahit run -m samples/2809_v1_1.fastq.gz -m samples/2809_v1_2.fastq.gz -o 2809_v1 --single-omics
Executing IMP command:
docker run --net=host --rm --name home_fredrik_boulund_workspace_tmp_imp_test_2809_v1 -v /db/IMP:/home/imp/databases -v /home/fredrik.boulund/workspace_tmp/imp_test/2809_v1:/home/imp/output -v /home/fredrik.boulund/workspace_tmp/imp_test/samples:/home/imp/data -e "LOCAL_USER_ID=`id -u $USER`" -e "LOCAL_GROUP_ID=`id -g $USER`" -e IMP_SUDO="sudo" -e IMP_BINNING_METHOD="maxbin" -e MEMTOTAL="8" -e MEMCORE="2" -e THREADS="20" -e MG="/home/imp/data/2809_v1_1.fastq.gz /home/imp/data/2809_v1_2.fastq.gz" -e MT="" -e IMP_ASSEMBLER="megahit" -e IMP_STEPS="preprocessing assembly analysis binning report" docker-r3lab.uni.lu/imp/imp:1.4.1 snakemake -s /home/imp/code/Snakefile
groupmod: GID '100' already exists
Provided cores: 1
Rules claiming more threads will be scaled down.
Job counts:
count jobs
1 ALL
1 ANALYSIS
1 ASSEMBLY
1 BINNING
1 PREPROCESSING
1 REPORT
1 annotate
1 assembly_contig_length
1 call_gene_depth
1 diagramm
1 download_librairies_files
1 fastqc_preprocessed
1 fastqc_raw
1 krona
1 local_librarie_files
1 make_report
1 maxbin
1 maxbin_contig2bin
1 metaquast
1 reads_count
1 rename_stat_output
1 variant_calling
1 visualize
1 visualize_maxbin
1 vizbin
25
rule annotate:
input: Assembly/mg.assembly.merged.fa, /home/imp/databases/cm/Bacteria.i1i, /home/imp/databases/genus/Staphylococcus.phr, /home/imp/databases/hmm/CLUSTERS.hmm.h3f, /home/imp/databases/kingdom/Archaea/sprot.phr, Analysis/tbl2asn.updated
output: Analysis/annotation/annotation.filt.gff, Analysis/annotation/prokka.faa, Analysis/annotation/prokka.fna, Analysis/annotation/prokka.ffn, Analysis/annotation/prokka.fsa
Error in job annotate while creating output files Analysis/annotation/annotation.filt.gff, Analysis/annotation/prokka.faa, Analysis/annotation/prokka.fna, Analysis/annotation/prokka.ffn, Analysis/annotation/prokka.fsa.
RuleException:
CalledProcessError in line 13 of /home/imp/code/rules/Analysis/prokka.rule:
Command '
### prokka by default will look databases where is located the binary.
### we have to softlink to put the binary somewhere and the databases somewhere else.
if [[ "/home/imp/databases" = /* ]]
then
PP=/home/imp/databases;
else
PP=$PWD//home/imp/databases;
fi
DD=$(dirname $(which prokka))/../db
if [[ ! -L $DD ]]
then
CUR=$PWD
echo "Softlinking $DD to $PP"
cd $(dirname $(which prokka))/.. && ln -fs $PP db
cd $CUR
fi
rm -rf Analysis/annotation/
prokka --force --outdir Analysis/annotation --prefix prokka --cpus 20 --metagenome Assembly/mg.assembly.merged.fa >> Analysis/annotation.log 2>&1
# Prokka gives a gff file with a long header and with all the contigs at the bottom. The command below removes the
# And keeps only the gff table.
LN=`grep -Hn "^>" Analysis/annotation/prokka.gff | head -n1 | cut -f2 -d ":" || if [[ $? -eq 141 ]]; then true; else exit $?; fi`
LN1=1
LN=$(($LN-$LN1))
head -n $LN Analysis/annotation/prokka.gff | grep -v "^#" | sort | uniq | grep -v "^==" > Analysis/annotation/annotation.filt.gff
' returned non-zero exit status 2
File "/usr/lib/python3.4/concurrent/futures/thread.py", line 54, in run
Removing output files of failed job annotate since they might be corrupted:
Analysis/annotation/prokka.faa, Analysis/annotation/prokka.fna, Analysis/annotation/prokka.ffn, Analysis/annotation/prokka.fsa
Will exit after finishing currently running jobs.
Exiting because a job execution failed. Look above for error message