diff options
author | Benjamin Schubert <contact@benschubert.me> | 2019-07-26 16:06:03 +0100 |
---|---|---|
committer | Benjamin Schubert <contact@benschubert.me> | 2019-07-29 10:42:02 +0100 |
commit | b632e471f1ca4764c15534006294f7dc0b842b69 (patch) | |
tree | 0b7a1782b8e7054ba2bfb05aeeedb6f0c1e26dd6 /src/buildstream/types.py | |
parent | 0f074dd37524047cb53214be5c0f10436d3abb1d (diff) | |
download | buildstream-b632e471f1ca4764c15534006294f7dc0b842b69.tar.gz |
context: Move scheduler actions to an Enum
Also add helpers for the cli to be able to represent 'FastEnum' directly
Diffstat (limited to 'src/buildstream/types.py')
-rw-r--r-- | src/buildstream/types.py | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/buildstream/types.py b/src/buildstream/types.py index ff4a3cc57..08e2b0d08 100644 --- a/src/buildstream/types.py +++ b/src/buildstream/types.py @@ -192,3 +192,19 @@ class _KeyStrength(FastEnum): # Includes names of direct build dependencies but does not include # cache keys of dependencies. WEAK = 2 + + +# _SchedulerErrorAction() +# +# Actions the scheduler can take on error +# +class _SchedulerErrorAction(FastEnum): + + # Continue building the rest of the tree + CONTINUE = "continue" + + # finish ongoing work and quit + QUIT = "quit" + + # Abort immediately + TERMINATE = "terminate" |