Skip to content

ProcessManager: the task configuration used by the logs is not restored after a child task or a sub-process #333

Closed

Description

@njoubert-cleverage

ProcessManager keeps the task being executed in $taskConfiguration, read by the Monolog processors to add task_code and task_service to the logs (also persisted by the UI bundle). It is set when a task starts and set to null when it ends, but never restored to the previous value:

  • After a child task (outputs) has been processed, $taskConfiguration is null while its parent iterable task goes on: from the 2nd iteration, the logs of the parent task have no task_code nor task_service.
  • After a sub-process (process_executor), the task of the sub-process (or null) stays: the error of a failed sub-process is logged in the parent with the task_code of the task of the sub-process.
  • The early returns of process() (stop, empty iterable) skip the reset to null.

#301 restores the process history ($processHistory) in the same situations, not the task configuration.

Fix: restore the previous task configuration when process(), initialize(), finalize() and execute() end, including on early returns and exceptions.

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

Activity

  1. 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