set self._extra before 'super'
authorEmmanuel Garette <egarette@cadoles.com>
Tue, 4 Feb 2014 20:55:57 +0000 (21:55 +0100)
committerEmmanuel Garette <egarette@cadoles.com>
Tue, 4 Feb 2014 20:55:57 +0000 (21:55 +0100)
tiramisu/option.py

index 66f2a38..32465c2 100644 (file)
@@ -893,6 +893,8 @@ class PortOption(Option):
         if extra['_max_value'] is None:
             raise ValueError(_('max value is empty'))
 
+        #FIXME avant le super ?
+        self._extra = extra
         super(PortOption, self).__init__(name, doc, default=default,
                                          default_multi=default_multi,
                                          callback=callback,
@@ -903,7 +905,6 @@ class PortOption(Option):
                                          validator_params=validator_params,
                                          properties=properties,
                                          warnings_only=warnings_only)
-        self._extra = extra
 
     def _validate(self, value):
         if self._extra['_allow_range'] and ":" in str(value):