feat: Redesigning expected experiment states [DET-7278] [DET-7719]
Description
This WIP branch is following our Figma flowchart for more intuitive UI for Experiment State.
This change applies three rules:
- While the experiment.state is Active / Job is Scheduled, its UI label is "Running"
- If the experiment requires too many slots to ever run on an existing agent (currently using
(e.config->'resources'->>'slots_per_trial')::int <= (SELECT MAX(slots) FROM slots_by_agent)), its UI label is "Queued" - For these two states, the state badge UI will match on the Experiment List and Detail views
This is part of a larger project to change any state badge in the UI (Experiments, Trials, Tasks, Commands, and Jobs).
Test Plan
SQL to change an experiment slots_per_trial:
update experiments set config = config||'{"resources":{"slots_per_trial": 3}}' WHERE id = 1887;
There ought to be a helper function used in the decoder for Experiment and ExperimentList, which then has its own test.
From my testing: pause, stop, and complete appear to be consistently working.
Checklist
- [x] User-facing API changes need the "User-facing API Change" label.
- [x] Release notes should be added as a separate file under
docs/release-notes/. - [x] Licenses should be included for new code which was copied and/or modified from any external code.
Deploy Preview for determined-ui canceled.
| Name | Link |
|---|---|
| Latest commit | 43a11392d50bed77665064a0bf2752c927423fdd |
| Latest deploy log | https://app.netlify.com/sites/determined-ui/deploys/6320ec7816feb30009fc3d1c |
@mapmeld can we query plan 'get_active_allocations' in the most insane case and post back here? just to make sure we're not going to regret this.
Deploy Preview for storybook-det canceled.
| Name | Link |
|---|---|
| Latest commit | 43a11392d50bed77665064a0bf2752c927423fdd |
| Latest deploy log | https://app.netlify.com/sites/storybook-det/deploys/6320ec784d03680008e63aea |
@stoksc Added STATE_RUNNING back into the mix, and rebased to get the new experiments bun code, so hopefully that all runs through