ohai_solo and posh_ohai json.loads should try harder
Bug #1409175 reported by
Sam Stavinoha
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
satori |
New
|
Undecided
|
Sam Stavinoha |
Bug Description
Right now if the initial json.loads() does not work, we call get_json which looks for the first "{" and last "}" to extract the json string from the output of the server. This has been useful if the shell is spitting out unwanted characters such as fail whales or security banners.
Due to the amount of data returned from ohai_solo or posh_ohai, we are bound to see some UnicodeDecodeError or ValueError from an invalid control character.
Fixing this bug means going one or more steps further in order to do whatever is necessary to decode the data returned.
To post a comment you must log in.