1 new changeset in galaxy-central:
http://bitbucket.org/galaxy/galaxy-central/changeset/040d6f59f464/
changeset: r5095:040d6f59f464
user: kanwei
date: 2011-02-18 23:47:07
summary: Update distutils egg to 0.7, and use the provided HTML output writer to do rst->html conversion. Remove old code that previously did this. This fixes a bug where an extra "</div>" was appended after every output, resulting in the tool config not showing in workflows, in IE.
affected #: 5 files (115 bytes)
--- a/eggs.ini Fri Feb 18 16:21:11 2011 -0500
+++ b/eggs.ini Fri Feb 18 17:47:07 2011 -0500
@@ -32,7 +32,7 @@
amqplib = 0.6.1
Beaker = 1.4
decorator = 3.1.2
-docutils = 0.4
+docutils = 0.7
drmaa = 0.4b3
elementtree = 1.2.6_20050316
GeneTrack = 2.0.0_beta_1
--- a/lib/galaxy/util/__init__.py Fri Feb 18 16:21:11 2011 -0500
+++ b/lib/galaxy/util/__init__.py Fri Feb 18 17:47:07 2011 -0500
@@ -19,7 +19,7 @@
pkg_resources.require( 'docutils' )
import docutils.core
-from galaxy.util.docutils_ext.htmlfrag import Writer as HTMLFragWriter
+import docutils.writers.html4css1
pkg_resources.require( 'elementtree' )
from elementtree import ElementTree, ElementInclude
@@ -252,7 +252,9 @@
def write( self, str ):
if len( str ) > 0 and not str.isspace():
log.warn( str )
- return docutils.core.publish_string( s, writer=HTMLFragWriter(), settings_overrides=dict( warning_stream=FakeStream() ) )
+ return docutils.core.publish_string(s,
+ writer=docutils.writers.html4css1.Writer(),
+ settings_overrides={"embed_stylesheet": False, "template": os.path.join(os.path.dirname(__file__), "docutils_template.txt"), "warning_stream": FakeStream()})
def xml_text(root, name=None):
"""Returns the text inside an element"""
--- a/lib/galaxy/util/docutils_ext/htmlfrag.py Fri Feb 18 16:21:11 2011 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,137 +0,0 @@
-# Author: Ollie Rutherfurd
-# Contact: oliver(a)rutherfurd.net
-# Revision: $Revision: 2884 $
-# Date: $Date: 2004-12-08 20:49:05 +0100 (Wed, 08 Dec 2004) $
-# Copyright: This module has been placed in the public domain.
-
-"""
-Simple .ht (HyperText Template) document tree Writer.
-
-.ht tmeplate files are essentially normal HTML, with
-an option set of RFC 2822-like headers at the top of
-the file. There must be at least one blank line between
-the last header and the start of the body HTML.
-
-See http://ht2html.sf.net/ for more information on
-.ht files and ht2html..
-"""
-
-__docformat__ = 'reStructuredText'
-
-import os
-from docutils import nodes
-from docutils import writers
-from docutils import frontend
-from docutils.writers.html4css1 import HTMLTranslator, utils
-
-
-class Writer(writers.Writer):
-
- supported = ('htmlfrag',)
- """Formats this writer supports."""
-
- settings_spec = (
- 'HTML-Specific Options',
- None,
- (('Specify a stylesheet URL, used verbatim. Default is '
- '"default.css". Overrides --stylesheet-path.',
- ['--stylesheet'],
- {'default': 'default.css', 'metavar': '<URL>',
- 'overrides': 'stylesheet_path'}),
- ('Specify a stylesheet file, relative to the current working '
- 'directory. The path is adjusted relative to the output HTML '
- 'file. Overrides --stylesheet.',
- ['--stylesheet-path'],
- {'metavar': '<file>', 'overrides': 'stylesheet'}),
- ('Link to the stylesheet in the output HTML file. This is the '
- 'default.',
- ['--link-stylesheet'],
- {'dest': 'embed_stylesheet', 'action': 'store_false',
- 'validator': frontend.validate_boolean}),
- ('Embed the stylesheet in the output HTML file. The stylesheet '
- 'file must be accessible during processing (--stylesheet-path is '
- 'recommended). Default: link the stylesheet, do not embed it.',
- ['--embed-stylesheet'],
- {'action': 'store_true', 'validator': frontend.validate_boolean}),
- ('Specify the initial header level. Default is 1 for "<h1>". '
- 'Does not affect document title & subtitle (see --no-doc-title).',
- ['--initial-header-level'],
- {'choices': '1 2 3 4 5 6'.split(), 'default': '3',
- 'metavar': '<level>'}),
- ('Specify the maximum width (in characters) for one-column field '
- 'names. Longer field names will span an entire row of the table '
- 'used to render the field list. Default is 14 characters. '
- 'Use 0 for "no limit".',
- ['--field-name-limit'],
- {'default': 14, 'metavar': '<level>',
- 'validator': frontend.validate_nonnegative_int}),
- ('Specify the maximum width (in characters) for options in option '
- 'lists. Longer options will span an entire row of the table used '
- 'to render the option list. Default is 14 characters. '
- 'Use 0 for "no limit".',
- ['--option-limit'],
- {'default': 14, 'metavar': '<level>',
- 'validator': frontend.validate_nonnegative_int}),
- ('Format for footnote references: one of "superscript" or '
- '"brackets". Default is "brackets".',
- ['--footnote-references'],
- {'choices': ['superscript', 'brackets'], 'default': 'brackets',
- 'metavar': '<format>',
- 'overrides': 'trim_footnote_reference_space'}),
- ('Format for block quote attributions: one of "dash" (em-dash '
- 'prefix), "parentheses"/"parens", or "none". Default is "dash".',
- ['--attribution'],
- {'choices': ['dash', 'parentheses', 'parens', 'none'],
- 'default': 'dash', 'metavar': '<format>'}),
- ('Remove extra vertical whitespace between items of bullet lists '
- 'and enumerated lists, when list items are "simple" (i.e., all '
- 'items each contain one paragraph and/or one "simple" sublist '
- 'only). Default: enabled.',
- ['--compact-lists'],
- {'default': 1, 'action': 'store_true',
- 'validator': frontend.validate_boolean}),
- ('Disable compact simple bullet and enumerated lists.',
- ['--no-compact-lists'],
- {'dest': 'compact_lists', 'action': 'store_false'}),
- ('Omit the XML declaration. Use with caution.',
- ['--no-xml-declaration'],
- {'dest': 'xml_declaration', 'default': 1, 'action': 'store_false',
- 'validator': frontend.validate_boolean}),
- ('Scramble email addresses to confuse harvesters. '
- 'For example, "abc(a)example.org" will become '
- '``<a href="mailto:%61%62%63%40...">abc at example dot org</a>``.',
- ['--cloak-email-addresses'],
- {'action': 'store_true', 'validator': frontend.validate_boolean}),))
-
-
- relative_path_settings = ('stylesheet_path',)
-
- output = None
-
- def __init__(self):
- writers.Writer.__init__(self)
- self.translator_class = HTMLFragTranslator
-
- def translate(self):
- visitor = self.translator_class(self.document)
- self.document.walkabout(visitor)
- self.output = visitor.astext()
- self.stylesheet = visitor.stylesheet
- self.body = visitor.body
-
-
-class HTMLFragTranslator(HTMLTranslator):
-
- def __init__(self, document):
- # I don't believe we can embed any style content
- # the header, so always link to the stylesheet.
- document.settings.embed_stylesheet = 0
- HTMLTranslator.__init__(self, document)
-
- def astext(self):
- # kludge! want footer, but not '</body></html>'
- body = self.body_pre_docinfo + self.docinfo + self.body + \
- self.body_suffix[:-1]
- return ''.join(body)
-
-# :indentSize=4:lineSeparator=\n:noTabs=true:tabSize=4:
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/5f5dae7e7ccc/
changeset: r5092:5f5dae7e7ccc
user: greg
date: 2011-02-18 20:53:35
summary: Another fix for rendering the contents of a data library - the form to acti on multiple datasets should now be rendered correclty.
affected #: 1 file (378 bytes)
--- a/templates/library/common/browse_library.mako Fri Feb 18 14:46:16 2011 -0500
+++ b/templates/library/common/browse_library.mako Fri Feb 18 14:53:35 2011 -0500
@@ -349,10 +349,6 @@
form_type = trans.model.FormDefinition.types.LIBRARY_INFO_TEMPLATE
info_association, inherited = folder.get_info_association( restrict=True )
-
- if not self.has_accessible_datasets:
- # If we already know the library contains accessible datasets, no need to check again (and we may set it to False if we do).
- self.has_accessible_datasets = trans.app.security_agent.has_accessible_library_datasets( trans, folder, trans.user, current_user_roles, search_downward=False )
%>
%if not root_folder and ( not folder.deleted or show_deleted ):
<% encoded_id = trans.security.encode_id(folder.id) %>
@@ -489,7 +485,7 @@
info_association, inherited = library.get_info_association()
form_type = trans.model.FormDefinition.types.LIBRARY_INFO_TEMPLATE
- self.has_accessible_datasets = trans.app.security_agent.has_accessible_library_datasets( trans, library.root_folder, trans.user, current_user_roles, search_downward=False )
+ self.has_accessible_datasets = trans.app.security_agent.has_accessible_library_datasets( trans, library.root_folder, trans.user, current_user_roles )
has_accessible_folders = is_admin or trans.app.security_agent.has_accessible_folders( trans, library.root_folder, trans.user, current_user_roles )
tracked_datasets = {}
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/6cf34552c6f5/
changeset: r5091:6cf34552c6f5
user: rc
date: 2011-02-18 20:46:16
summary: renamed 'samples' to 'sample_widgets' in __save_samples
affected #: 1 file (63 bytes)
--- a/lib/galaxy/web/controllers/requests_common.py Fri Feb 18 14:34:14 2011 -0500
+++ b/lib/galaxy/web/controllers/requests_common.py Fri Feb 18 14:46:16 2011 -0500
@@ -1093,7 +1093,7 @@
request_widgets=request_widgets,
displayable_sample_widgets=displayable_sample_widgets,
sample_copy_select_field=sample_copy_select_field )
- def __save_samples( self, trans, cntrller, request, samples, saving_new_samples=False, **kwd ):
+ def __save_samples( self, trans, cntrller, request, sample_widgets, saving_new_samples=False, **kwd ):
# Here we handle saving all new samples added by the user as well as saving
# changes to any subset of the request's samples. A sample will not have an
# associated SampleState until the request is submitted, at which time the
@@ -1109,7 +1109,7 @@
else:
redirect_action = 'edit_samples'
# Check for duplicate sample names within the request
- self.__validate_sample_names( trans, cntrller, request, samples, **kwd )
+ self.__validate_sample_names( trans, cntrller, request, sample_widgets, **kwd )
if not saving_new_samples:
library = None
folder = None
@@ -1138,8 +1138,8 @@
# TODO: make changes necessary to just send the samples...
encoded_selected_sample_ids = self.__get_encoded_selected_sample_ids( trans, request, **kwd )
# Make sure all samples have a unique bar_code if the state is changing
- for sample_index in range( len( samples ) ):
- current_sample = samples[ sample_index ]
+ for sample_index in range( len( sample_widgets ) ):
+ current_sample = sample_widgets[ sample_index ]
if current_sample is None:
# We have a None value because the user did not select this sample
# on which to perform the action.
@@ -1163,15 +1163,15 @@
library_id = params.get( 'sample_operation_library_id', 'none' )
folder_id = params.get( 'sample_operation_folder_id', 'none' )
library, folder = self.__get_library_and_folder( trans, library_id, folder_id )
- for sample_index in range( len( samples ) ):
- current_sample = samples[ sample_index ]
+ for sample_index in range( len( sample_widgets ) ):
+ current_sample = sample_widgets[ sample_index ]
if current_sample is None:
# We have a None value because the user did not select this sample
# on which to perform the action.
continue
current_sample[ 'library' ] = library
current_sample[ 'folder' ] = folder
- self.__update_samples( trans, cntrller, request, samples, **kwd )
+ self.__update_samples( trans, cntrller, request, sample_widgets, **kwd )
message = 'Changes made to the samples have been saved. '
else:
# Saving a newly created sample. The sample will not have an associated SampleState
@@ -1179,9 +1179,9 @@
# set to the first SampleState configured for the request's RequestType configured
# by the admin ( i.e., the sample's SampleState would be set to request.type.states[0] ).
new_samples = []
- for index in range( len( samples ) - len( request.samples ) ):
+ for index in range( len( sample_widgets ) - len( request.samples ) ):
sample_index = len( request.samples )
- sample_widget = samples[ sample_index ]
+ sample_widget = sample_widgets[ sample_index ]
form_values = trans.model.FormValues( request.type.sample_form, sample_widget[ 'field_values' ] )
trans.sa_session.add( form_values )
trans.sa_session.flush()
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/41b368b104ff/
changeset: r5090:41b368b104ff
user: natefoo
date: 2011-02-18 20:34:14
summary: Remove the new/ subdirectory from the eggs repository and update the pysam egg.
affected #: 2 files (5 bytes)
--- a/dist-eggs.ini Fri Feb 18 13:22:31 2011 -0500
+++ b/dist-eggs.ini Fri Feb 18 14:34:14 2011 -0500
@@ -22,7 +22,7 @@
py2.4-macosx-10.3-fat-ucs2 = lonnie.bx.psu.edu /usr/local/bin/python2.4
py2.5-macosx-10.3-fat-ucs2 = lonnie.bx.psu.edu /usr/local/bin/python2.5
py2.6-macosx-10.3-fat-ucs2 = lonnie.bx.psu.edu /usr/local/bin/python2.6
-py2.6-macosx-10.6-universal-ucs2 = bach.bx.psu.edu /usr/bin/python2.6
+py2.6-macosx-10.6-universal-ucs2 = fanty.bx.psu.edu /usr/bin/python2.6
py2.4-solaris-2.10-i86pc_32-ucs2 = thumper.bx.psu.edu /afs/bx.psu.edu/project/pythons/solaris-2.10-i86pc_32-ucs2/bin/python2.4
py2.5-solaris-2.10-i86pc_32-ucs2 = thumper.bx.psu.edu /afs/bx.psu.edu/project/pythons/solaris-2.10-i86pc_32-ucs2/bin/python2.5
py2.6-solaris-2.10-i86pc_32-ucs2 = thumper.bx.psu.edu /afs/bx.psu.edu/project/pythons/solaris-2.10-i86pc_32-ucs2/bin/python2.6
--- a/eggs.ini Fri Feb 18 13:22:31 2011 -0500
+++ b/eggs.ini Fri Feb 18 14:34:14 2011 -0500
@@ -7,7 +7,7 @@
;
[general]
-repository = http://eggs.g2.bx.psu.edu/new
+repository = http://eggs.g2.bx.psu.edu
; these eggs must be scrambled for your local environment
no_auto = pbs_python DRMAA_python
@@ -69,7 +69,7 @@
bx_python = _14b6a6c95da6
GeneTrack = _dev_48da9e998f0caf01c5be731e926f4b0481f658f0
SQLAlchemy = _dev_r6498
-pysam = _kanwei_a92c29d5cdec
+pysam = _kanwei_ae2bd50d9945
; dependency source urls, necessary for scrambling. for an explanation, see
; the wiki page above
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/c8f8f80902d1/
changeset: r5089:c8f8f80902d1
user: natefoo
date: 2011-02-18 19:22:31
summary: Don't copy ez_setup.py to egg build directories anymore, and provide a more useful error message when an egg is missing a dependency with a version conflict.
affected #: 2 files (427 bytes)
--- a/lib/galaxy/eggs/__init__.py Fri Feb 18 12:07:27 2011 -0500
+++ b/lib/galaxy/eggs/__init__.py Fri Feb 18 13:22:31 2011 -0500
@@ -187,6 +187,10 @@
else:
raise EggNotFetchable( self )
except pkg_resources.VersionConflict, e:
+ if e.args[1].key != e.args[0].key:
+ log.error( "One of Galaxy's managed eggs depends on something which is missing, this is almost certainly a bug in the egg distribution." )
+ log.error( 'Dependency "%s" requires "%s"' % ( e.args[0].project_name, str( e.args[1] ) ) )
+ raise
# there's a conflicting egg on the path, remove it
return self.version_conflict( e.args[0], e.args[1] )
def version_conflict( self, conflict_dist, conflict_req ):
--- a/lib/galaxy/eggs/scramble.py Fri Feb 18 12:07:27 2011 -0500
+++ b/lib/galaxy/eggs/scramble.py Fri Feb 18 13:22:31 2011 -0500
@@ -54,7 +54,6 @@
self.copy_build_script()
if not os.path.exists( ScrambleEgg.ez_setup ):
URLRetriever().retrieve( ScrambleEgg.ez_setup_url, ScrambleEgg.ez_setup )
- shutil.copyfile( ScrambleEgg.ez_setup, os.path.join( self.buildpath, 'ez_setup.py' ) )
self.run_scramble_script()
new_egg = os.path.join( self.buildpath, 'dist', os.path.basename( self.distribution.location ) )
if not os.path.exists( new_egg ):
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/c0f7d67ece33/
changeset: r5087:c0f7d67ece33
user: greg
date: 2011-02-18 18:04:26
summary: Fix for changing the selected data library and folder for a checked list of samples ( a subset of the entire list of the request's samples ).
affected #: 1 file (1.0 KB)
--- a/lib/galaxy/web/controllers/requests_common.py Fri Feb 18 11:18:52 2011 -0500
+++ b/lib/galaxy/web/controllers/requests_common.py Fri Feb 18 12:04:26 2011 -0500
@@ -463,8 +463,18 @@
samples.append( sample )
else:
samples.append( None )
- # The __save_samples method requires sample_widgets, not sample objects
- sample_widgets = self.__get_sample_widgets( trans, request, samples, **kwd )
+ # The __save_samples method requires sample_widgets, not sample objects, so we'll get what we
+ # need by calling __get_sample_widgets(). However, we need to take care here because __get_sample_widgets()
+ # is used to populate the sample widget dicts from kwd, and the method assumes that a None object in the
+ # received list of samples should be populated from the db. Since we're just re-using the method here to
+ # change our list of samples into a list of sample widgets, we'll need to make sure to keep track of our
+ # None objects.
+ sample_widgets = [ obj for obj in samples ]
+ sample_widgets = self.__get_sample_widgets( trans, request, sample_widgets, **kwd )
+ # Replace each sample widget dict with a None object if necessary
+ for index, obj in enumerate( samples ):
+ if obj is None:
+ sample_widgets[ index ] = None
else:
sample_widgets = displayable_sample_widgets
return self.__save_samples( trans, cntrller, request, sample_widgets, saving_new_samples=False, **kwd )
@@ -1155,6 +1165,10 @@
library, folder = self.__get_library_and_folder( trans, library_id, folder_id )
for sample_index in range( len( samples ) ):
current_sample = samples[ sample_index ]
+ if current_sample is None:
+ # We have a None value because the user did not select this sample
+ # on which to perform the action.
+ continue
current_sample[ 'library' ] = library
current_sample[ 'folder' ] = folder
self.__update_samples( trans, cntrller, request, samples, **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.