diff options
author | Daniel DeLeo <dan@opscode.com> | 2011-03-16 12:18:20 -0700 |
---|---|---|
committer | Daniel DeLeo <dan@opscode.com> | 2011-03-16 12:18:20 -0700 |
commit | 0e53f417bea8f386aed5e1012a78611649b3147e (patch) | |
tree | a85955d70392b207c6816682f2978c182ffcb27e /chef/lib/chef/cookbook | |
parent | b3fdb87a845a23d19713c95f7057f93199c2cf0c (diff) | |
download | chef-0e53f417bea8f386aed5e1012a78611649b3147e.tar.gz |
Suggest metadata as a possible cause when raising CookbookNotFound
Diffstat (limited to 'chef/lib/chef/cookbook')
-rw-r--r-- | chef/lib/chef/cookbook/cookbook_collection.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/chef/lib/chef/cookbook/cookbook_collection.rb b/chef/lib/chef/cookbook/cookbook_collection.rb index c4b05d5ea0..9527ccde14 100644 --- a/chef/lib/chef/cookbook/cookbook_collection.rb +++ b/chef/lib/chef/cookbook/cookbook_collection.rb @@ -35,7 +35,8 @@ class Chef # simply extract them def initialize(cookbook_versions={}) super() do |hash, key| - raise Chef::Exceptions::CookbookNotFound, "Cookbook #{key} not found" + raise Chef::Exceptions::CookbookNotFound, "Cookbook #{key} not found. " << + "If you're loading #{key} from another cookbook, make sure you configure the dependency in your metadata" end cookbook_versions.each{ |cookbook_name, cookbook_version| self[cookbook_name] = cookbook_version } end |