exceptions
JobExecutionError
¶
Bases: RuntimeError
Forwards errors in the execution of a task that are due to external factors
This error wraps and forwards errors occurred during the execution of tasks, but related to external factors like:
- A negative exit code (e.g. because the task received a TERM or KILL signal);
- An error on the executor side (e.g. the SLURM executor could not find the pickled file with task output).
This error also adds information that is useful to track down and debug the failing task within a workflow.
Attributes:
Name | Type | Description |
---|---|---|
info |
Optional[str]
|
A free field for additional information |
cmd_file |
Optional[str]
|
Path to the file of the command that was executed (e.g. a SLURM submission script). |
stdout_file |
Optional[str]
|
Path to the file with the command stdout |
stderr_file |
Optional[str]
|
Path to the file with the command stderr |
Source code in fractal_server/app/runner/exceptions.py
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 |
|
_read_file(filepath)
¶
Return the content of a text file, and handle the cases where it is empty or missing
Source code in fractal_server/app/runner/exceptions.py
86 87 88 89 90 91 92 93 94 95 96 97 98 99 |
|
assemble_error()
¶
Read the files that are specified in attributes, and combine them in an error message.
Source code in fractal_server/app/runner/exceptions.py
101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 |
|
TaskExecutionError
¶
Bases: RuntimeError
Forwards errors occurred during the execution of a task
This error wraps and forwards errors occurred during the execution of tasks, when the exit code is larger than 0 (i.e. the error took place within the task). This error also adds information that is useful to track down and debug the failing task within a workflow.
Attributes:
Name | Type | Description |
---|---|---|
workflow_task_id |
Optional[int]
|
ID of the workflow task that failed. |
workflow_task_order |
Optional[int]
|
Order of the task within the workflow. |
task_name |
Optional[str]
|
Human readable name of the failing task. |
Source code in fractal_server/app/runner/exceptions.py
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 |
|