letex:propagate-caught-error (in library simple-progress-msg.xpl) propagate-caught-error
propagate-caught-error
This step redirects an error to a status text file and prints a cx:message
. If option fail-on-error
is set to true
, the error is reproduced with an attached error code.
Visualisation
The pre-creation of this SVG image needs the Graphviz software installed. Please inform your project maintainer.
Input Ports
Name | Documentation | Connections |
---|---|---|
sourceⓅ | Input port:
|
Output Ports
Name | Documentation | Connections |
---|---|---|
resultⓅ | Output port:
| Output port: result If option fail-on-error is not set to true, then the output is a c:errors document. Additionally, two attributes are attached: type: severity of the error code: error code |
Options
Name | Documentation | Default |
---|---|---|
fail-on-error | Option:
| 'false' |
code | Option:
| 'letex:UNSP01' |
severity | Option:
| 'fatal-error' |
msg-file | Option:
| 'unspecified-error.txt' |
status-dir-uri | Option:
| 'debug/status' |
Subpipeline
Step | Inputs | Outputs | Options | ||
---|---|---|---|---|---|
p:xslt error-msg |
| result | |||
letex:simple-progress-msg write-progress-msg | result | file = $msg-file status-dir-uri = $status-dir-uri | |||
cx:message output-error-msg |
| result | message = /c:errors | ||
p:sink d90e386 |
| ||||
p:add-attribute add-code |
| result | attribute-name = 'code' match = '/c:errors/c:error[last()]' attribute-value = $code | ||
p:add-attribute add-severity | result | attribute-name = 'type' match = '/c:errors/c:error[last()]' attribute-value = $severity | |||
p:choose d90e403 | |||||
$fail-on-error = 'true' | |||||
p:error d90e407 If you use a prefix in the error code, you might have to declare it in this file. |
| result | code = $code | ||
p:otherwise | |||||
p:identity d90e423 |
| result |