[galaxy-dev] xml tool wrapper conditional

2012-02-06 Thread Holger Klein
Dear all,

I'm working on a tool wrapper which for a sequence scoring tool.
It's supposed to score sequences either using a library installed to
galaxy (tool-data/models.loc) or datasets from the user history.

I tried to implement this behavior using the conditional / when
value mechanism, simplified code follows below.

Using locally installed models (from models.loc) fails with NotFound:
cannot find 'models', although in the details view of the failed tool
run model database points to the right file.

Using the model file from the history works.

Defining _only_ locally installed models from models.loc also works
(removing the conditional stuff and leaving only the part inside when
value='local' /when).

The commandline might look a bit strange but is correct.

Can anybody spot what is going wrong here?

Regards,
Holger




--

command
  calcModels --scoreFasta -- --fa $fasta_in --bgFa $fasta_background
  --models $models  $output_table
/command

inputs
  param format=fasta name=fasta_in type=data label=Input Fasta
File /

  param format=fasta name=fasta_background type=data
label=Background Fasta File /

  conditional name=ModelSource
param name=models type=select label=model source
help=History or installed models? value=local
  option value=localLocally installed models/option
  option value=historyModels from your history/option
/param

when value=local
  param name=models type=select label=model database
options from_file=models.loc
  column name=name index=1/
  column name=value index=2/
/options
/param
/when

when value=history
  param name=models type=data format=tabular label=model
database /
/when
  /conditional
/inputs




-- 
Dr. Holger Klein
Core Facility Bioinformatics
Institute of Molecular Biology gGmbH (IMB)
http://www.imb-mainz.de/
Tel: +49(6131) 39 21511
___
Please keep all replies on the list by using reply all
in your mail client.  To manage your subscriptions to this
and other Galaxy lists, please use the interface at:

  http://lists.bx.psu.edu/


Re: [galaxy-dev] xml tool wrapper conditional

2012-02-06 Thread Sarah Diehl
I'm only guessing here, but maybe the issue is that the parameter names 
are all the same (namely model). Did you try with only unique names? 
Especially this one:


 param name=models type=select label=model source
help=History or installed models? value=local

should get it's own name.

Sarah


On 02/06/2012 03:38 PM, Holger Klein wrote:

Dear all,

I'm working on a tool wrapper which for a sequence scoring tool.
It's supposed to score sequences either using a library installed to
galaxy (tool-data/models.loc) or datasets from the user history.

I tried to implement this behavior using theconditional  /when
value  mechanism, simplified code follows below.

Using locally installed models (from models.loc) fails with NotFound:
cannot find 'models', although in the details view of the failed tool
run model database points to the right file.

Using the model file from the history works.

Defining _only_ locally installed models from models.loc also works
(removing theconditional  stuff and leaving only the part insidewhen
value='local'  /when).

The commandline might look a bit strange but is correct.

Can anybody spot what is going wrong here?

Regards,
Holger




--

command
   calcModels --scoreFasta -- --fa $fasta_in --bgFa $fasta_background
   --models $models  $output_table
/command

inputs
   param format=fasta name=fasta_in type=data label=Input Fasta
File /

   param format=fasta name=fasta_background type=data
label=Background Fasta File /

   conditional name=ModelSource
 param name=models type=select label=model source
help=History or installed models? value=local
   option value=localLocally installed models/option
   option value=historyModels from your history/option
 /param

 when value=local
   param name=models type=select label=model database
options from_file=models.loc
column name=name index=1/
column name=value index=2/
/options
/param
 /when

 when value=history
   param name=models type=data format=tabular label=model
database /
 /when
   /conditional
/inputs






___
Please keep all replies on the list by using reply all
in your mail client.  To manage your subscriptions to this
and other Galaxy lists, please use the interface at:

 http://lists.bx.psu.edu/