voxpupuli/puppetboard

Add option to show friendly error messages when in report view on a specific node

mike406 opened this issue · 6 comments

Error messages are cut off when viewing a specific node's report due to error being wrapped in <pre> tags. Can the friendly error messages feature be implemented on this screen as well so that the errors will wrap on the page? I'm on the latest version 3.4.2.

Edit: Only happens on certain error messages, not sure why that is though.

image

Hi @mike406, thanks for filing the issue!

I was thinking about doing this together with #641 but I haven't found the time for that just yet... But we are open to PRs from anyone who is willing to improve this. :)

I went with a simpler solution. I just added this to puppetboard/static/css/puppetboard.css. For my purposes this is sufficient as I just care to be able to see the full error. This also has the added benefit of allowing the errors to wrap on the failures tab as well when friendly messages is toggled off.

pre {
 white-space: pre-wrap;
}

image

Cool, can you make a PR with such change @mike406?

Please check out v3.5.0rc1 with this feature, @mike406. A final release will be done within a few days.

Final v3.5.0 released.

Hi @gdubicki sorry for the late reply, this change looks great! Thank you for implementing.