mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-08-21 08:02:26 +00:00
fix request armageddon on flow status update for inner flows
This commit is contained in:
@@ -17,6 +17,7 @@
|
||||
import JobArgs from './JobArgs.svelte'
|
||||
import { Loader2 } from 'lucide-svelte'
|
||||
import FlowStatusWaitingForEvents from './FlowStatusWaitingForEvents.svelte'
|
||||
import { deepEqual } from 'fast-equals'
|
||||
|
||||
const dispatch = createEventDispatcher()
|
||||
|
||||
@@ -101,17 +102,21 @@
|
||||
mod.type === FlowStatusModule.type.WAITING_FOR_EXECUTOR &&
|
||||
localFlowModuleStates[mod.id ?? '']?.scheduled_for == undefined
|
||||
) {
|
||||
console.debug('updating', mod.job)
|
||||
JobService.getJob({
|
||||
workspace: workspaceId ?? $workspaceStore ?? '',
|
||||
id: mod.job ?? ''
|
||||
}).then((job) => {
|
||||
localFlowModuleStates[mod.id ?? ''] = {
|
||||
const newState = {
|
||||
type: mod.type,
|
||||
scheduled_for: job?.['scheduled_for'],
|
||||
job_id: job?.id,
|
||||
parent_module: mod['parent_module'],
|
||||
args: job?.args
|
||||
}
|
||||
if (!deepEqual(newState, localFlowModuleStates[mod.id ?? ''])) {
|
||||
localFlowModuleStates[mod.id ?? ''] = newState
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user