custom datatypes and data_collections

We have some custom datatypes (hep.mc.root for instance) defined very simply in datatypes_conf.xml like so:

<datatype extension="hep.mc.root" type="galaxy.datatypes.binary:Binary" subclass="true" display_in_upload="true" description="ROOT binary file."/>

In a tool we are creating we wish to have as input-data a data collection which has data elements of this type. We have this data collection (a list with X number of hep.mc.root files ) in the history.

However, in the input field of the tool, only collections with type png or empty lists are possible to select (we have other tools producing png files, and thus they are in the history). png is one of the standard types from galaxy. Could it be that for Dataset Collections the new custom hep.mc.root datatype does not exist, thus can not be selected?

The screenshot:
The collections suggested in the input field are either empty or contain png files. The MC Hists item 3895 is the one I would like to be able to select, but it is not suggested in the collection list in the input field to the left as you see.

The tool wrapper looks like the following:

<tool id="plotHistograms_maiken" name="Plot Histograms MaikenTest" profile="16.04" version="1.0.0">
<description></description>
<requirements>
	<requirement type="package" version="1.0.0">fys5555_py3</requirement>
</requirements>
  <command>
    <![CDATA[
	     #set $origname_data = $dataFile.element_identifier
	     #set $orignames_mc = []
	     #set $galaxynames_mc = []
	     #for $d in $mcFileList
	     #set $tmpname=$d.element_identifier
	     #silent orignames_mc.append("%s" % $tmpname)
	     #silent galaxynames_mc.append("%s" % $d)
	     #end for
	     python '/storage/shared/software/Scripts/ATLASOpenData/13TeV/copyForMakePlots.py' '$dataFile' '$origname_data' '$galaxynames_mc' '$orignames_mc';
	     python '/storage/shared/software/Scripts/ATLASOpenData/13TeV/MakePlots.py' '$channel';
    ]]> 
  </command>
  <inputs>
    <param name="channel" type="select" label="Channel">
      <option value="ee" selected="true">ee</option>
      <option value="uu">uu</option>
    </param>
    <param name="dataFile" type="data"  format="hep.data.root"  label="Data root file" />
    <param name="mcFileList" type="data_collection"  label="MC root file(s)" />
  </inputs>
  
  <outputs>
 	 <collection name="output" type="list" label="Conventional Analysis Plots"> 
		         <discover_datasets pattern="(?P&lt;designation&gt;.+)\.png"  directory="Histograms/Plots"  ext="png"  recurse="true" visible="false" from_tool_provided_metadata="true" />
	 
		 </collection>
  </outputs>
</tool>

Update: ?roblem solved. It was confusion related to the ext option in the discover_datasets parameter and the format option in the collection parameter in the tool that generated the list in the first place:

We had:

<collection name="output2" type="list" format="hep.mc.root"  label="MC Hists">
    <discover_datasets pattern="(?P&lt;designation&gt;.+.*MC.*)\.root" directory="Histograms/"   ext="root" recurse="true"  />
  </collection>

And then changed to

<collection name="output2" type="list"  label="MC Hists">
    <discover_datasets pattern="(?P&lt;designation&gt;.+.*MC.*)\.root" directory="Histograms/"   ext="hep.mc.root" recurse="true"  />
  </collection>

Seems the format in the collection parameter is just ignored, and the ext is taken as the format. We had the wrong extention name “root” instead of “hep.mc.root”.

Problem solved!