Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-176

(#19955) (PR1941) Errors from databindings should clearly indicate Hiera as the source of the problem



    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • PUP 3.4.0
    • Compiler
    • 1
    • Week 2013-09-25 to 2013-10-02, Week 2013-10-02 to 2013-10-09


      When the Puppet 3.x compiler comes across a parameterized class, it will attempt to load parameter defaults from Hiera data bindings. If the bindings fail for any reason, an error message will be logged:

      Error: Could not retrieve catalog from remote server: Error 400 on SERVER: can't convert String into Hash at /etc/puppet/environments/production/manifests/cluster/core/nodes.pp:4 on node puppet01.dev.example.net

      The error message calls out the parameterized class that failed and its location in the puppet manifest, but doesn't include any indication that the failure actually occurred in Hiera. Unless a user immediately runs the compilation under `--trace`, they may waste a significant amount of time staring at manifest code that contains no errors.

      It seems Puppet should do one of the following when a data binding fails:

      • Log an Error that indicates the failure occurred in a data binding backend and indicate which terminus the indirector was calling and fail the compilation.
      • Log a Warning with the above information and continue compilation using parameter defaults that were specified by the class definition in the Puppet manifest.




            henrik.lindberg Henrik Lindberg
            chuck Charlie Sharpsteen
            0 Vote for this issue
            3 Start watching this issue



              Zendesk Support