1 new commit in galaxy-central:
https://bitbucket.org/galaxy/galaxy-central/changeset/10e0d2765f24/
changeset: 10e0d2765f24
user: greg
date: 2011-12-18 19:49:26
summary: Only persist the datatypes registry when the load_datatypes() method is called. Tools and metadata setting processes that create their own datatypes registry will use the existing temporary file rather than persisting the registry themselves.
affected #: 4 files
diff -r 4ee7b5f6b23db6f92bfe6b895bb6db5f4cf4d7b1 -r 10e0d2765f24c32f840be414d88bf813321e41b5 lib/galaxy/datatypes/registry.py
--- a/lib/galaxy/datatypes/registry.py
+++ b/lib/galaxy/datatypes/registry.py
@@ -174,6 +174,9 @@
self.log.debug( 'Loaded sniffer for datatype: %s' % dtype )
except Exception, exc:
self.log.warning( 'Error appending datatype %s to sniff_order, problem: %s' % ( dtype, str( exc ) ) )
+ # Persist the xml form of the registry into a temporary file so that it
+ # can be loaded from the command line by tools and set_metadata processing.
+ self.to_xml_file()
# Default values.
if not self.datatypes_by_extension:
self.datatypes_by_extension = {
@@ -466,4 +469,3 @@
os.write( fd, '</sniffers>\n' )
os.write( fd, '</datatypes>\n' )
os.close( fd )
- return os.path.abspath( filename )
diff -r 4ee7b5f6b23db6f92bfe6b895bb6db5f4cf4d7b1 -r 10e0d2765f24c32f840be414d88bf813321e41b5 lib/galaxy/jobs/__init__.py
--- a/lib/galaxy/jobs/__init__.py
+++ b/lib/galaxy/jobs/__init__.py
@@ -868,7 +868,7 @@
if config_root is None:
config_root = self.app.config.root
if datatypes_config is None:
- datatypes_config = self.app.datatypes_registry.to_xml_file()
+ datatypes_config = self.app.datatypes_registry.xml_filename
return self.external_output_metadata.setup_external_metadata( [ output_dataset_assoc.dataset for output_dataset_assoc in job.output_datasets ],
self.sa_session,
exec_dir = exec_dir,
diff -r 4ee7b5f6b23db6f92bfe6b895bb6db5f4cf4d7b1 -r 10e0d2765f24c32f840be414d88bf813321e41b5 lib/galaxy/tools/__init__.py
--- a/lib/galaxy/tools/__init__.py
+++ b/lib/galaxy/tools/__init__.py
@@ -1672,8 +1672,7 @@
# For the upload tool, we need to know the root directory and the
# datatypes conf path, so we can load the datatypes registry
param_dict['__root_dir__'] = param_dict['GALAXY_ROOT_DIR'] = os.path.abspath( self.app.config.root )
- datatypes_config = self.app.datatypes_registry.to_xml_file()
- param_dict['__datatypes_config__'] = param_dict['GALAXY_DATATYPES_CONF_FILE'] = datatypes_config
+ param_dict['__datatypes_config__'] = param_dict['GALAXY_DATATYPES_CONF_FILE'] = self.app.datatypes_registry.xml_filename
# Return the dictionary of parameters
return param_dict
diff -r 4ee7b5f6b23db6f92bfe6b895bb6db5f4cf4d7b1 -r 10e0d2765f24c32f840be414d88bf813321e41b5 lib/galaxy/tools/actions/metadata.py
--- a/lib/galaxy/tools/actions/metadata.py
+++ b/lib/galaxy/tools/actions/metadata.py
@@ -51,7 +51,7 @@
dataset_files_path = trans.app.model.Dataset.file_path,
output_fnames = None,
config_root = None,
- datatypes_config = trans.app.datatypes_registry.to_xml_file(),
+ datatypes_config = trans.app.datatypes_registry.xml_filename,
job_metadata = None,
kwds = { 'overwrite' : overwrite } )
incoming[ '__SET_EXTERNAL_METADATA_COMMAND_LINE__' ] = cmd_line
Repository URL: https://bitbucket.org/galaxy/galaxy-central/
--
This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.
1 new commit in galaxy-central:
https://bitbucket.org/galaxy/galaxy-central/changeset/da4342bc04c7/
changeset: da4342bc04c7
user: greg
date: 2011-12-18 15:16:52
summary: Send the persisted data types registry instead of None as the value of the datatypes_config parameter to the setup_external_metadata method when creating the cmd_line in the SetMetadataToolAction.execute() method. This eliminates the use of the hard-coded 'datatypes_conf.xml' file name when setting metadata externally.
affected #: 1 file
diff -r be0a75fd565845be5d6a9719552013548bb6a82f -r da4342bc04c779a50f50431fbec87d3d0c56576b lib/galaxy/tools/actions/metadata.py
--- a/lib/galaxy/tools/actions/metadata.py
+++ b/lib/galaxy/tools/actions/metadata.py
@@ -51,7 +51,7 @@
dataset_files_path = trans.app.model.Dataset.file_path,
output_fnames = None,
config_root = None,
- datatypes_config = None,
+ datatypes_config = trans.app.datatypes_registry.to_xml_file(),
job_metadata = None,
kwds = { 'overwrite' : overwrite } )
incoming[ '__SET_EXTERNAL_METADATA_COMMAND_LINE__' ] = cmd_line
Repository URL: https://bitbucket.org/galaxy/galaxy-central/
--
This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.
1 new commit in galaxy-central:
https://bitbucket.org/galaxy/galaxy-central/changeset/be0a75fd5658/
changeset: be0a75fd5658
user: jgoecks
date: 2011-12-17 20:29:23
summary: Trackster: fix bug in 13ba6909faae that prevented display in Dense mode.
affected #: 1 file
diff -r e65f4e9539144c882f4f07355a033f53a1963ddd -r be0a75fd565845be5d6a9719552013548bb6a82f static/scripts/trackster.js
--- a/static/scripts/trackster.js
+++ b/static/scripts/trackster.js
@@ -3966,10 +3966,8 @@
return this.summary_draw_height + SUMMARY_TREE_TOP_PADDING;
}
else {
- var rows_required = 1;
- if (mode === "no_detail" || mode === "Squish" || mode === "Pack") {
- var rows_required = this.incremental_slots(w_scale, result.data, mode);
- }
+ // All other modes require slotting.
+ var rows_required = this.incremental_slots(w_scale, result.data, mode);
// HACK: use dummy painter to get required height. Painter should be extended so that get_required_height
// works as a static function.
var dummy_painter = new (this.painter)(null, null, null, this.prefs, mode);
Repository URL: https://bitbucket.org/galaxy/galaxy-central/
--
This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.
1 new commit in galaxy-central:
https://bitbucket.org/galaxy/galaxy-central/changeset/e65f4e953914/
changeset: e65f4e953914
user: greg
date: 2011-12-16 23:08:35
summary: Always attempt to remove previously written temporary xml files when persisting the current datatypes registry.
affected #: 2 files
diff -r 48b3531465ee90f26680291971c837670ad0b7f0 -r e65f4e9539144c882f4f07355a033f53a1963ddd lib/galaxy/app.py
--- a/lib/galaxy/app.py
+++ b/lib/galaxy/app.py
@@ -126,8 +126,7 @@
try:
# If the datatypes registry was persisted, attempt to
# remove the temporary file in which it was written.
- tmp_filename = self.datatypes_registry.xml_filename
- if tmp_filename:
- os.unlink( tmp_filename )
+ if self.datatypes_registry.xml_filename is not None:
+ os.unlink( self.datatypes_registry.xml_filename )
except:
pass
diff -r 48b3531465ee90f26680291971c837670ad0b7f0 -r e65f4e9539144c882f4f07355a033f53a1963ddd lib/galaxy/datatypes/registry.py
--- a/lib/galaxy/datatypes/registry.py
+++ b/lib/galaxy/datatypes/registry.py
@@ -432,6 +432,14 @@
rval[ 'auto' ] = rval[ 'txt' ]
return rval
def to_xml_file( self ):
+ if self.xml_filename is not None:
+ # If persisted previously, attempt to remove
+ # the temporary file in which we were written.
+ try:
+ os.unlink( self.xml_filename )
+ except:
+ pass
+ self.xml_filename = None
fd, filename = tempfile.mkstemp()
self.xml_filename = filename
if self.converters_path_attr:
Repository URL: https://bitbucket.org/galaxy/galaxy-central/
--
This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.