You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With DITA-OT 4.2, I'm able to override message severities. My use case for that is to set up a build gate as part of validation for documentation commits; issues that are allowed as warnings or errors for local / in-progress builds should be treated as fatal for pull request purposes. (We already use processing-mode strict, but this doesn't catch everything.)
When I change the severity of an XSLT message to Fatal, the message templates pick it up, and the build will fail if I throw the message. However the Java code will not do the same; because Java messages are thrown using logger.warn or logger.error, the message severity is part of the code itself, and modifying the severity in the message definition will have no effect.
For example, the Java code throws DOTX008E for missing images; I would like to set the severity of that to FATAL and use that to prevent merging any content with missing image references.
Possible Solution
It would be nice if the Java code was able to read the severity as well as the message text, so that when throwing an error, it could use that to determine error level.
The text was updated successfully, but these errors were encountered:
Description
With DITA-OT 4.2, I'm able to override message severities. My use case for that is to set up a build gate as part of validation for documentation commits; issues that are allowed as warnings or errors for local / in-progress builds should be treated as fatal for pull request purposes. (We already use processing-mode strict, but this doesn't catch everything.)
When I change the severity of an XSLT message to Fatal, the message templates pick it up, and the build will fail if I throw the message. However the Java code will not do the same; because Java messages are thrown using
logger.warn
orlogger.error
, the message severity is part of the code itself, and modifying the severity in the message definition will have no effect.For example, the Java code throws DOTX008E for missing images; I would like to set the severity of that to FATAL and use that to prevent merging any content with missing image references.
Possible Solution
It would be nice if the Java code was able to read the severity as well as the message text, so that when throwing an error, it could use that to determine error level.
The text was updated successfully, but these errors were encountered: