fix workflow run dead state after diagnostics back nav (#4776)
Co-authored-by: Suchintan Singh <suchintan@skyvern.com>
This commit is contained in:
@@ -70,7 +70,9 @@ function TaskDetails() {
|
||||
|
||||
const { data: workflowRun, isLoading: workflowRunIsLoading } =
|
||||
useQuery<WorkflowRunStatusApiResponse>({
|
||||
queryKey: ["workflowRun", task?.workflow_run_id],
|
||||
// Keep this cache separate from workflow-run pages, which store
|
||||
// a richer payload under ["workflowRun", workflowRunId].
|
||||
queryKey: ["taskWorkflowRun", task?.workflow_run_id],
|
||||
queryFn: async () => {
|
||||
const client = await getClient(credentialGetter);
|
||||
return client
|
||||
@@ -110,6 +112,9 @@ function TaskDetails() {
|
||||
queryClient.invalidateQueries({
|
||||
queryKey: ["workflowRun", task.workflow_run_id],
|
||||
});
|
||||
queryClient.invalidateQueries({
|
||||
queryKey: ["taskWorkflowRun", task.workflow_run_id],
|
||||
});
|
||||
queryClient.invalidateQueries({
|
||||
queryKey: [
|
||||
"workflowRun",
|
||||
|
||||
@@ -78,6 +78,9 @@ function WorkflowRunStream(props?: Props) {
|
||||
queryClient.invalidateQueries({
|
||||
queryKey: ["workflowRun", workflowRunId],
|
||||
});
|
||||
queryClient.invalidateQueries({
|
||||
queryKey: ["taskWorkflowRun", workflowRunId],
|
||||
});
|
||||
queryClient.invalidateQueries({
|
||||
queryKey: ["workflowTasks", workflowRunId],
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user