From: Andy Bavier Date: Thu, 11 Feb 2010 21:17:56 +0000 (+0000) Subject: Minor tweaks X-Git-Tag: sfa-0.9-11~111 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=0907aa9df31b1d00e0ddb347de2ba08937fe7605;p=sfa.git Minor tweaks --- diff --git a/sfa/managers/aggregate_manager_eucalyptus.py b/sfa/managers/aggregate_manager_eucalyptus.py index 5a0cd455..321ab895 100644 --- a/sfa/managers/aggregate_manager_eucalyptus.py +++ b/sfa/managers/aggregate_manager_eucalyptus.py @@ -88,7 +88,7 @@ def init_server(): configParser.read(['/etc/sfa/eucalyptus_aggregate.conf', 'eucalyptus_aggregate.conf']) if len(configParser.sections()) < 1: print >>sys.stderr, 'No cloud defined in the config file' - raise 'Cannot find cloud definition in configuration file.' + raise Exception('Cannot find cloud definition in configuration file.') # Only read the first section. cloudSec = configParser.sections()[0] @@ -173,7 +173,7 @@ class EucaRSpecBuilder(object): # @param cloud A dictionary containing data about a # cloud (ex. clusters, ip) def __init__(self, cloud): - self.eucaRSpec = XMLBuilder() + self.eucaRSpec = XMLBuilder(format = True, tab_step = " ") self.cloudInfo = cloud ## @@ -379,7 +379,7 @@ def create_slice(api, xrn, xml): if not rspecValidator(rspecXML): error = rspecValidator.error_log.last_error message = '%s (line %s)' % (error.message, error.line) - raise Exception(message) + raise InvalidRSpec(message) # Process the RSpec requests = rspecXML.findall('.//request')