Issue #23173 has been reported by Thomas Limoncelli.

----------------------------------------
Bug #23173: Error message for malformed json files is misleading
https://projects.puppetlabs.com/issues/23173

* Author: Thomas Limoncelli
* Status: Unreviewed
* Priority: Normal
* Assignee: 
* Category: 
* Target version: 
* Affected Puppet version: 3.3.2
* Keywords: 
* Branch: 
----------------------------------------
If hiera can not load a json file the error looks like:

Error: Could not retrieve catalog from remote server: Error 400 on SERVER: 
Puppet::Parser::AST::Resource failed with error ArgumentError: malformed format 
string - %S at /etc/puppet/manifests/site.pp:11 on node client1 
Warning: Not using cache on failed catalog 
Error: Could not retrieve catalog; skipping run

While an advanced use might be able to connect "malformed format string - %S" 
to a json file, it would be more useful if the error message plainly stated 
that there was a malformed file and what that files name was.

Suggested text: "Unable to parse file: FILE_NAME_HERE".

Since most JSON libraries have error messages that indicate the line and char 
of the error, it would be useful to print that too.




-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-bugs.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to