diff options
author | Tim Smith <tsmith84@gmail.com> | 2020-07-06 14:55:18 -0700 |
---|---|---|
committer | Tim Smith <tsmith84@gmail.com> | 2020-07-15 11:39:06 -0700 |
commit | 9778eec4e7890016b4cb30a73c2b6dbfcfbc1ee7 (patch) | |
tree | 3daa9bf2024489239986ea86eb4adf857aece2b6 | |
parent | 5c03f35d05bc79a9b88203bf30a252f705588ec3 (diff) | |
download | chef-9778eec4e7890016b4cb30a73c2b6dbfcfbc1ee7.tar.gz |
Fix warning message for cb / core resource conflict
Update the message to reflect what's actually happening, remove the evil
double space after the period, and use branding.
Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r-- | lib/chef/node_map.rb | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/chef/node_map.rb b/lib/chef/node_map.rb index f4dae0f9b7..2b15ce4e4b 100644 --- a/lib/chef/node_map.rb +++ b/lib/chef/node_map.rb @@ -35,10 +35,13 @@ # # XXX: confusingly, in the *_priority_map the :klass may be an array of Strings of class names # + +require_relative "dist" + class Chef class NodeMap COLLISION_WARNING = <<~EOH.gsub(/\s+/, " ").strip - %{type_caps} %{key} from the client is overriding the %{type} from a cookbook. Please upgrade your cookbook + %{type_caps} %{key} built into %{client_name} is being overridden by the %{type} from a cookbook. Please upgrade your cookbook or remove the cookbook from your run_list. EOH @@ -84,7 +87,7 @@ class Chef else klass.superclass.to_s end - Chef::Log.warn( COLLISION_WARNING % { type: type_of_thing, key: key, type_caps: type_of_thing.capitalize } ) + Chef::Log.warn( COLLISION_WARNING % { type: type_of_thing, key: key, type_caps: type_of_thing.capitalize, client_name: Chef::Dist::PRODUCT } ) end # The map is sorted in order of preference already; we just need to find |