-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Publisher: Publish description and detail respects new line characters #1137
base: develop
Are you sure you want to change the base?
Publisher: Publish description and detail respects new line characters #1137
Conversation
Just below in the code I'm also seeing a I think it's much clearer if it's either HTML or Markdown - and once that knowledge is known... then we don't need to convert anything since it'd just be "HTML" or "markdown"? By forcing line breaks to |
You're right, and I don't have strong opinion about it, but I did spend at about an hour finding out how it's used. The idea is/was that we will use markdown to nicely visualize the errors to user. On the other side, the reality is that most of the errors are not markdown, especially those that are not |
I think the best question asked now is - which current reports are not shown in the way we would expect them to be shown. And if they are shown invalidly - would it just make sense to include Also, I'd say moving to markdown by default isn't a bad idea for me per se either - and maybe rewriting any that aren't actually markdown now to turn them into markdown instead of using html? |
I'm fine with having markdown as true by default, also to keep compatibility. But we need to be able to have that information on the exception so we can handle it accordingly. So if there is not markdown then e.g. printing to console could revert it back to "standard" text? Considering that text will be printed in deadline output too... I'm maybe overthinking it? |
I think considering the deadline logs, also there markdown would be more readable than HTML. So defaulting to markdown I think is still the best way forward. About 'sanitizing' that for any console output in the future - I'd say, keep that separate from this PR here. Feels a bit out of scope and hasn't been an issue much yet. I'd rather have us solve being able to also get JSON reports for those headless publishes - so that if one really needed to, they could load up the JSON report from that session into the dedicated Publish JSON report viewer. |
Ehmmm 🤔 Here's the string used to print the following messages.
|
I've gone through the discussion. personally, I'd love to stick to one consistent way to provide error messages. |
@iLLiCiTiT what's the next step for this PR? |
Changelog Description
New line characters in publish error and details are showed correctly now.
Additional info
The issue is that we do allow HTML tags, so we use
setHtml
method, which does not respect new line characters.Question is, are there plugins that are raising errors with new line characters that should be ignored? NOTE: This also affects
PublishValidationError
.Testing notes:
PublishError
raises error with\n
it is shown in UI.Resolves #1062