X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=plugins%2Finterfaces.py;fp=plugins%2Finterfaces.py;h=bc24b4e6cac67f91016391ba0e7f056dd03916b7;hb=ac6786141feadccdc48b819ab21a825a54881ded;hp=6927b235e7ba8bdd0b0c37c7119a864d0a858ec5;hpb=b885d5d47644343378129c3e38b5676c9b747aea;p=nodemanager.git diff --git a/plugins/interfaces.py b/plugins/interfaces.py index 6927b23..bc24b4e 100644 --- a/plugins/interfaces.py +++ b/plugins/interfaces.py @@ -26,7 +26,7 @@ def start(): def GetSlivers(data, config=None, plc=None): if 'slivers' not in data: - logger.log_missing_data("interfaces.GetSlivers",'slivers') + logger.log_missing_data("interfaces.GetSlivers", 'slivers') return for sliver in data['slivers']: @@ -43,7 +43,7 @@ def GetSlivers(data, config=None, plc=None): if tag['tagname'] == 'interface': interfaces = eval(tag['value']) - if not isinstance(interfaces, (list,tuple)): + if not isinstance(interfaces, (list, tuple)): # if interface is not a list, then make it into a singleton list interfaces = [interfaces] @@ -55,7 +55,7 @@ def GetSlivers(data, config=None, plc=None): url = mydict['url'] try: contents = curlwrapper.retrieve(url) - except xmlrpclib.ProtocolError,e: + except xmlrpclib.ProtocolError as e: logger.log('interfaces (%s): failed to retrieve %s' % (slicename, url)) continue else: