fix(pi-workflow): consume interrupted implementation recovery
This commit is contained in:
@@ -4348,16 +4348,17 @@ export class WorkflowEngine {
|
||||
next.status = "running";
|
||||
});
|
||||
if (run.implementationContext?.status === "ready") {
|
||||
if (interruptedMutating.length > 0) {
|
||||
if (
|
||||
interruptedMutating.length > 0 &&
|
||||
stage(run, "implement").status !== "completed"
|
||||
) {
|
||||
run = await this.transition(run, (next) => {
|
||||
const implement = stage(next, "implement");
|
||||
if (implement.status !== "completed") {
|
||||
implement.status = "completed";
|
||||
implement.finishedAt = this.now();
|
||||
implement.output = {
|
||||
recovery: "User requested a new remediation Assignment after interruption",
|
||||
};
|
||||
}
|
||||
implement.status = "completed";
|
||||
implement.finishedAt = this.now();
|
||||
implement.output = {
|
||||
recovery: "User requested a new remediation Assignment after interruption",
|
||||
};
|
||||
});
|
||||
return this.remediate(run);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user