id,summary,reporter,owner,description,type,status,priority,milestone,component,version,severity,resolution,keywords,cc,branch,changelog,apichanges,internalchanges 11902,Fix config.parse_if_needed cache invalidation,Peter Suter,Peter Suter,"[comment:42:ticket:5525] noted: > It appears there is an unused protected attribute `_cache` in [9037#file11]: [browser:/tags/trac-1.0.2/trac/config.py@:293-294#L264]. Could that be removed? But perhaps some other variable was meant to be cleared, e.g. `self._sections = {}` or `for k in self._sections: self._sections[k]._cache = {}`. It looks like this scenario would currently fail and be fixed by that cache invalidation: {{{#!python # config inherits parent.ini containing [a] b=x config.get('a', 'b') # caches 'x' in config._sections['a']._cache['b'] # change parent.ini to [a] b=y config.parse_if_needed() # does not invalidate that cache config.get('a', 'b') # should return 'y' but returns cached 'x' }}} We should add a testcase and fix the code.",defect,closed,normal,1.0.3,general,,normal,fixed,,Ryan J Ollos,,`Section` cache is properly invalidated by `Configuration.parse_if_needed(..)`.,,