reset cache when permissive is added

This commit is contained in:
2017-04-20 11:20:37 +02:00
parent 9a5b8a5f63
commit 6ca3e236f9
4 changed files with 175 additions and 152 deletions

View File

@ -303,6 +303,9 @@ class Property(object):
def __repr__(self):
return str(list(self._properties))
def get(self):
return tuple(self._properties)
#____________________________________________________________
class Settings(object):
@ -505,7 +508,7 @@ class Settings(object):
opt_type = 'option'
if 'frozen' in properties:
return PropertiesOptionError(_('cannot change the value for '
'option {0} this option is'
'option "{0}" this option is'
' frozen').format(
opt_or_descr.impl_getname()),
props, self, datas, opt_type)
@ -538,6 +541,7 @@ class Settings(object):
if not isinstance(permissive, tuple): # pragma: optional cover
raise TypeError(_('permissive must be a tuple'))
self._p_.setpermissive(path, permissive)
self._getcontext().cfgimpl_reset_cache()
#____________________________________________________________
def setowner(self, owner):