Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Moses Mendoza updated an issue Puppet / PUP-3619 Hiera: future+strict_variables fails with uncaught throw :undefined_variable Change By: Moses Mendoza Labels: triaged Add Comment This message was sent by Atlassian JIRA (v6.4.14#64029-sha1:ae256fe) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Moses Mendoza commented on PUP-3619 Re: Hiera: future+strict_variables fails with uncaught throw :undefined_variable If this is still an issue in Hiera 5 / Puppet 4.10, can you re-open this? Pending that, closing this as won't fix. Add Comment This message was sent by Atlassian JIRA (v6.4.14#64029-sha1:ae256fe) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Sean McDonald updated an issue Puppet / PUP-3619 Hiera: future+strict_variables fails with uncaught throw :undefined_variable Change By: Sean McDonald Labels: triaged Add Comment This message was sent by Atlassian JIRA (v6.4.14#64029-sha1:ae256fe) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Nick Howes commented on PUP-3619 Re: Hiera: future+strict_variables fails with uncaught throw :undefined_variable I get this on 3.7.3. For me it works if the value is found in the first item in the hierarchy, otherwise it throws this exception before it gets any further. So for me it's more than just a cryptic message. Without strict_variables, hiera can traverse its hierarchy. /etc/puppet/hiera.yaml --- :hierarchy: - nodes/%{::hostname} - common A call to hiera('puppet::version') fails with the above exception if puppet::version is set in common.yaml, but works if it's set in nodes/thehostname.yaml Add Comment
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Nick Howes commented on PUP-3619 Re: Hiera: future+strict_variables fails with uncaught throw :undefined_variable Ah, found out what it is - it's not that it doesn't go past the first item in the hierarchy, it's that the second item in my hierarchy used interpolated facts that aren't being set. So it is genuinely complaining about missing variables, which is fair enough. So my case is nothing new from what Chris has already mentioned. Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- You received this message because you are subscribed to the Google Groups Puppet Bugs group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Chris Boot created an issue Puppet / PUP-3619 Hiera: future+strict_variables fails with uncaught throw :undefined_variable Issue Type: Bug Affects Versions: PUP 3.7.2 Assignee: Unassigned Created: 2014/11/05 12:45 AM Priority: Major Reporter: Chris Boot The following fails: puppet apply --config /dev/null -e 'class foo($bar='test') { notify { bar=${bar}: } } class { 'foo': }' --parser future --strict_variables with: Error: Evaluation Error: Error while evaluating a Resource Statement, Error from DataBinding 'hiera' while looking up
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Chris Boot updated an issue Puppet / PUP-3619 Hiera: future+strict_variables fails with uncaught throw :undefined_variable Change By: Chris Boot Thefollowingfails:{noformat}puppetapply--config/dev/null-e'classfoo($bar='test'){notify{bar=${bar}:}}class{'foo':}'--parserfuture--strict_variables{noformat}with:{noformat}Error:EvaluationError:ErrorwhileevaluatingaResourceStatement,ErrorfromDataBinding'hiera'whilelookingup'foo::bar':uncaughtthrow:undefined_variableatline1:51onnodebabbage.bootc.euError:EvaluationError:ErrorwhileevaluatingaResourceStatement,ErrorfromDataBinding'hiera'whilelookingup'foo::bar':uncaughtthrow:undefined_variableatline1:51onnodebabbage.bootc.eu{noformat} ThiswasfineinPuppet3.7.1. Add Comment This message was sent by Atlassian JIRA (v6.3.7#6337-sha1:2ed701e) -- You received this message because you are subscribed to the Google Groups Puppet Bugs group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Henrik Lindberg commented on PUP-3619 Re: Hiera: future+strict_variables fails with uncaught throw :undefined_variable I just tried the above on Puppet 3.7.3 and I cannot reproduce the problem. I was using the default hiera configuration. The output I got was: Notice: bar=test Notice: /Stage[main]/Foo/Notify[bar=test]/message: defined 'message' as 'bar=test' Need more information to reproduce. Add Comment This message was sent by Atlassian JIRA (v6.3.7#6337-sha1:2ed701e) -- You received this message because you are subscribed to the Google Groups Puppet Bugs group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Henrik Lindberg updated an issue Puppet / PUP-3619 Hiera: future+strict_variables fails with uncaught throw :undefined_variable Change By: Henrik Lindberg Assignee: ChrisBoot Add Comment This message was sent by Atlassian JIRA (v6.3.7#6337-sha1:2ed701e) -- You received this message because you are subscribed to the Google Groups Puppet Bugs group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Henrik Lindberg commented on PUP-3619 Re: Hiera: future+strict_variables fails with uncaught throw :undefined_variable I should have said - can you try this on 3.7.3 to see if the problem is gone? Add Comment This message was sent by Atlassian JIRA (v6.3.7#6337-sha1:2ed701e) -- You received this message because you are subscribed to the Google Groups Puppet Bugs group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Chris Boot commented on PUP-3619 Re: Hiera: future+strict_variables fails with uncaught throw :undefined_variable Right, I've tried this with 3.7.3 and still get the issue. It seems it comes from Hiera resolving the hierarchy. If I create a hiera.yaml file with the following content: --- :hierarchy: - %{foobar} ... the bug is apparent. If I replace foobar with fqdn or another fact, then the catalogue applies. I guess strictly speaking it is an undefined variable, but it crops up in a really unexpected place. In my case, I was using this for additional ENC-provided variables to be able to influence the hierarchy. The doubly strange thing is that this only appears for me on parametric classes where I don't override the default value, as that's when the value is automatically looked up in Hiera. Add Comment This message was sent by Atlassian JIRA (v6.3.7#6337-sha1:2ed701e)
Jira (PUP-3619) Hiera: future+strict_variables fails with uncaught throw :undefined_variable
Title: Message Title Henrik Lindberg commented on PUP-3619 Re: Hiera: future+strict_variables fails with uncaught throw :undefined_variable Thank you, that explains why it is happening. For starters it should not issue the message uncaught throw, but the question is what it should do instead? It is after all a reference to a variable that does not exist. Without strict_variables the lookup returns undef which then becomes an empty string. That is exactly the behavior that strict_variables is supposed to guard against. So, not sure what to do here except improve the handling of the error. The fact that you get this error when you have not given an explicit value is because the interpolation of the variable only takes place if that lookup is triggered by not giving a value for the parameter. Add Comment This message was sent by Atlassian JIRA (v6.3.7#6337-sha1:2ed701e) -- You received this message because you are subscribed to the Google Groups Puppet Bugs group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.