pep8
authorEmmanuel Garette <egarette@cadoles.com>
Wed, 28 Aug 2013 07:16:12 +0000 (09:16 +0200)
committerEmmanuel Garette <egarette@cadoles.com>
Wed, 28 Aug 2013 07:16:12 +0000 (09:16 +0200)
tiramisu/option.py

index 8f598b9..31f8cc8 100644 (file)
@@ -69,7 +69,7 @@ class BaseInformation(object):
         except AttributeError:
             raise AttributeError(_('{0} has no attribute '
                                    'impl_set_information').format(
         except AttributeError:
             raise AttributeError(_('{0} has no attribute '
                                    'impl_set_information').format(
-                                   self.__class__.__name__))
+                                       self.__class__.__name__))
 
     def impl_get_information(self, key, default=None):
         """retrieves one information's item
 
     def impl_get_information(self, key, default=None):
         """retrieves one information's item
@@ -87,7 +87,7 @@ class BaseInformation(object):
         except AttributeError:
             raise AttributeError(_('{0} has no attribute '
                                    'impl_get_information').format(
         except AttributeError:
             raise AttributeError(_('{0} has no attribute '
                                    'impl_get_information').format(
-                                   self.__class__.__name__))
+                                       self.__class__.__name__))
 
 
 class Option(BaseInformation):
 
 
 class Option(BaseInformation):
@@ -150,7 +150,7 @@ class Option(BaseInformation):
             except ValueError, err:
                 raise ValueError(_("invalid default_multi value {0} "
                                    "for option {1}: {2}").format(
             except ValueError, err:
                 raise ValueError(_("invalid default_multi value {0} "
                                    "for option {1}: {2}").format(
-                                   str(default_multi), name, err))
+                                       str(default_multi), name, err))
         if callback is not None and (default is not None or
                                      default_multi is not None):
             raise ValueError(_("default value not allowed if option: {0} "
         if callback is not None and (default is not None or
                                      default_multi is not None):
             raise ValueError(_("default value not allowed if option: {0} "
@@ -180,8 +180,8 @@ class Option(BaseInformation):
         if not isinstance(properties, tuple):
             raise TypeError(_('invalid properties type {0} for {1},'
                             ' must be a tuple').format(
         if not isinstance(properties, tuple):
             raise TypeError(_('invalid properties type {0} for {1},'
                             ' must be a tuple').format(
-                                                type(properties),
-                                                self._name))
+                                type(properties),
+                                self._name))
         self._properties = properties  # 'hidden', 'disabled'...
 
     def __eq__(self, other):
         self._properties = properties  # 'hidden', 'disabled'...
 
     def __eq__(self, other):
@@ -329,7 +329,7 @@ class Option(BaseInformation):
         "no default value has been set yet"
         if ((not self.impl_is_multi() and self._default is None) or
                 (self.impl_is_multi() and (self._default == []
         "no default value has been set yet"
         if ((not self.impl_is_multi() and self._default is None) or
                 (self.impl_is_multi() and (self._default == []
-                                      or None in self._default))):
+                                           or None in self._default))):
             return True
         return False
 
             return True
         return False
 
@@ -1003,10 +1003,7 @@ def validate_requires_arg(requires, name):
         ret_action = []
         for require in opt_requires.values():
             req = (require[0], tuple(require[1]),
         ret_action = []
         for require in opt_requires.values():
             req = (require[0], tuple(require[1]),
-                                     require[2],
-                                     require[3],
-                                     require[4],
-                                     require[5])
+                   require[2], require[3], require[4], require[5])
             ret_action.append(req)
         ret.append(tuple(ret_action))
     return frozenset(config_action.keys()), tuple(ret)
             ret_action.append(req)
         ret.append(tuple(ret_action))
     return frozenset(config_action.keys()), tuple(ret)