mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Bugfix: Hadn't implemented clean way to iterate of collection element names in tools.
Perhaps stretching the definition of bugfix here to get this in next-stable.
This commit is contained in:
@@ -272,6 +272,12 @@ class DatasetCollectionWrapper( object, HasDatasets ):
|
||||
def is_collection( self ):
|
||||
return True
|
||||
|
||||
def __getitem__( self, key ):
|
||||
if isinstance( key, int ):
|
||||
return self.element_instance_list[ key ]
|
||||
else:
|
||||
return self.element_instances[ key ]
|
||||
|
||||
def __getattr__( self, key ):
|
||||
return self.element_instances[ key ]
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<tool id="collection_paired_test" name="paired_test" version="0.1.0">
|
||||
<command>
|
||||
cat $f1.forward $f1.reverse >> $out1;
|
||||
cat $f1.forward $f1['reverse'] >> $out1;
|
||||
</command>
|
||||
<inputs>
|
||||
<param name="f1" type="data_collection" collection_type="paired" />
|
||||
|
||||
Reference in New Issue
Block a user