pub struct TaskSteps<'a> { /* private fields */ }Expand description
The step executor of one run of a task program.
Implementations§
Source§impl<'a> TaskSteps<'a>
impl<'a> TaskSteps<'a>
Sourcepub const fn with_events(self, events: &'a dyn StepEvents) -> Self
pub const fn with_events(self, events: &'a dyn StepEvents) -> Self
The step executor, which tells events when each step starts to run and
when each comes from the cache, as kizz run asks for its live output.
Source§impl TaskSteps<'_>
impl TaskSteps<'_>
Sourcepub const fn with_cache_never(self, never: bool) -> Self
pub const fn with_cache_never(self, never: bool) -> Self
The step executor, which runs every step as if it were marked always, with
the reason that names the task option, when never says that the task is
marked cache=never. The option is in no step key.
Sourcepub fn decisions(&self) -> Vec<StepDecision>
pub fn decisions(&self) -> Vec<StepDecision>
What the build decided about each step so far, in order: why each one ran, or that it was cached.
Sourcepub fn commands(&self) -> Vec<CommandInput>
pub fn commands(&self) -> Vec<CommandInput>
The command of each step so far that reached a decision, in order, for the
observation report: a step that ran, or whose program kizz did not find,
with its outcome, its process tree and the lookup’s observations, and a step
that came from the cache as cached. A step whose bare program name has no
PATH is in it too, as a command that started no process, although it has
no decision. Empty unless the engine writes a report
(Engine::with_report).
Sourcepub fn finish(&self, succeeded: bool) -> Result<(), StoreError>
pub fn finish(&self, succeeded: bool) -> Result<(), StoreError>
End the run of the task: store the step positions of its cached steps, add
the task to the owners of the record each of them names, remove the positions
beyond its last step, and store its task record, all in one transaction, with
succeeded saying whether the run succeeded. Without a task identity this
stores nothing.
Every way a step is noted as cached makes its task an owner here: a hit on a
stored record, and a result reused within the build, an always result or a
result that was not cached, whose run stored the record under the key. A
record that the task already owns is not written again for its owners. A step
that ran stored its position and became its record’s owner when it ran.
§Errors
A StoreError when the records cannot be written.
Trait Implementations§
Auto Trait Implementations§
impl<'a> !Freeze for TaskSteps<'a>
impl<'a> !RefUnwindSafe for TaskSteps<'a>
impl<'a> !Send for TaskSteps<'a>
impl<'a> !Sync for TaskSteps<'a>
impl<'a> !UnwindSafe for TaskSteps<'a>
impl<'a> Unpin for TaskSteps<'a>
impl<'a> UnsafeUnpin for TaskSteps<'a>
Blanket Implementations§
impl<T> AsTypeStaticRegistered for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> HasTyVTable for Twhere
T: ?Sized,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more