So I think there are a few issues here. The settings code in [3.3.1](https://github.com/puppetlabs/puppet/blob/3.3.1/lib/puppet/settings.rb#L605) would always interpolate settings that contained a hook, and would raise an InterpolationError if the default value for the setting referred to a special setting like `$confdir` whose value is only known after `run_mode` is determined and the application defaults have been initialized.

In f68aafc69a, we changed it, so that `setting.handle` is only called for hooks that aren't of type `:on_initialize_and_write`: 

<pre>
          if setting.call_hook_on_initialize?
            @hooks_to_call_on_application_initialization &lt;&lt; setting
          else
            setting.handle(self.value(setting.name, env))
          end
</pre>

We later try to resolve them and ignore interpolation errors:

<pre>
    call_hooks_deferred_to_application_initialization :ignore_interpolation_dependency_errors => true
</pre>

However, for `:on_define_and_write` hooks, we still call `setting.handle`, which will blow up if the default value contains `$confdir`.

For `:on_write_only` hooks, the default, we still call `setting.handle`, which is wrong because we should only call that hook when the value is set. It will also blow up if the default value contains `$confdir`.

Later in commit 1285d403, we removed the `settings_with_hooks` method, so we actually enumerate all settings, even those without hooks. As a result, a setting like `:autosign` which doesn't has a hook, but does have a default value of `$confdir/autosign.conf` will also cause an interpolation error when `setting.handle` is called.

I think we should never call `setting.handle` in this method. Instead, defer calling of hooks of type `:on_define_and_write` and `:on_initialize_and_write`, and ignore interpolation errors. We will retry interpolation again later, and fail hard if we still can't interpolate them.

Also modify this method so that we only enumerate settings with hooks.

And sadly none of the spec tests caught this issue.