Skip to content

Commit 00aa61c

Browse files
[24.2] Ensure job states are fetched in invocation view
Fixes galaxyproject#20003 We weren't checking if the job states summary had been fetched before we had the ``` if (invocationSchedulingTerminal.value && jobCount.value === 0) ``` check. `jobCount` would always be 0 if the states summary hadn't been fetched yet.
1 parent d44bac9 commit 00aa61c

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

client/src/components/WorkflowInvocationState/WorkflowInvocationState.vue

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,11 +108,16 @@ const invocationSchedulingTerminal = computed(() => {
108108
);
109109
});
110110
const jobStatesTerminal = computed(() => {
111+
// If the job states summary is null, we haven't fetched it yet
112+
if (jobStatesSummary.value === null) {
113+
return false;
114+
}
115+
111116
if (invocationSchedulingTerminal.value && jobCount.value === 0) {
112-
// no jobs for this invocation (think subworkflow or just inputs)
117+
// no jobs for this invocation (think it has just subworkflows/inputs)
113118
return true;
114119
}
115-
return !!jobStatesSummary.value && isTerminal(jobStatesSummary.value as InvocationJobsSummary);
120+
return isTerminal(jobStatesSummary.value);
116121
});
117122
const jobStatesSummary = computed(() => {
118123
const jobsSummary = invocationStore.getInvocationJobsSummaryById(props.invocationId);

0 commit comments

Comments
 (0)