Question: Syntax Error User-Provided Input
gravatar for danielfortin86
3.1 years ago by
United States
danielfortin86100 wrote:

I'm trying to modify a tool so that a user can type in data and pipe it from stdin (e.g. <echo "ACGTATGATGT") instead of providing it to galaxy as a fasta file. The command is included below. When I try to execute this command in galaxy I get a syntax error. However, when I view the "job command-line" and execute that outside of galaxy it functions correctly. Can anyone tell me what the problem is?


-query &lt;(echo -e "$input_seq.query2")



Fatal error: Exit code 2 ()
/nfs/seqdata/galaxy-data/job_working_directory/000/118/ line 17: syntax error near unexpected token `('
/nfs/seqdata/galaxy-data/job_working_directory/000/118/ line 17: `PACKAGE_BASE=/opt/shed_tools/blast+/2.2.29/devteam/ncbi_blast_plus/623f727cdff1; export PACKAGE_BASE; . /opt/shed_tools/blast+/2.2.29/devteam/ncbi_blast_plus/623f727cdff1/; blastn -version > /nfs/seqdata/galaxy-data/tmp/GALAXY_VERSION_STRING_118 2>&1; bash /opt/shed_tools/ -query <(echo -e "CTTCGAACCTCTGCCATCAGGACAGCCCCCAATCCCTATTATTGCCAGGTGGGGCTTGGCCCGGCCCAGTCCTGGCCTCTGCCACCAGGTGTCACCGAGGTTTCCCCAGCCAATGTTACTCTGCTCAGAG")     -db "/nfs/seqdata/blastdb/nt_nr"      -task blastn -evalue 0.001 -out "/nfs/seqdata/galaxy-data/files/000/dataset_350.dat"     -outfmt "6 std sallseqid score nident positive gaps ppos qframe sframe qseq sseq qlen slen salltitles"      -num_threads "${GALAXY_SLOTS:-8}"'

galaxy • 812 views
ADD COMMENTlink modified 3.1 years ago by Daniel Blankenberg ♦♦ 1.7k • written 3.1 years ago by danielfortin86100
gravatar for Daniel Blankenberg
3.1 years ago by
Daniel Blankenberg ♦♦ 1.7k
United States
Daniel Blankenberg ♦♦ 1.7k wrote:

It looks like you just need to turn a Galaxy parameter into a file for command-line usage. I would suggest using configfiles for this:


    <configfile name="fasta_file">${input_seq.query2}</configfile>

Then reference the filename as ${fasta_file}

ADD COMMENTlink written 3.1 years ago by Daniel Blankenberg ♦♦ 1.7k

That worked perfectly, thank you!

ADD REPLYlink written 3.1 years ago by danielfortin86100
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 86 users visited in the last hour