@@ -166,7 +166,12 @@ def __process_raw_inputs( self, tool_inputs, raw_inputs, parent_context=None ):
166166 # an infinite loop - hence the "case_value is not None"
167167 # check.
168168 expanded_inputs [ case_context .for_state () ] = expanded_case_value
169-
169+ elif isinstance ( value , galaxy .tools .parameters .grouping .Section ):
170+ context = ParamContext ( name = value .name , parent_context = parent_context )
171+ for r_name , r_value in value .inputs .iteritems ():
172+ expanded_input = self .__process_raw_inputs ( { context .for_state (): r_value }, raw_inputs , parent_context = context )
173+ if expanded_input :
174+ expanded_inputs .update ( expanded_input )
170175 elif isinstance ( value , galaxy .tools .parameters .grouping .Repeat ):
171176 repeat_index = 0
172177 while True :
@@ -364,6 +369,13 @@ def expand_input_elems( root_elem, prefix="" ):
364369 __pull_up_params ( root_elem , cond_elem )
365370 root_elem .remove ( cond_elem )
366371
372+ section_elems = root_elem .findall ( 'section' )
373+ for section_elem in section_elems :
374+ new_prefix = __prefix_join ( prefix , section_elem .get ( "name" ) )
375+ expand_input_elems ( section_elem , new_prefix )
376+ __pull_up_params ( root_elem , section_elem )
377+ root_elem .remove ( section_elem )
378+
367379
368380def __append_prefix_to_params ( elem , prefix ):
369381 for param_elem in elem .findall ( 'param' ):
0 commit comments