DescriptionTrack step nesting in StreamEngine (Reland).
Currently, step nesting is tracked by the step runner as an integer,
which is passed to the stream engine as the `set_nest_level` post-create
event. This poses two problems, namely:
- The nest level is known to the runner immediately on step creation,
but is presented to the stream engine as a separate piece of
information.
- This forces the step runner's concept of nesting (integer) onto the
stream engine, when all it really cares about is whether or not a step
is nested.
This patch updates the API to pass the nested state as a boolean: either
a step is nested in the previous step, or it isn't. The stream engine is
responsible for tracking how it represents this to the stream's
consumer. The nested state is also passed at step creation, making
nesting an atomic step propety instead of an out-of-band option.
Along the way, small cleanups.
BUG=chromium:628770
TEST=local
- Ran unit tests locally.
- `./recipes.py --package ./infra/config/recipes.cfg run example/nested`
Committed: https://github.com/luci/recipes-py/commit/227f56ba6353986a7fe6d56fb283ad73c84e94d9
Patch Set 1 #Patch Set 2 : Fix variable name. #Patch Set 3 : Might as well go deeper. #
Dependent Patchsets: Messages
Total messages: 7 (3 generated)
|