diff --git a/lib/galaxy/jobs/runners/drmaa.py b/lib/galaxy/jobs/runners/drmaa.py
index 62206f165d1..1fb01e89927 100644
--- a/lib/galaxy/jobs/runners/drmaa.py
+++ b/lib/galaxy/jobs/runners/drmaa.py
@@ -15,7 +15,6 @@ from galaxy.jobs import JobDestination
from galaxy.jobs.handler import DEFAULT_JOB_PUT_FAILURE_MESSAGE
from galaxy.jobs.runners import AsynchronousJobState, AsynchronousJobRunner
from galaxy.util import asbool
-from pulsar.managers.util.drmaa import DrmaaSessionFactory
drmaa = None
@@ -62,6 +61,7 @@ class DRMAAJobRunner( AsynchronousJobRunner ):
'feature, please install it or correct the '
'following error:\n%s: %s' %
(exc.__class__.__name__, str(exc)))
+ from pulsar.managers.util.drmaa import DrmaaSessionFactory
# Subclasses may need access to state constants
self.drmaa_job_states = drmaa.JobState
diff --git a/lib/galaxy/tools/actions/__init__.py b/lib/galaxy/tools/actions/__init__.py
index 9b010c144ec..d70fd8fe53a 100644
--- a/lib/galaxy/tools/actions/__init__.py
+++ b/lib/galaxy/tools/actions/__init__.py
@@ -7,7 +7,7 @@ from six import string_types
from galaxy import model
from galaxy.exceptions import ObjectInvalid
from galaxy.model import LibraryDatasetDatasetAssociation
-from galaxy.tools.parameters.basic import DataCollectionToolParameter, DataToolParameter
+from galaxy.tools.parameters.basic import DataCollectionToolParameter, DataToolParameter, RuntimeValue
from galaxy.tools.parameters.wrapped import WrappedParameters
from galaxy.tools.parameters import update_param
from galaxy.util import ExecutionTimer
@@ -54,8 +54,8 @@ class DefaultToolAction( object ):
def visitor( input, value, prefix, parent=None, **kwargs ):
def process_dataset( data, formats=None ):
- if not data:
- return data
+ if not data or isinstance( data, RuntimeValue ):
+ return None
if formats is None:
formats = input.formats
if not data.datatype.matches_any( formats ):
diff --git a/lib/galaxy/web/security/__init__.py b/lib/galaxy/web/security/__init__.py
index 29726ee6ea9..4a2ed331a97 100644
--- a/lib/galaxy/web/security/__init__.py
+++ b/lib/galaxy/web/security/__init__.py
@@ -54,13 +54,13 @@ class SecurityHelper( object ):
# Encrypt
return id_cipher.encrypt( s ).encode( 'hex' )
- def encode_dict_ids( self, a_dict, kind=None ):
+ def encode_dict_ids( self, a_dict, kind=None, skip_startswith=None ):
"""
Encode all ids in dictionary. Ids are identified by (a) an 'id' key or
(b) a key that ends with '_id'
"""
for key, val in a_dict.items():
- if key == 'id' or key.endswith('_id'):
+ if key == 'id' or key.endswith('_id') and ( skip_startswith is None or not key.startswith( skip_startswith ) ):
a_dict[ key ] = self.encode_id( val, kind=kind )
return a_dict
diff --git a/lib/galaxy/webapps/galaxy/api/tools.py b/lib/galaxy/webapps/galaxy/api/tools.py
index fd88db5f7b4..26f97f8e7c1 100644
--- a/lib/galaxy/webapps/galaxy/api/tools.py
+++ b/lib/galaxy/webapps/galaxy/api/tools.py
@@ -284,7 +284,7 @@ class ToolsController( BaseAPIController, UsesVisualizationMixin ):
# so it's possible to figure out which newly created elements
# correspond with which tool file outputs
output_dict[ 'output_name' ] = output_name
- outputs.append( trans.security.encode_dict_ids( output_dict ) )
+ outputs.append( trans.security.encode_dict_ids( output_dict, skip_startswith="metadata_" ) )
for job in vars.get('jobs', []):
rval[ 'jobs' ].append( self.encode_all_ids( trans, job.to_dict( view='collection' ), recursive=True ) )
diff --git a/test-data/biom1_metadata_test.txt b/test-data/biom1_metadata_test.txt
new file mode 100644
index 00000000000..c4514806f24
--- /dev/null
+++ b/test-data/biom1_metadata_test.txt
@@ -0,0 +1,11 @@
+table_rows: __ob__u__sq__2__sq__, u__sq__3__sq__, u__sq__4__sq__, u__sq__5__sq__, u__sq__8__sq__, u__sq__9__sq__, u__sq__10__sq__, u__sq__11__sq__, u__sq__12__sq__, u__sq__14__sq__, u__sq__15__sq__, u__sq__16__sq__, u__sq__17__sq__, u__sq__18__sq__, u__sq__22__sq__, u__sq__23__sq__, u__sq__25__sq__, u__sq__28__sq__, u__sq__29__sq____cb__
+table_matrix_element_type: float
+table_format: Biological Observation Matrix 1.0.0
+table_generated_by: BIOM-Format 2.1.5
+table_matrix_type: sparse
+table_shape: __ob__19, 2__cb__
+table_format_url: http://biom-format.org
+table_date: 2016-05-26T16:43:45.614267
+table_type: OTU table
+table_id: None
+table_columns: __ob__u__sq__SAMPLE_1__sq__, u__sq__SAMPLE_2__sq____cb__
\ No newline at end of file
diff --git a/test-data/input_taxonomy.biom1 b/test-data/input_taxonomy.biom1
new file mode 100644
index 00000000000..e1c0a5315fb
--- /dev/null
+++ b/test-data/input_taxonomy.biom1
@@ -0,0 +1 @@
+{"id": "None","format": "Biological Observation Matrix 1.0.0","format_url": "http://biom-format.org","matrix_type": "sparse","generated_by": "BIOM-Format 2.1.5","date": "2016-05-26T16:43:45.614267","type": "OTU table","matrix_element_type": "float","shape": [19, 2],"data": [[1,0,160.0],[1,1,242.0],[6,0,1.0],[6,1,1.0],[7,0,3.0],[7,1,4.0],[12,0,13.0],[12,1,36.0],[14,0,1.0],[14,1,5.0],[15,0,1.0],[16,0,1.0],[16,1,3.0]],"rows": [{"id": "2", "metadata": {"taxonomy": ["d__Archaea"]}},{"id": "3", "metadata": {"taxonomy": ["d__Bacteria"]}},{"id": "4", "metadata": {"taxonomy": ["d__Archaea", "p__Crenarchaeota"]}},{"id": "5", "metadata": {"taxonomy": ["d__Archaea", "p__Euryarchaeota"]}},{"id": "8", "metadata": {"taxonomy": ["d__Bacteria", "p__AC1"]}},{"id": "9", "metadata": {"taxonomy": ["d__Bacteria", "p__AD3"]}},{"id": "10", "metadata": {"taxonomy": ["d__Bacteria", "p__Acidobacteria"]}},{"id": "11", "metadata": {"taxonomy": ["d__Bacteria", "p__Actinobacteria"]}},{"id": "12", "metadata": {"taxonomy": ["d__Bacteria", "p__AncK6"]}},{"id": "14", "metadata": {"taxonomy": ["d__Bacteria", "p__Armatimonadetes"]}},{"id": "15", "metadata": {"taxonomy": ["d__Bacteria", "p__BHI80-139"]}},{"id": "16", "metadata": {"taxonomy": ["d__Bacteria", "p__BRC1"]}},{"id": "17", "metadata": {"taxonomy": ["d__Bacteria", "p__Bacteroidetes"]}},{"id": "18", "metadata": {"taxonomy": ["d__Bacteria", "p__CD12"]}},{"id": "22", "metadata": {"taxonomy": ["d__Bacteria", "p__Chlorobi"]}},{"id": "23", "metadata": {"taxonomy": ["d__Bacteria", "p__Chloroflexi"]}},{"id": "25", "metadata": {"taxonomy": ["d__Bacteria", "p__Cyanobacteria"]}},{"id": "28", "metadata": {"taxonomy": ["d__Bacteria", "p__EM19"]}},{"id": "29", "metadata": {"taxonomy": ["d__Bacteria", "p__EM3"]}}],"columns": [{"id": "SAMPLE_1", "metadata": null},{"id": "SAMPLE_2", "metadata": null}]}
\ No newline at end of file
diff --git a/test/functional/tools/metadata_biom1.xml b/test/functional/tools/metadata_biom1.xml
new file mode 100644
index 00000000000..e20ec3652a0
--- /dev/null
+++ b/test/functional/tools/metadata_biom1.xml
@@ -0,0 +1,28 @@
+
+ cp "${input_metadata_values}" "${output_of_input_metadata}"
+
+ table_rows: ${input_biom1.metadata.table_rows}
+table_matrix_element_type: ${input_biom1.metadata.table_matrix_element_type}
+table_format: ${input_biom1.metadata.table_format}
+table_generated_by: ${input_biom1.metadata.table_generated_by}
+table_matrix_type: ${input_biom1.metadata.table_matrix_type}
+table_shape: ${input_biom1.metadata.table_shape}
+table_format_url: ${input_biom1.metadata.table_format_url}
+table_date: ${input_biom1.metadata.table_date}
+table_type: ${input_biom1.metadata.table_type}
+table_id: ${input_biom1.metadata.table_id}
+table_columns: ${input_biom1.metadata.table_columns}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/test/functional/tools/sample_datatypes_conf.xml b/test/functional/tools/sample_datatypes_conf.xml
index 28cb5ff2df7..3891cad99c4 100644
--- a/test/functional/tools/sample_datatypes_conf.xml
+++ b/test/functional/tools/sample_datatypes_conf.xml
@@ -13,5 +13,6 @@
+
-
\ No newline at end of file
+
diff --git a/test/functional/tools/samples_tool_conf.xml b/test/functional/tools/samples_tool_conf.xml
index 60c7d5edb54..bbbeed7395f 100644
--- a/test/functional/tools/samples_tool_conf.xml
+++ b/test/functional/tools/samples_tool_conf.xml
@@ -24,6 +24,7 @@
+