def add_explanation(error_description)
case exception
when Net::HTTPServerException, Net::HTTPFatalError
humanize_http_exception(error_description)
when Errno::ECONNREFUSED, Timeout::Error, Errno::ETIMEDOUT, SocketError
error_description.section("Network Error:","There was a network error connecting to the Chef Server:\n\#{exception.message}\n")
error_description.section("Relevant Config Settings:","chef_server_url \"\#{server_url}\"\n\nIf your chef_server_url is correct, your network could be down.\n")
when Chef::Exceptions::PrivateKeyMissing
error_description.section("Private Key Not Found:","Your private key could not be loaded. If the key file exists, ensure that it is\nreadable by chef-client.\n")
error_description.section("Relevant Config Settings:","validation_key \"\#{api_key}\"\n")
else
"#{exception.class.name}: #{exception.message}"
end
end