1 new changeset in galaxy-central:
http://bitbucket.org/galaxy/galaxy-central/changeset/38899d79629b/
changeset: 38899d79629b
user: greg
date: 2011-07-11 20:48:12
summary: Fix for setting tool shed repository etadata multiple times when nothing in the repository has changed.
affected #: 1 file (178 bytes)
--- a/lib/galaxy/webapps/community/controllers/common.py Mon Jul 11 14:10:56 2011 -0400
+++ b/lib/galaxy/webapps/community/controllers/common.py Mon Jul 11 14:48:12 2011 -0400
@@ -146,10 +146,13 @@
metadata_dict[ 'tools' ] = [ tool_dict ]
except Exception, e:
invalid_tool_configs.append( ( name, str( e ) ) )
- repository_metadata = trans.model.RepositoryMetadata( repository.id, repository.tip, metadata_dict )
- trans.sa_session.add( repository_metadata )
- if not flush_needed:
- flush_needed = True
+ if metadata_dict:
+ # The metadata_dict dictionary will contain items only
+ # if the repository did not already have metadata set.
+ repository_metadata = trans.model.RepositoryMetadata( repository.id, repository.tip, metadata_dict )
+ trans.sa_session.add( repository_metadata )
+ if not flush_needed:
+ flush_needed = True
else:
message = "Repository does not include changeset revision '%s'." % str( ctx_str )
status = 'error'
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 changeset in galaxy-central:
http://bitbucket.org/galaxy/galaxy-central/changeset/0007cf69d1dc/
changeset: 0007cf69d1dc
user: greg
date: 2011-07-11 19:45:57
summary: Allow an admin user to manage repositories they do not own.
affected #: 1 file (61 bytes)
--- a/lib/galaxy/webapps/community/controllers/repository.py Mon Jul 11 13:34:23 2011 -0400
+++ b/lib/galaxy/webapps/community/controllers/repository.py Mon Jul 11 13:45:57 2011 -0400
@@ -214,7 +214,8 @@
if operation == "view_or_manage_repository":
repository_id = kwd.get( 'id', None )
repository = get_repository( trans, repository_id )
- if repository.user == trans.user:
+ is_admin = trans.user_is_admin()
+ if is_admin or repository.user == trans.user:
return trans.response.send_redirect( web.url_for( controller='repository',
action='manage_repository',
**kwd ) )
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 changeset in galaxy-central:
http://bitbucket.org/galaxy/galaxy-central/changeset/35c11787e690/
changeset: 35c11787e690
user: jgoecks
date: 2011-07-07 17:55:14
summary: Trackster: implement broad/wide incremental data fetching and add icons for data fetching.
affected #: 5 files (1.5 KB)
--- a/static/june_2007_style/blue/trackster.css Wed Jul 06 22:37:51 2011 -0400
+++ b/static/june_2007_style/blue/trackster.css Thu Jul 07 11:55:14 2011 -0400
@@ -51,3 +51,6 @@
.bookmark{background:white;border:solid #999 1px;border-right:none;margin:0.5em;margin-right:0;padding:0.5em;}
.bookmark .position{font-weight:bold;}
.delete-icon-container{float:right;}
+.icon{display:inline-block;width:16px;height:16px;}
+.icon.more-down{background:url('../images/fugue/arrow-transition-270-bw.png') no-repeat 0px 0px;}
+.icon.more-across{background:url('../images/fugue/arrow-transition-bw.png') no-repeat 0px 0px;}
--- a/static/june_2007_style/trackster.css.tmpl Wed Jul 06 22:37:51 2011 -0400
+++ b/static/june_2007_style/trackster.css.tmpl Thu Jul 07 11:55:14 2011 -0400
@@ -293,3 +293,16 @@
float:right;
}
+.icon {
+ display:inline-block;
+ width:16px;
+ height:16px;
+}
+.icon.more-down {
+ background:url('../images/fugue/arrow-transition-270-bw.png') no-repeat 0px 0px;
+}
+.icon.more-across{
+ background:url('../images/fugue/arrow-transition-bw.png') no-repeat 0px 0px;
+}
+
+
--- a/static/scripts/trackster.js Wed Jul 06 22:37:51 2011 -0400
+++ b/static/scripts/trackster.js Thu Jul 07 11:55:14 2011 -0400
@@ -172,7 +172,7 @@
// height of individual features within tracks. Feature height, then, should always be less
// than track height.
CHAR_HEIGHT_PX = 9, // FIXME: font size may not be static
- ERROR_PADDING = 18, // Padding at the top of tracks for error messages
+ ERROR_PADDING = 20, // Padding at the top of tracks for error messages
SUMMARY_TREE_TOP_PADDING = CHAR_HEIGHT_PX + 2,
// Maximum number of rows un a slotted track
MAX_FEATURE_DEPTH = 100,
@@ -369,13 +369,15 @@
//
// Set parameters based on request type.
//
+ var query_low = low;
if (req_type === this.DEEP_DATA_REQ) {
// Use same interval but set start_val to skip data that's already in cur_data.
$.extend(extra_params, {start_val: cur_data.data.length + 1});
}
else if (req_type === this.BROAD_DATA_REQ) {
- // Set low to be past the last feature returned.
- low = cur_data.data[cur_data.length-1][2] + 1;
+ // Set query low to be past the last feature returned so that an area of extreme feature depth
+ // is bypassed.
+ query_low = cur_data.data[cur_data.data.length - 1][2] + 1;
}
//
@@ -384,14 +386,19 @@
//
var
data_manager = this,
- new_data_request = this.load_data(low, high, resolution, extra_params)
+ new_data_request = this.load_data(query_low, high, resolution, extra_params)
new_data_available = $.Deferred();
// load_data sets cache to new_data_request, but use custom deferred object so that signal and data
// is all data, not just new data.
this.set_data(low, high, mode, new_data_available);
$.when(new_data_request).then(function(result) {
+ // Update data and message.
if (result.data) {
result.data = cur_data.data.concat(result.data);
+ if (result.message) {
+ // HACK: replace number in message with current data length. Works but is ugly.
+ result.message = result.message.replace(/[0-9]+/, result.data.length);
+ }
}
data_manager.set_data(low, high, mode, result);
new_data_available.resolve(result);
@@ -2209,18 +2216,29 @@
message_div = $("<div/>").addClass("tile-message").text(tile.message).
// -1 to account for border.
css({'height': ERROR_PADDING-1, 'width': tile.canvas.width}).appendTo(container_div),
- show_more_data_btn = $("<div/>").text("Show more").addClass("action-button").css({'padding-top': 0, 'padding-bottom':0}).appendTo(message_div);
+ more_down_icon = $("<a href='javascript:void(0);'/>").addClass("icon more-down").appendTo(message_div),
+ more_across_icon = $("<a href='javascript:void(0);'/>").addClass("icon more-across").appendTo(message_div);
container_div.append(canvas);
tile_element = container_div;
- // Set up actions for button.
- show_more_data_btn.click(function() {
+ // Set up actions for icons.
+ more_down_icon.click(function() {
// Mark tile as stale, request more data, and redraw track.
tile.stale = true;
track.data_manager.get_more_data(tile.low, tile.high, tile.resolution, {}, track.data_manager.DEEP_DATA_REQ);
track.draw();
}).dblclick(function(e) {
- // Do not propogate as this would normal zoom in.
+ // Do not propogate as this would normally zoom in.
+ e.stopPropagation();
+ });
+
+ more_across_icon.click(function() {
+ // Mark tile as stale, request more data, and redraw track.
+ tile.stale = true;
+ track.data_manager.get_more_data(tile.low, tile.high, tile.resolution, {}, track.data_manager.BROAD_DATA_REQ);
+ track.draw();
+ }).dblclick(function(e) {
+ // Do not propogate as this would normally zoom in.
e.stopPropagation();
});
}
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 changeset in galaxy-central:
http://bitbucket.org/galaxy/galaxy-central/changeset/84b20f29dfdf/
changeset: 84b20f29dfdf
user: kanwei
date: 2011-07-07 04:37:51
summary: Add tool version-string support to tool wrappers. Use the <version_string> tag to denote the command to run for the tool version, such as: tophat --version (see tophat wrapper change for example)
The tool version string will currently be appended to the Info string in the history dataset and you will be able to see it in the history pane, although this might be added to the database as well in the future.
affected #: 4 files (1.1 KB)
--- a/lib/galaxy/jobs/__init__.py Thu Jul 07 10:04:20 2011 +1000
+++ b/lib/galaxy/jobs/__init__.py Wed Jul 06 22:37:51 2011 -0400
@@ -271,7 +271,7 @@
class JobWrapper( object ):
"""
- Wraps a 'model.Job' with convience methods for running processes and
+ Wraps a 'model.Job' with convenience methods for running processes and
state management.
"""
def __init__( self, job, queue ):
@@ -284,6 +284,9 @@
self.sa_session = self.app.model.context
self.extra_filenames = []
self.command_line = None
+ # Tool versioning variables
+ self.version_string_cmd = None
+ self.version_string = ""
self.galaxy_lib_dir = None
# With job outputs in the working directory, we need the working
# directory to be set before prepare is run, or else premature deletion
@@ -311,6 +314,9 @@
param_dict = self.tool.params_from_strings( param_dict, self.app )
return param_dict
+ def get_version_string_path( self ):
+ return os.path.abspath(os.path.join(self.app.config.new_file_path, "GALAXY_VERSION_STRING_%s" % self.job_id))
+
def prepare( self ):
"""
Prepare the job to run by creating the working directory and the
@@ -389,6 +395,7 @@
extra_filenames.append( param_filename )
self.param_dict = param_dict
self.extra_filenames = extra_filenames
+ self.version_string_cmd = self.tool.version_string_cmd
return extra_filenames
def fail( self, message, exception=False ):
@@ -491,6 +498,12 @@
job.state = job.states.ERROR
else:
job.state = job.states.OK
+ if self.version_string_cmd:
+ version_filename = self.get_version_string_path()
+ if os.path.exists(version_filename):
+ self.version_string = "Tool version: %s" % open(version_filename).read()
+ os.unlink(version_filename)
+
if self.app.config.outputs_to_working_directory:
for dataset_path in self.get_output_fnames():
try:
@@ -541,7 +554,7 @@
dataset.blurb = 'done'
dataset.peek = 'no peek'
- dataset.info = context['stdout'] + context['stderr']
+ dataset.info = context['stdout'] + context['stderr'] + self.version_string
dataset.set_size()
if context['stderr']:
dataset.blurb = "error"
--- a/lib/galaxy/jobs/runners/__init__.py Thu Jul 07 10:04:20 2011 +1000
+++ b/lib/galaxy/jobs/runners/__init__.py Wed Jul 06 22:37:51 2011 -0400
@@ -1,10 +1,9 @@
import os, os.path
class BaseJobRunner( object ):
-
def build_command_line( self, job_wrapper, include_metadata=False ):
"""
- Compose the sequence of commands neccesary to execute a job. This will
+ Compose the sequence of commands necessary to execute a job. This will
currently include:
- environment settings corresponding to any requirement tags
- command line taken from job wrapper
@@ -15,9 +14,13 @@
# occur
if not commands:
return None
+ # Prepend version string
+ if job_wrapper.version_string_cmd:
+ commands = "%s &> %s; " % ( job_wrapper.version_string_cmd, job_wrapper.get_version_string_path() ) + commands
# Prepend dependency injection
if job_wrapper.dependency_shell_commands:
commands = "; ".join( job_wrapper.dependency_shell_commands + [ commands ] )
+
# Append metadata setting commands, we don't want to overwrite metadata
# that was copied over in init_meta(), as per established behavior
if include_metadata and self.app.config.set_metadata_externally:
--- a/lib/galaxy/tools/__init__.py Thu Jul 07 10:04:20 2011 +1000
+++ b/lib/galaxy/tools/__init__.py Wed Jul 06 22:37:51 2011 -0400
@@ -5,7 +5,7 @@
pkg_resources.require( "simplejson" )
-import logging, os, string, sys, tempfile, glob, shutil, types, urllib
+import logging, os, string, sys, tempfile, glob, shutil, types, urllib, subprocess
import simplejson
import binascii
from UserDict import DictMixin
@@ -395,6 +395,10 @@
self.redirect_url_params = ''
# Short description of the tool
self.description = util.xml_text(root, "description")
+ # Versioning for tools
+ self.version_string_cmd = None
+ if root.find("version_string") is not None:
+ self.version_string_cmd = root.find("version_string").text
# Parallelism for tasks, read from tool config.
parallelism = root.find("parallelism")
if parallelism is not None and parallelism.get("method"):
--- a/tools/ngs_rna/tophat_wrapper.xml Thu Jul 07 10:04:20 2011 +1000
+++ b/tools/ngs_rna/tophat_wrapper.xml Wed Jul 06 22:37:51 2011 -0400
@@ -1,5 +1,6 @@
<tool id="tophat" name="Tophat for Illumina" version="1.5.0"><description>Find splice junctions using RNA-seq data</description>
+ <version_string>tophat --version</version_string><requirements><requirement type="package">tophat</requirement></requirements>
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.