Skip to content

StopTask: identify a process stopped on purpose as stopped, not as failed #337

Closed

Description

@njoubert-cleverage

The stop task (StopTask) is documented as "Immediately stops the process and marks its history as failed". A stop is not a failure, though: it is a decision of the process (e.g. not going on when the source file does not exist), and the process manager already handles it so (tasks finalized, cleverage_process.end event, exit code 0, parent process going on). But a stopped process cannot be told apart:

  • its history is flagged as failed and the Process … failed log is written (at the failed_level);
  • the cleverage_process.end event does not tell that the process was stopped: the UI records the execution as Finish, while it has a Stopped status (only used for the stop checkers).

Decision: keep the stop semantics (not a failure), and identify a stopped process clearly:

  • new ProcessHistory::STATE_STOPPED (setStopped(), isStopped()), set by the StopTask instead of the failed state;
  • Process <code> stopped log, at the success_level;
  • new ProcessEvent::isProcessStopped() on the cleverage_process.end event, used by the UI to record the execution as Stopped;
  • documentation of the stop task (difference with a failure, example on a missing source file).

Found during the global audit after the 5.4 release (process-bundle-audit.md #101).

Activity

  1. added 2 commits that reference this issue on Oct 23, 2026
  2. changed the title [-]StopTask: the process is marked as failed but does not fail (exit code 0, parent process goes on)[/-] [+]StopTask: identify a process stopped on purpose as stopped, not as failed[/+] on Oct 23, 2026
  3. added a commit that references this issue on Oct 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions