Exception: Chef::Node::AttributeDoesNotExistError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/chef/sugar/node.rb

Instance Method Summary collapse

Constructor Details

#initialize(keys, key) ⇒ AttributeDoesNotExistError

Returns a new instance of AttributeDoesNotExistError.


22
23
24
25
26
27
28
29
30
# File 'lib/chef/sugar/node.rb', line 22

def initialize(keys, key)
  hash = keys.map { |key| "['#{key}']" }

  super <<-EOH
No attribute `node#{hash.join}' exists on
the current node. Specifically the `#{key}' attribute is not
defined. Please make sure you have spelled everything correctly.
EOH
end