mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Fix API handling of tools containing repeat statement with min set.
This commit is contained in:
@@ -1982,6 +1982,7 @@ class Tool( object, Dictifiable ):
|
||||
group_errors = [ ]
|
||||
any_group_errors = False
|
||||
rep_index = 0
|
||||
del group_state[:] # Clear prepopulated defaults if repeat.min set.
|
||||
while True:
|
||||
rep_name = "%s_%d" % ( key, rep_index )
|
||||
if not any( [ incoming_key.startswith(rep_name) for incoming_key in incoming.keys() ] ):
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
<tool id="min_repeat" name="min_repeat">
|
||||
<command>
|
||||
cat #for $q in $queries# ${q.input} #end for# > $out_file1 ;
|
||||
cat #for $q in $queries2# ${q.input2} #end for# > $out_file2
|
||||
</command>
|
||||
<inputs>
|
||||
<repeat name="queries" title="Dataset" min="1">
|
||||
<param name="input" type="data" label="Select" />
|
||||
</repeat>
|
||||
<repeat name="queries2" title="Dataset" min="1">
|
||||
<param name="input2" type="data" label="Select" />
|
||||
</repeat>
|
||||
</inputs>
|
||||
<outputs>
|
||||
<data name="out_file1" format="txt" />
|
||||
<data name="out_file2" format="txt" />
|
||||
</outputs>
|
||||
<tests>
|
||||
<test>
|
||||
<param name="input" value="simple_line.txt"/>
|
||||
<param name="input" value="simple_line.txt"/>
|
||||
<param name="input2" value="simple_line_alternative.txt"/>
|
||||
<output name="out_file1" file="simple_line_x2.txt"/>
|
||||
<output name="out_file2" file="simple_line_alternative.txt"/>
|
||||
</test>
|
||||
</tests>
|
||||
</tool>
|
||||
@@ -12,4 +12,5 @@
|
||||
<tool file="metadata.xml" />
|
||||
<tool file="output_order.xml" />
|
||||
<tool file="disambiguate_repeats.xml" />
|
||||
<tool file="min_repeat.xml" />
|
||||
</toolbox>
|
||||
Reference in New Issue
Block a user