Skip to content

fix(pausescheduling): mark paused work units and show them in the UI - #984

Merged
andrzejfudro merged 4 commits into
mainfrom
fix/scheduling-paused-status
Sep 28, 2026
Merged

andrzejfudro merged 4 commits into
mainfrom
fix/scheduling-paused-status

Conversation

@andrzejfudro

@andrzejfudro andrzejfudro commented Sep 25, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Fix updating SCHEDULING_PAUSED state and show the state in the UI.

Key Changes

  • Actuator pause handler: the WorkUnitExecution update mask now contains only status.state. status.state_update_time is not an updateable path in storage, so every pause-buffered task failed with InvalidArgument and went to the DLQ while the work unit stayed INITIALIZING. status.state already persists StateUpdateTime and requires it to be set.
  • UI status chip & table: new orange "Scheduling Paused" chip (distinct from yellow "Initializing" and grey "Scheduling"), mapped from SCHEDULING_PAUSED in the work units table.
  • UI status bar: orange segment for paused work units, ordered after INITIALIZING.
  • Tests: pause handler test expects the valid mask and checks StateUpdateTime; work units table test covers the paused label.

Verification

  • bazel test //cmd/actuator/pausescheduling:pausescheduling_test (Passed)
  • Prettier check on changed UI files (Passed); bazel build //cmd/ui:ui_image_tarball (Passed)
  • Verified end-to-end on a dev environment: paused work units transition to SCHEDULING_PAUSED and render the new chip.
  • UI unit tests and ESLint left to CI (local node_modules could not be installed).

Preview

image

TAG=agy
CONV=aca941d1-8c29-4820-96a9-0200c1071207

The pause handler sent "status.state_update_time" in the WorkUnitExecution
update mask. Storage rejects it as not updateable, so buffering a task during
a scheduling pause failed with InvalidArgument and the task went to the DLQ
while the work unit stayed INITIALIZING. "status.state" already persists
StateUpdateTime (and requires it to be set), so the mask now contains only
"status.state". The test asserts the timestamp is still populated.

TAG=agy
CONV=aca941d1-8c29-4820-96a9-0200c1071207
Work units in SCHEDULING_PAUSED fell through to the "Unknown" status chip.
Map the state to a "Scheduling Paused" chip with a dedicated orange style,
and add an orange segment for it in the experiment work units status bar so
admin-paused work is distinct from initializing and scheduling.

TAG=agy
CONV=aca941d1-8c29-4820-96a9-0200c1071207

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces support for the "SCHEDULING_PAUSED" status across both the backend and frontend. In the backend, the update mask for work unit executions is simplified to only require "status.state" (which implicitly persists the state update time), and the tests are updated to verify this behavior. In the frontend, the new "SCHEDULING_PAUSED" status is integrated into the status chip, status bar, and work units table components, along with corresponding orange styling and unit tests. There are no review comments, so I have no feedback to provide.

@andrzejfudro
andrzejfudro marked this pull request as ready for review September 25, 2026 07:42
@github-actions
github-actions Bot requested a review from pachopepe September 25, 2026 07:43
pachopepe
pachopepe previously approved these changes Sep 25, 2026
Addresses review feedback on #984: map SCHEDULING_PAUSED to
StatusOption.SCHEDULING_PAUSED in Header.getStatusOption so that
the work unit header chip does not display as Unknown.

#984 (comment)

TAG=agy
@andrzejfudro
andrzejfudro added this pull request to the merge queue Sep 28, 2026
Merged via the queue into main with commit ff9e76b Sep 28, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants