Hi Ben, On Thu, Apr 12, 2018 at 02:25:58PM -0600, Ben Draut wrote: > This changes the parser to run section postparsers once per section > instance, rather than only when the section type changes. > > This is motivated by the work discussed in > https://firstname.lastname@example.org/msg29527.html. It should > make it easy to produce the warning mentioned in the summary at most once > per section.
Hmmm I don't much like this principle, because it's not a post-section parser anymore in this case, it's a post config parser. Note that it is very possible that you need a different type of post-processing to help with the resolvers stuff, but I really think this approach is mistaken because it removes the ability to perform post-section processing. From what I'm seeing by quickly grepping in the code, at least the cache relies on this. I *think* we do have a way to register a post-config call, but to be honest I really don't remember, as we've added a few such hooks over time. Maybe you'd need to call this thing before entering check_config_validity() which resolves every cross-dependency between the config elements and which detect inconsistencies. We may imagine having a pre_final_check and a post_final_check callback for this maybe. Just a few ideas. Thanks! Willy