@burdenoff/fluidgrids-fe-sdk 2026.1111.22 → 2026.1111.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/dist/{AiStudioPage-DIfF4LhQ.js → AiStudioPage-NfhraV2M.js} +5 -5
  2. package/dist/{ApprovalInboxPage-dbBDSJ-f.js → ApprovalInboxPage-D8vhnloO.js} +1 -1
  3. package/dist/{DataSinkDashboardPage-DDvNPS8Z.js → DataSinkDashboardPage-BfdKumMH.js} +1 -1
  4. package/dist/{DataTablesPage-BpnF13UT.js → DataTablesPage-DoVBkb_T.js} +3 -3
  5. package/dist/{EntityTagPicker-BqRNsLCQ.js → EntityTagPicker-Dk3CufFt.js} +1 -1
  6. package/dist/{ExecutionDetailPage-DYLWtHRG.js → ExecutionDetailPage-Dtpn7Xnl.js} +20 -15
  7. package/dist/{ExecutionsListPage-D63aCXJH.js → ExecutionsListPage-DeqJnEO7.js} +9 -9
  8. package/dist/{FailureTriagePanel-B9hDQymi.js → FailureTriagePanel-BzD4UJU5.js} +2 -2
  9. package/dist/{FluidGridsProvider-CWyQ8ziM.js → FluidGridsProvider-BuZERrTA.js} +245 -38
  10. package/dist/{HistoryPage-CNXgUMb0.js → HistoryPage-BC7ld-oQ.js} +2 -2
  11. package/dist/{HumanRequestCard-D-ooVPDn.js → HumanRequestCard-mOhr-Ic9.js} +239 -31
  12. package/dist/{InsightsPage-Duo83yAM.js → InsightsPage-C8X1g_Ya.js} +6 -6
  13. package/dist/{MissingNodesInstallModal-Q3RYBvS8.js → MissingNodesInstallModal-DUmwDs4e.js} +1 -1
  14. package/dist/{NodesPage-Bf5PhfBK.js → NodesPage-Dhg5Q2R5.js} +2 -2
  15. package/dist/{QuotaExhaustedDialog-ChBoJnRo.js → QuotaExhaustedDialog-RctNPfz_.js} +1 -1
  16. package/dist/{SettingsPage-DI_vIG7t.js → SettingsPage-BbE4S63W.js} +6 -6
  17. package/dist/{TagFilterSelect-DCBOH6Ou.js → TagFilterSelect-VC6JMK3F.js} +1 -1
  18. package/dist/{TaskQueuesPage-9VgSnLdL.js → TaskQueuesPage-C3R5ZoKs.js} +2 -2
  19. package/dist/{TemplateCard-6W2q2wiK.js → TemplateCard-D800haiE.js} +2 -2
  20. package/dist/{TemplateConfigurationModal-qNQGP7cm.js → TemplateConfigurationModal-DYs1YxYy.js} +1 -1
  21. package/dist/{TemplateDetailPanel-CQvYqhVO.js → TemplateDetailPanel-CKhCQlyo.js} +1 -1
  22. package/dist/{TemplatePreview-t3251W_n.js → TemplatePreview-DbF97Jwi.js} +3 -3
  23. package/dist/{TemplatesPage-Bvg6R2P9.js → TemplatesPage-BR6iOnC0.js} +5 -5
  24. package/dist/{VersionDiffDialog-DSN0mU0f.js → VersionDiffDialog-B00qeGiE.js} +1 -1
  25. package/dist/{WorkflowBuilder-C-hgvww2.js → WorkflowBuilder-BWqiMpdk.js} +3 -3
  26. package/dist/{WorkflowBuilder-DdvSGsxr.js → WorkflowBuilder-CWsUITzN.js} +8 -8
  27. package/dist/{WorkflowProposalCard-qrEeNyYG.js → WorkflowProposalCard-U31u1qcw.js} +2 -2
  28. package/dist/{WorkflowSearchRedirect-33Vs4FKc.js → WorkflowSearchRedirect-7Kc7NniX.js} +1 -1
  29. package/dist/{WorkflowShareDialog-mbIwRQUY.js → WorkflowShareDialog-Dv46nAyh.js} +2 -2
  30. package/dist/{WorkflowsList-C3bHLpSv.js → WorkflowsList-Bnov6LCT.js} +8 -8
  31. package/dist/{agentTools-BjhxAdlt.js → agentTools-yi8CDKzs.js} +3 -3
  32. package/dist/{ai-usage-glCwHyQz.js → ai-usage-bmUn-gJP.js} +1 -1
  33. package/dist/{api-C8e0iV-Q.js → api-C8WmUejq.js} +1 -1
  34. package/dist/{api-BrCHB5oA.js → api-DwaHAJtA.js} +1 -1
  35. package/dist/{canvasNoteTools-CZEFFhRp.js → canvasNoteTools-kRtdgYMQ.js} +2 -2
  36. package/dist/{code-editor-field-CfP0QYUD.js → code-editor-field-Dg2U8mk1.js} +1 -1
  37. package/dist/executions.js +2 -2
  38. package/dist/{flow-builder-CE8cNXNi.js → flow-builder-CEYMv_sG.js} +17 -17
  39. package/dist/{graphql-operation-types-kX-MMjgW.js → graphql-operation-types-BdU65FNm.js} +413 -1
  40. package/dist/{graphql-types-CDKVWH2R.js → graphql-types-v6CTGwA0.js} +470 -39
  41. package/dist/history.js +1 -1
  42. package/dist/{index-7eJQwsNS.d.ts → index-T8fJI6Ys.d.ts} +2073 -99
  43. package/dist/index.d.ts +2 -2
  44. package/dist/index.js +35 -35
  45. package/dist/{node-detail-view-BoR0vYZ3.js → node-detail-view-Ft8huQ5T.js} +9 -9
  46. package/dist/{node-editor-tab-body-DxMbKspp.js → node-editor-tab-body-CjwxJdlF.js} +2 -2
  47. package/dist/{node-endpoint-configs-B5bjNMDW.js → node-endpoint-configs-BrzQMy10.js} +1 -1
  48. package/dist/nodes.js +1 -1
  49. package/dist/observability.d.ts +1 -1
  50. package/dist/observability.js +2 -2
  51. package/dist/{popover-B1aKz7DC.js → popover-B6Rjrhar.js} +2 -2
  52. package/dist/{quick-config-panel-DXvLJdeW.js → quick-config-panel-D95dc_2F.js} +3 -3
  53. package/dist/{run-list-links-ByYC0OlV.js → run-list-links-eUhZB1ju.js} +1 -1
  54. package/dist/{schedule-panel-CY6S4JMd.js → schedule-panel-C-N92gxl.js} +157 -11
  55. package/dist/settings.js +1 -1
  56. package/dist/{sidebar-node-editor-FU3fvOjh.js → sidebar-node-editor-BHBicLCn.js} +3 -3
  57. package/dist/templates.js +2 -2
  58. package/dist/{useAgentDefinitions-B0dam3_o.js → useAgentDefinitions-DSU8Eek4.js} +1 -1
  59. package/dist/{useDurableParity-BApRraSO.js → useDurableParity-DEceXnEa.js} +2 -2
  60. package/dist/{useEntityTags-DhnsZcTl.js → useEntityTags-C8rPBi6W.js} +1 -1
  61. package/dist/{useExecutions-C2a4EcvC.js → useExecutions-D3S4aqIQ.js} +3 -3
  62. package/dist/{useObservability-BmbeK5bG.js → useObservability-B9cOl5mw.js} +1 -1
  63. package/dist/{useRunHistory-CqfDFRzr.js → useRunHistory-uTJepemz.js} +3 -3
  64. package/dist/{useWorkflowCodeExport-DebpM48M.js → useWorkflowCodeExport-L-5NIRiH.js} +3 -3
  65. package/dist/{useWorkflows-D1-rYzGK.js → useWorkflows-D9BlhpWH.js} +2 -2
  66. package/dist/workflow-builder.js +4 -4
  67. package/dist/workflow-pages.d.ts +1 -1
  68. package/dist/workflow-pages.js +17 -17
  69. package/dist/workflows-list.js +1 -1
  70. package/package.json +1 -1
@@ -1,15 +1,15 @@
1
1
  "use client";
2
2
  import { t as __exportAll } from "./rolldown-runtime-hDbaFkMy.js";
3
3
  import { t as ThemeProvider } from "./theme-provider-B3mIuz2d.js";
4
- import { a as useAiWorkflowTemplates, i as enrichDraftNodes, n as AI_DRAFT_MAX_PROMPT_LENGTH, r as draftToCanvas, t as FlowBuilderPage } from "./flow-builder-CE8cNXNi.js";
5
- import { Ot as builderPathOf, kt as classifyCreateRefusal, u as ensureNodeTypesLoaded, z as buildOperationSeed } from "./FluidGridsProvider-CWyQ8ziM.js";
4
+ import { a as useAiWorkflowTemplates, i as enrichDraftNodes, n as AI_DRAFT_MAX_PROMPT_LENGTH, r as draftToCanvas, t as FlowBuilderPage } from "./flow-builder-CEYMv_sG.js";
5
+ import { Ot as builderPathOf, kt as classifyCreateRefusal, u as ensureNodeTypesLoaded, z as buildOperationSeed } from "./FluidGridsProvider-BuZERrTA.js";
6
6
  import { _ as throwIfResultError, n as getFluidGridsClient } from "./client-C9XSzSXr.js";
7
7
  import { a as notifyFluidGridsAiCreditsUpdated, t as AiCreditBalanceSlot } from "./aiCreditsBridge-BuE92tKo.js";
8
- import { Pr as WorkflowGenerationDocument, y as CancelWorkflowGenerationDocument, yt as GenerateWorkflowFromPromptDocument } from "./graphql-operation-types-kX-MMjgW.js";
9
- import { n as useCreateWorkflow } from "./useWorkflows-D1-rYzGK.js";
8
+ import { Ir as WorkflowGenerationDocument, x as CancelWorkflowGenerationDocument, xt as GenerateWorkflowFromPromptDocument } from "./graphql-operation-types-BdU65FNm.js";
9
+ import { n as useCreateWorkflow } from "./useWorkflows-D9BlhpWH.js";
10
10
  import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
11
11
  import { t as BILLING_PLANS_PATH } from "./quota-Cdt8yz7N.js";
12
- import { T as CreateWorkflowRefusalDialog } from "./useWorkflowCodeExport-DebpM48M.js";
12
+ import { T as CreateWorkflowRefusalDialog } from "./useWorkflowCodeExport-L-5NIRiH.js";
13
13
  import { s as useFluidGridsPermission, t as FLUIDGRIDS_PERMISSIONS } from "./constants-B2lhWNoN.js";
14
14
  import { useCallback, useEffect, useMemo, useRef, useState } from "react";
15
15
  import { useNavigate } from "react-router";
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { t as __exportAll } from "./rolldown-runtime-hDbaFkMy.js";
3
3
  import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
4
- import { r as usePendingHumanRequests, t as HumanRequestCard } from "./HumanRequestCard-D-ooVPDn.js";
4
+ import { i as usePendingHumanRequests, t as HumanRequestCard } from "./HumanRequestCard-mOhr-Ic9.js";
5
5
  import { t as FluidGridsDocsLink } from "./FluidGridsDocsLink-JxkBpOeb.js";
6
6
  import { _ as throwIfResultError, h as isForbiddenError, n as getFluidGridsClient } from "./client-C9XSzSXr.js";
7
7
  import { i as SdkPermissionButton, s as useFluidGridsPermission, t as FLUIDGRIDS_PERMISSIONS } from "./constants-B2lhWNoN.js";
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { t as __exportAll } from "./rolldown-runtime-hDbaFkMy.js";
3
3
  import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
4
- import { n as useDataSinks, t as useDataSinkData } from "./useObservability-BmbeK5bG.js";
4
+ import { n as useDataSinks, t as useDataSinkData } from "./useObservability-B9cOl5mw.js";
5
5
  import { s as prettyJson, t as formatBytes } from "./utils-uaL5UVxb.js";
6
6
  import { useEffect, useMemo, useState } from "react";
7
7
  import { Icon } from "@iconify/react";
@@ -1,9 +1,9 @@
1
1
  "use client";
2
2
  import { t as __exportAll } from "./rolldown-runtime-hDbaFkMy.js";
3
- import { t as EntityTagPicker } from "./EntityTagPicker-BqRNsLCQ.js";
4
- import { t as TagFilterSelect } from "./TagFilterSelect-DCBOH6Ou.js";
3
+ import { t as EntityTagPicker } from "./EntityTagPicker-Dk3CufFt.js";
4
+ import { t as TagFilterSelect } from "./TagFilterSelect-VC6JMK3F.js";
5
5
  import { _ as throwIfResultError, m as describeOperationError, n as getFluidGridsClient } from "./client-C9XSzSXr.js";
6
- import { a as useDataTableTagOverlay, n as tagLabel } from "./useEntityTags-DhnsZcTl.js";
6
+ import { a as useDataTableTagOverlay, n as tagLabel } from "./useEntityTags-C8rPBi6W.js";
7
7
  import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
8
8
  import { i as useOpenRequest, n as ACTION_PARAM_VALUES, r as useActionParam } from "./useActionParam-B0ebTZmg.js";
9
9
  import { i as SdkPermissionButton, s as useFluidGridsPermission, t as FLUIDGRIDS_PERMISSIONS } from "./constants-B2lhWNoN.js";
@@ -1,6 +1,6 @@
1
1
  "use client";
2
2
  import { x as getFluidGridsConfig } from "./client-C9XSzSXr.js";
3
- import { d as useUntagEntity, s as useEntityTags, u as useTagEntity } from "./useEntityTags-DhnsZcTl.js";
3
+ import { d as useUntagEntity, s as useEntityTags, u as useTagEntity } from "./useEntityTags-C8rPBi6W.js";
4
4
  import { useCallback, useEffect, useRef, useState } from "react";
5
5
  import { jsx } from "react/jsx-runtime";
6
6
  import { TagBadge, TagsWidget } from "@burdenoff/fe-libs/tag";
@@ -1,29 +1,29 @@
1
1
  "use client";
2
2
  import { t as __exportAll } from "./rolldown-runtime-hDbaFkMy.js";
3
- import { i as useRunPending, n as useDurableParityRunFields, o as ExecutionStatusBadge, r as useRunMetadata, s as NodeStatusBadge, t as setRunVersioningOverride } from "./useDurableParity-BApRraSO.js";
3
+ import { i as useRunPending, n as useDurableParityRunFields, o as ExecutionStatusBadge, r as useRunMetadata, s as NodeStatusBadge, t as setRunVersioningOverride } from "./useDurableParity-DEceXnEa.js";
4
4
  import { n as formatRunVersion, r as nodeDisplayTitle, t as buildNodeDisplayMap } from "./run-display-BycKYSU0.js";
5
5
  import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
6
6
  import { s as isAgentNodeType } from "./agent-form-Bfvm32j1.js";
7
- import { Cn as canSignalRun, I as describeRunError, L as describeRunStep, On as runSignalTargets, Tn as durableInterfaceOf, cn as nodeStateDurationMs, ln as runDurationMs, sn as formatElapsedMs } from "./FluidGridsProvider-CWyQ8ziM.js";
7
+ import { Cn as canSignalRun, I as describeRunError, L as describeRunStep, On as runSignalTargets, Tn as durableInterfaceOf, cn as nodeStateDurationMs, ln as runDurationMs, sn as formatElapsedMs } from "./FluidGridsProvider-BuZERrTA.js";
8
8
  import { n as useFgAskable, r as useFgAskableSelection } from "./askAboutBridge-BV8m95kk.js";
9
- import { f as callbackTone, g as shortRunId, h as runChainLinks, m as parseMetadataDefinition, n as useExecution, p as overrideRequestOf, r as useExecutionActions, t as useAutoRefresh } from "./useExecutions-C2a4EcvC.js";
9
+ import { f as callbackTone, g as shortRunId, h as runChainLinks, m as parseMetadataDefinition, n as useExecution, p as overrideRequestOf, r as useExecutionActions, t as useAutoRefresh } from "./useExecutions-D3S4aqIQ.js";
10
10
  import { _ as throwIfResultError, m as describeOperationError, n as getFluidGridsClient, r as getFluidGridsClientSafe, x as getFluidGridsConfig } from "./client-C9XSzSXr.js";
11
- import { Yr as WorkflowRunHierarchyDocument, dn as RunAiUsageDocument, o as AgentStepUpdatedDocument, s as AgentTraceDocument, ut as ExplainRunDocument, xn as RunLogsDocument, yn as RunLogAppendedDocument } from "./graphql-operation-types-kX-MMjgW.js";
11
+ import { Cn as RunLogsDocument, Zr as WorkflowRunHierarchyDocument, ft as ExplainRunDocument, o as AgentStepUpdatedDocument, pn as RunAiUsageDocument, s as AgentTraceDocument, xn as RunLogAppendedDocument } from "./graphql-operation-types-BdU65FNm.js";
12
12
  import { i as SdkPermissionButton, s as useFluidGridsPermission, t as FLUIDGRIDS_PERMISSIONS } from "./constants-B2lhWNoN.js";
13
- import { t as EntityTagPicker } from "./EntityTagPicker-BqRNsLCQ.js";
14
- import { a as useRunHumanRequests, n as channelLabel, o as useRecipientLabel } from "./HumanRequestCard-D-ooVPDn.js";
13
+ import { t as EntityTagPicker } from "./EntityTagPicker-Dk3CufFt.js";
14
+ import { n as channelLabel, o as useRunHumanRequests, r as ApprovalApprovers, s as useRecipientLabel } from "./HumanRequestCard-mOhr-Ic9.js";
15
15
  import { a as encodedPayloadBytes, f as EffectBadge, h as useRunPolicyDecisions, i as decodePayloads, l as formatBudgetUsd, n as checkCodecServerUrl, o as isEncodedPayload, r as containsEncodedPayload, t as CodecServerError } from "./codec-client-CJ95Rmqo.js";
16
- import { n as useWorkflowProposal, o as canSaveRunAsTestCase, r as saveRunAsTestCase, t as WorkflowProposalCard } from "./WorkflowProposalCard-qrEeNyYG.js";
16
+ import { n as useWorkflowProposal, o as canSaveRunAsTestCase, r as saveRunAsTestCase, t as WorkflowProposalCard } from "./WorkflowProposalCard-U31u1qcw.js";
17
17
  import { t as AiCreditBalanceSlot } from "./aiCreditsBridge-BuE92tKo.js";
18
- import { a as fetchRunFailureClusters, i as dismissRunFailureCluster, r as OPEN_STATUSES, t as BUCKET_LABELS } from "./FailureTriagePanel-B9hDQymi.js";
19
- import { a as useDurableRunFields, i as useDeterminismStatus, n as SignalRunDialog, o as useRunStackTrace, r as terminateDurableRun, s as RunHistoryView, t as useRunHistory } from "./useRunHistory-CqfDFRzr.js";
20
- import { $u as ErrorType, L as AgentStepKind, LF as WorkflowQueryRejectCondition, tI as WorkflowUpdateWaitFor, yP as VersioningBehavior } from "./graphql-types-CDKVWH2R.js";
21
- import { a as formatTokens, d as formatMicroUsd, o as modelLabel, r as aiCost } from "./ai-usage-glCwHyQz.js";
18
+ import { a as fetchRunFailureClusters, i as dismissRunFailureCluster, r as OPEN_STATUSES, t as BUCKET_LABELS } from "./FailureTriagePanel-BzD4UJU5.js";
19
+ import { a as useDurableRunFields, i as useDeterminismStatus, n as SignalRunDialog, o as useRunStackTrace, r as terminateDurableRun, s as RunHistoryView, t as useRunHistory } from "./useRunHistory-uTJepemz.js";
20
+ import { $P as VersioningBehavior, FI as WorkflowUpdateWaitFor, L as AgentStepKind, _I as WorkflowQueryRejectCondition, jd as ErrorType } from "./graphql-types-v6CTGwA0.js";
21
+ import { a as formatTokens, d as formatMicroUsd, o as modelLabel, r as aiCost } from "./ai-usage-bmUn-gJP.js";
22
22
  import { c as useDurableParityEnabled, f as usePhaseCFlags, m as useWorkflowTestsEnabled, s as useDurableFunctionNodesEnabled } from "./feature-flags-DM5myWaD.js";
23
- import { A as revokeSignalToken, B as updateActivityOptions, D as resetActivities, E as queryRun, N as sendRunUpdate, O as resetRun, R as unpauseActivities, S as fetchSignalTokens, V as upsertRunSearchAttributes, _ as fetchPauseRules, b as fetchRunUpdate, d as failActivityById, g as fetchCodecServerSettings, i as completeActivityById, k as resetRunToLastCleanTask, s as createSignalToken, v as fetchRunControlFields, w as pauseActivities, y as fetchRunHistoryArchive } from "./api-BrCHB5oA.js";
24
- import { a as fetchTaskQueueStats } from "./api-C8e0iV-Q.js";
23
+ import { A as revokeSignalToken, B as updateActivityOptions, D as resetActivities, E as queryRun, N as sendRunUpdate, O as resetRun, R as unpauseActivities, S as fetchSignalTokens, V as upsertRunSearchAttributes, _ as fetchPauseRules, b as fetchRunUpdate, d as failActivityById, g as fetchCodecServerSettings, i as completeActivityById, k as resetRunToLastCleanTask, s as createSignalToken, v as fetchRunControlFields, w as pauseActivities, y as fetchRunHistoryArchive } from "./api-DwaHAJtA.js";
24
+ import { a as fetchTaskQueueStats } from "./api-C8WmUejq.js";
25
25
  import { a as RUN_CONTROL_DIALOG_STYLE, c as parseJsonInput, i as NativeSelect, l as parseJsonObjectInput, n as JsonBlock, o as StatusPill, r as JsonField, s as newRunControlId, t as FieldError, u as useResource } from "./shared-CMfn30xT.js";
26
- import { v as useWorkflowVersions } from "./useWorkflows-D1-rYzGK.js";
26
+ import { v as useWorkflowVersions } from "./useWorkflows-D9BlhpWH.js";
27
27
  import { useCallback, useEffect, useMemo, useRef, useState } from "react";
28
28
  import { Link, useNavigate, useParams, useSearchParams } from "react-router";
29
29
  import { Icon } from "@iconify/react";
@@ -1355,7 +1355,8 @@ function answerRows(request, tr) {
1355
1355
  // src/modules/human-response/components/RunHumanRequests.tsx
1356
1356
  /**
1357
1357
  * Run detail: the asks a "Send and Wait for Response" node made (BOFF-7651) — who was asked, by
1358
- * which channel, until when, and what came back. Renders nothing for runs that asked nobody.
1358
+ * which channel, until when, and what came back. An approval lists its approvers with each one's
1359
+ * answer and comment (BOFF-9956). Renders nothing for runs that asked nobody.
1359
1360
  */
1360
1361
  function outcome(request, tr) {
1361
1362
  const when = request.respondedAt ? new Date(request.respondedAt).toLocaleString() : "";
@@ -1405,6 +1406,10 @@ function RunHumanRequestRow({ request }) {
1405
1406
  outcome(request, tr)
1406
1407
  ]
1407
1408
  }),
1409
+ (request.approvals?.length ?? 0) > 0 && /* @__PURE__ */ jsx("div", {
1410
+ className: "mt-1 w-full sm:mt-0",
1411
+ children: /* @__PURE__ */ jsx(ApprovalApprovers, { request })
1412
+ }),
1408
1413
  answer.length > 0 && /* @__PURE__ */ jsx("dl", {
1409
1414
  className: "mt-1 w-full space-y-0.5 text-xs sm:mt-0",
1410
1415
  "data-testid": "run-human-answer",
@@ -1,23 +1,23 @@
1
1
  "use client";
2
2
  import { t as __exportAll } from "./rolldown-runtime-hDbaFkMy.js";
3
3
  import { M as DEFAULT_EXECUTIONS_FILTER, N as useExecutionsStore, m as describeOperationError, n as getFluidGridsClient } from "./client-C9XSzSXr.js";
4
- import { c as OPERATORS_BY_TYPE, i as useExecutionStats, l as buildSearchAttributeFilter, o as useExecutionsWithStore, r as useExecutionActions, s as EMPTY_SEARCH_FILTER, t as useAutoRefresh, u as searchFilterConflicts, y as validateDateRange } from "./useExecutions-C2a4EcvC.js";
4
+ import { c as OPERATORS_BY_TYPE, i as useExecutionStats, l as buildSearchAttributeFilter, o as useExecutionsWithStore, r as useExecutionActions, s as EMPTY_SEARCH_FILTER, t as useAutoRefresh, u as searchFilterConflicts, y as validateDateRange } from "./useExecutions-D3S4aqIQ.js";
5
5
  import { c as useDurableParityEnabled, f as usePhaseCFlags } from "./feature-flags-DM5myWaD.js";
6
6
  import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
7
7
  import { n as useFluidGridsPageControls } from "./pageControlsBridge-0pX9s-3k.js";
8
8
  import { t as executionsControls } from "./pageControlSpecs-DZJ9K37m.js";
9
- import { t as TagFilterSelect } from "./TagFilterSelect-DCBOH6Ou.js";
10
- import { a as useRunStatusCounts, c as runStatusLabels, l as RUN_STATUS_CONFIG, o as ExecutionStatusBadge } from "./useDurableParity-BApRraSO.js";
9
+ import { t as TagFilterSelect } from "./TagFilterSelect-VC6JMK3F.js";
10
+ import { a as useRunStatusCounts, c as runStatusLabels, l as RUN_STATUS_CONFIG, o as ExecutionStatusBadge } from "./useDurableParity-DEceXnEa.js";
11
11
  import { n as formatRunVersion } from "./run-display-BycKYSU0.js";
12
- import { ln as runDurationMs, sn as formatElapsedMs } from "./FluidGridsProvider-CWyQ8ziM.js";
13
- import { n as runListLinkKey, t as runListFilterFromSearch } from "./run-list-links-ByYC0OlV.js";
14
- import { h as useWorkflowDefinitions } from "./useWorkflows-D1-rYzGK.js";
12
+ import { ln as runDurationMs, sn as formatElapsedMs } from "./FluidGridsProvider-BuZERrTA.js";
13
+ import { n as runListLinkKey, t as runListFilterFromSearch } from "./run-list-links-eUhZB1ju.js";
14
+ import { h as useWorkflowDefinitions } from "./useWorkflows-D9BlhpWH.js";
15
15
  import { t as FluidGridsDocsLink } from "./FluidGridsDocsLink-JxkBpOeb.js";
16
16
  import { s as useFluidGridsPermission, t as FLUIDGRIDS_PERMISSIONS } from "./constants-B2lhWNoN.js";
17
- import { C as jsonArg, F as startBatchOperation, I as startBatchTerminate, P as startBatchExport, m as fetchBatchOperations, n as cancelBatchOperation, p as fetchBatchOperation, x as fetchSearchAttributes } from "./api-BrCHB5oA.js";
17
+ import { C as jsonArg, F as startBatchOperation, I as startBatchTerminate, P as startBatchExport, m as fetchBatchOperations, n as cancelBatchOperation, p as fetchBatchOperation, x as fetchSearchAttributes } from "./api-DwaHAJtA.js";
18
18
  import { a as RUN_CONTROL_DIALOG_STYLE, c as parseJsonInput, i as NativeSelect, o as StatusPill, r as JsonField, t as FieldError, u as useResource } from "./shared-CMfn30xT.js";
19
- import { xr as WorkflowBatchOperationUpdatedDocument } from "./graphql-operation-types-kX-MMjgW.js";
20
- import { RF as WorkflowResetType, bF as WorkflowBatchOperationType } from "./graphql-types-CDKVWH2R.js";
19
+ import { Cr as WorkflowBatchOperationUpdatedDocument } from "./graphql-operation-types-BdU65FNm.js";
20
+ import { $F as WorkflowBatchOperationType, vI as WorkflowResetType } from "./graphql-types-v6CTGwA0.js";
21
21
  import { useCallback, useEffect, useMemo, useRef, useState } from "react";
22
22
  import { useNavigate, useSearchParams } from "react-router";
23
23
  import { Icon } from "@iconify/react";
@@ -1,8 +1,8 @@
1
1
  "use client";
2
2
  import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
3
3
  import { _ as throwIfResultError, n as getFluidGridsClient } from "./client-C9XSzSXr.js";
4
- import { On as SetRunFailureTriageEnabledDocument, Q as DismissRunFailureClusterDocument, gn as RunFailureTriageSettingsDocument, hn as RunFailureClustersDocument, mt as FgTriageFailedRunsDocument } from "./graphql-operation-types-kX-MMjgW.js";
5
- import { mD as RunFailureClusterStatus } from "./graphql-types-CDKVWH2R.js";
4
+ import { An as SetRunFailureTriageEnabledDocument, _n as RunFailureClustersDocument, et as DismissRunFailureClusterDocument, gt as FgTriageFailedRunsDocument, vn as RunFailureTriageSettingsDocument } from "./graphql-operation-types-BdU65FNm.js";
5
+ import { qD as RunFailureClusterStatus } from "./graphql-types-v6CTGwA0.js";
6
6
  import { useCallback, useEffect, useState } from "react";
7
7
  import { Icon } from "@iconify/react";
8
8
  import { jsx, jsxs } from "react/jsx-runtime";
@@ -5,11 +5,11 @@ import { i as getGlobalStoreClient, o as resetGlobalStoreClient, r as createGlob
5
5
  import { A as nodeAccent, C as nodeAdaptersOf, D as NodeCard, E as resolveOutputHandles, H as useFlowStore, I as partitionStickyNotes, L as resolveStickyColor, N as DEFAULT_STICKY_COLOR, O as NodeCardBody, P as STICKY_COLORS, R as stickySurfaceStyle, T as resolveInputHandles, V as STICKY_NOTE_TYPE, W as isNodeTrigger, _ as LogicNodeCard, b as alignPlainOutputEdges, i as WAIT_FOR_SIGNAL_NODE_TYPE, j as NodeTypeIcon, k as NodeCardHeader, l as interfaceFields, m as readSignalName, n as synchronizeOperationUpdate, p as readCodeWorkflowState, r as CODE_WORKFLOW_NODE_TYPE, t as resolveOperationName, u as interfaceHandlers, v as InputHandles, w as outputHandlesSpacerHeight, x as hasNodeManifest, y as OutputHandles } from "./node-operation-selection--oy-yEq_.js";
6
6
  import { n as FluidGridsTranslationProvider, r as useTr, t as ENGLISH_FALLBACK_TRANSLATOR } from "./TranslationBridge-Da-TPgQm.js";
7
7
  import { s as useDurableFunctionNodesEnabled } from "./feature-flags-DM5myWaD.js";
8
- import { A as CreateWorkflowDefinitionDocument, At as NodePaletteEntriesDocument, Er as WorkflowDefinitionDocument, L as CreateWorkflowVersionDocument, Tn as SaveWorkflowDraftDocument, _n as RunFromNodeDocument, at as ExecuteStepDocument, it as EventRegistrationsDocument, kt as NodeManifestsDocument, ot as ExecutionDetailDocument, qn as TriggerWorkflowDocument, qr as WorkflowRunDocument } from "./graphql-operation-types-kX-MMjgW.js";
8
+ import { Dn as SaveWorkflowDraftDocument, M as CreateWorkflowDefinitionDocument, Mt as NodePaletteEntriesDocument, Or as WorkflowDefinitionDocument, Yn as TriggerWorkflowDocument, ct as ExecutionDetailDocument, h as BuilderRunStatusDocument, jt as NodeManifestsDocument, m as BuilderRunNodeDetailsDocument, ot as EventRegistrationsDocument, st as ExecuteStepDocument, yn as RunFromNodeDocument, z as CreateWorkflowVersionDocument } from "./graphql-operation-types-BdU65FNm.js";
9
9
  import { a as collectExtensions, n as QUOTA_EXHAUSTED_CODE, o as errorCodesOf, r as RUNS_QUOTA_NAME, s as findQuotaRefusal } from "./quota-Cdt8yz7N.js";
10
10
  import { i as emitRunStarted, n as emitRunFailed, r as emitRunLimitHit, s as emitWorkflowCreated } from "./fluidgridsEvents-Dm5CaHtr.js";
11
11
  import { n as useFgAskable } from "./askAboutBridge-BV8m95kk.js";
12
- import { t as fetchAllNodeEndpointConfigs } from "./node-endpoint-configs-B5bjNMDW.js";
12
+ import { t as fetchAllNodeEndpointConfigs } from "./node-endpoint-configs-BrzQMy10.js";
13
13
  import { createContext, memo, useCallback, useContext, useEffect, useMemo, useRef, useState, useSyncExternalStore } from "react";
14
14
  import { useNavigate, useParams } from "react-router";
15
15
  import { ApolloProvider } from "@apollo/client/react";
@@ -1607,10 +1607,158 @@ function formatElapsedMs(ms, empty = "-") {
1607
1607
  return `${Math.floor(totalMinutes / 60)}h ${totalMinutes % 60}m`;
1608
1608
  }
1609
1609
 
1610
+ // src/hooks/run-follow.ts
1611
+ /**
1612
+ * Time between the starts of consecutive status polls, in ms, by poll number:
1613
+ * the poll after the first goes out 300 ms after it, and so on. A run that ends
1614
+ * within a couple of seconds is seen almost at once; a longer one is read every
1615
+ * {@link RUN_POLL_STEADY_MS}.
1616
+ */
1617
+ const RUN_POLL_PERIODS_MS = [
1618
+ 300,
1619
+ 300,
1620
+ 400,
1621
+ 500,
1622
+ 700,
1623
+ 1e3
1624
+ ];
1625
+ /** Time between the starts of status polls once a run has run for ~5 s. */
1626
+ const RUN_POLL_STEADY_MS = 1500;
1627
+ /** Time before a poll that failed (network or GraphQL error) is retried. */
1628
+ const RUN_POLL_RETRY_MS = 3e3;
1629
+ /** Most node state ids one details read asks for (the service accepts 500). */
1630
+ const MAX_DETAIL_IDS_PER_READ = 500;
1631
+ /** Attempts of one details read before its node states are given up on. */
1632
+ const MAX_DETAIL_ATTEMPTS = 3;
1633
+ /** Time before a failed details read is tried again. */
1634
+ const DETAIL_RETRY_MS = 2e3;
1635
+ /**
1636
+ * How long to wait after poll number `poll` (0 = the first) started before the
1637
+ * next one starts.
1638
+ */
1639
+ function runPollPeriodMs(poll) {
1640
+ return RUN_POLL_PERIODS_MS[poll] ?? 1500;
1641
+ }
1642
+ /**
1643
+ * The delay before the next poll, given when the last one started: the period
1644
+ * is measured from start to start, so a slow answer does not stretch it.
1645
+ */
1646
+ function nextPollDelayMs(poll, startedAt, now) {
1647
+ return Math.max(0, runPollPeriodMs(poll) - (now - startedAt));
1648
+ }
1649
+ /**
1650
+ * Maps the service's node status to the builder's four states.
1651
+ * WAITING / DELAYED / WAITING_SUBWORKFLOW are paused-but-active, so the
1652
+ * builder shows them as running. Anything else that is not over (PENDING,
1653
+ * SKIPPED, CANCELLED) gets no log line.
1654
+ */
1655
+ function toRunLogStatus(rawStatus) {
1656
+ switch (rawStatus.toLowerCase()) {
1657
+ case "completed": return "completed";
1658
+ case "failed":
1659
+ case "timeout": return "failed";
1660
+ case "running":
1661
+ case "waiting":
1662
+ case "delayed":
1663
+ case "waiting_subworkflow": return "running";
1664
+ default: return "pending";
1665
+ }
1666
+ }
1667
+ /**
1668
+ * One node state per node: the last one in the run's order (oldest first), so
1669
+ * a node that ran several times (a loop) shows its latest run.
1670
+ */
1671
+ function latestNodeStates(nodeStates) {
1672
+ const latest = /* @__PURE__ */ new Map();
1673
+ for (const nodeState of nodeStates) {
1674
+ latest.delete(nodeState.nodeId);
1675
+ latest.set(nodeState.nodeId, nodeState);
1676
+ }
1677
+ return [...latest.values()];
1678
+ }
1679
+ /**
1680
+ * Reads node inputs and outputs for the run the builder follows, once per node
1681
+ * state and status: the status poll reports what changed, and this reads only
1682
+ * those node states, one read at a time, with every node state that changed in
1683
+ * the meantime in the next read. Reads keep going after the run ended, until
1684
+ * the builder follows another run.
1685
+ */
1686
+ var RunNodeDetailsLoader = class {
1687
+ runId = null;
1688
+ /** Node state id → the status its details were (or are being) read for. */
1689
+ asked = /* @__PURE__ */ new Map();
1690
+ waiting = /* @__PURE__ */ new Set();
1691
+ attempts = /* @__PURE__ */ new Map();
1692
+ reading = false;
1693
+ options;
1694
+ constructor(options) {
1695
+ this.options = options;
1696
+ }
1697
+ /** Follows `runId` (null: none); forgets everything about the previous run. */
1698
+ follow(runId) {
1699
+ if (this.runId === runId) return;
1700
+ this.runId = runId;
1701
+ this.asked.clear();
1702
+ this.waiting.clear();
1703
+ this.attempts.clear();
1704
+ }
1705
+ /** The run being followed. */
1706
+ get followedRunId() {
1707
+ return this.runId;
1708
+ }
1709
+ /**
1710
+ * Reads the details of the node states whose status changed since their
1711
+ * details were last read. States with no log line (pending) are skipped.
1712
+ */
1713
+ request(runId, nodeStates) {
1714
+ if (runId !== this.runId) return;
1715
+ for (const { id, status } of nodeStates) {
1716
+ if (toRunLogStatus(status) === "pending") continue;
1717
+ if (this.asked.get(id) === status) continue;
1718
+ this.asked.set(id, status);
1719
+ this.attempts.delete(id);
1720
+ this.waiting.add(id);
1721
+ }
1722
+ this.readNext();
1723
+ }
1724
+ readNext() {
1725
+ const runId = this.runId;
1726
+ if (this.reading || !runId || this.waiting.size === 0) return;
1727
+ const ids = [...this.waiting].slice(0, 500);
1728
+ for (const id of ids) this.waiting.delete(id);
1729
+ this.reading = true;
1730
+ this.options.read(runId, ids).then((details) => {
1731
+ if (this.runId !== runId) return;
1732
+ for (const detail of details) this.asked.set(detail.id, detail.status);
1733
+ this.options.apply(runId, details);
1734
+ }).catch((error) => {
1735
+ this.options.onError?.(error);
1736
+ if (this.runId === runId) this.retryLater(runId, ids);
1737
+ }).finally(() => {
1738
+ this.reading = false;
1739
+ if (this.runId === runId) this.readNext();
1740
+ });
1741
+ }
1742
+ retryLater(runId, ids) {
1743
+ const retry = ids.filter((id) => {
1744
+ const attempts = (this.attempts.get(id) ?? 0) + 1;
1745
+ this.attempts.set(id, attempts);
1746
+ return attempts < MAX_DETAIL_ATTEMPTS;
1747
+ });
1748
+ if (retry.length === 0) return;
1749
+ (this.options.schedule ?? ((callback, ms) => {
1750
+ setTimeout(callback, ms);
1751
+ }))(() => {
1752
+ if (this.runId !== runId) return;
1753
+ for (const id of retry) this.waiting.add(id);
1754
+ this.readNext();
1755
+ }, DETAIL_RETRY_MS);
1756
+ }
1757
+ };
1758
+
1610
1759
  // src/hooks/useNodeExecution.ts
1611
1760
  const TRIGGER_WORKFLOW = TriggerWorkflowDocument;
1612
1761
  const EXECUTE_STEP = ExecuteStepDocument;
1613
- const WORKFLOW_RUN = WorkflowRunDocument;
1614
1762
  const RUN_FROM_NODE = RunFromNodeDocument;
1615
1763
  const EXECUTION_DETAIL = ExecutionDetailDocument;
1616
1764
  /** Terminal run statuses that stop polling */
@@ -1620,8 +1768,12 @@ const TERMINAL_STATUSES = /* @__PURE__ */ new Set([
1620
1768
  "CANCELLED",
1621
1769
  "TERMINATED"
1622
1770
  ]);
1623
- /** Polling interval in ms */
1624
- const POLL_INTERVAL = 1500;
1771
+ /**
1772
+ * Starting a run and following it are requests the person is waiting on: they
1773
+ * go out at once on their own HTTP request instead of joining a batching
1774
+ * host's queue (100 ms, 600 ms while the page loads; fe-libs BOFF-10389).
1775
+ */
1776
+ const SEND_UNBATCHED$1 = { sendUnbatched: true };
1625
1777
  /**
1626
1778
  * How long to wait for the run record to appear in the DB after triggering.
1627
1779
  * Only used in the `if (!run)` path — active runs poll indefinitely until
@@ -1669,10 +1821,53 @@ function useNodeExecution() {
1669
1821
  const addLog = useFlowStore((s) => s.actions.execution.addLog);
1670
1822
  const updateLog = useFlowStore((s) => s.actions.execution.updateLog);
1671
1823
  const setNodeStatus = useFlowStore((s) => s.actions.execution.setNodeStatus);
1672
- const setNodeItemCount = useFlowStore((s) => s.actions.execution.setNodeItemCount);
1673
1824
  const completeExecution = useFlowStore((s) => s.actions.execution.completeExecution);
1674
1825
  const clearLogs = useFlowStore((s) => s.actions.execution.clearLogs);
1675
1826
  const loadDebugRun = useFlowStore((s) => s.actions.execution.loadDebugRun);
1827
+ /** Node id → the node state whose status and details the builder shows. */
1828
+ const shownNodeStatesRef = useRef(/* @__PURE__ */ new Map());
1829
+ /**
1830
+ * Puts a details read's inputs and outputs on the run's log lines. Item
1831
+ * counts on the canvas come from a completed node's output.
1832
+ */
1833
+ const applyNodeDetails = useCallback((runId, details) => {
1834
+ const { execution, actions } = useFlowStore.getState();
1835
+ if (execution.currentRunId !== runId) return;
1836
+ const logsById = new Map(execution.logs.map((log) => [log.id, log]));
1837
+ for (const detail of details) {
1838
+ if (shownNodeStatesRef.current.get(detail.nodeId) !== detail.id) continue;
1839
+ const logId = `${runId}-${detail.nodeId}`;
1840
+ const log = logsById.get(logId);
1841
+ if (!log) continue;
1842
+ actions.execution.updateLog(logId, {
1843
+ inputArgs: detail.inputArgs ?? log.inputArgs,
1844
+ output: detail.output ?? log.output,
1845
+ error: detail.error ?? log.error
1846
+ });
1847
+ if (toRunLogStatus(detail.status) === "completed" && detail.output) actions.execution.setNodeItemCount(detail.nodeId, calculateItemCount(detail.output));
1848
+ }
1849
+ }, []);
1850
+ const detailsLoaderRef = useRef(null);
1851
+ const detailsLoader = useCallback(() => {
1852
+ detailsLoaderRef.current ??= new RunNodeDetailsLoader({
1853
+ read: async (runId, ids) => {
1854
+ return throwIfResultError(await getFluidGridsClient().query({
1855
+ query: BuilderRunNodeDetailsDocument,
1856
+ variables: {
1857
+ runId,
1858
+ ids: [...ids]
1859
+ },
1860
+ fetchPolicy: "no-cache",
1861
+ context: SEND_UNBATCHED$1
1862
+ })).data?.nodeStates ?? [];
1863
+ },
1864
+ apply: applyNodeDetails,
1865
+ onError: (error) => {
1866
+ console.error("[useNodeExecution] Node details read failed:", error);
1867
+ }
1868
+ });
1869
+ return detailsLoaderRef.current;
1870
+ }, [applyNodeDetails]);
1676
1871
  /**
1677
1872
  * Stop any active polling
1678
1873
  */
@@ -1708,23 +1903,21 @@ function useNodeExecution() {
1708
1903
  return data?.operation_name || data?.name || node.type || `Node ${nodeId}`;
1709
1904
  }, [workflow.nodes]);
1710
1905
  /**
1711
- * Process node states from a polled WorkflowRun response.
1712
- * Creates new logs or updates existing ones, and sets visual node status.
1906
+ * Process node states from a status poll: create or update the log lines
1907
+ * and the canvas status of each node, then read the inputs and outputs of
1908
+ * the node states that changed.
1713
1909
  */
1714
1910
  const processNodeStates = useCallback((runId, nodeStates) => {
1715
- for (const nodeState of nodeStates) {
1911
+ const latest = latestNodeStates(nodeStates);
1912
+ shownNodeStatesRef.current = new Map(latest.map((nodeState) => [nodeState.nodeId, nodeState.id]));
1913
+ const { execution } = useFlowStore.getState();
1914
+ const logsById = new Map(execution.logs.map((log) => [log.id, log]));
1915
+ for (const nodeState of latest) {
1716
1916
  const logId = `${runId}-${nodeState.nodeId}`;
1717
- const rawStatus = nodeState.status.toLowerCase();
1718
- const status = rawStatus === "completed" ? "completed" : rawStatus === "failed" || rawStatus === "timeout" ? "failed" : rawStatus === "running" || rawStatus === "waiting" || rawStatus === "delayed" || rawStatus === "waiting_subworkflow" ? "running" : "pending";
1719
- if (status === "completed") {
1720
- setNodeStatus(nodeState.nodeId, "success");
1721
- if (nodeState.output) {
1722
- const itemCount = calculateItemCount(nodeState.output);
1723
- setNodeItemCount(nodeState.nodeId, itemCount);
1724
- }
1725
- } else if (status === "failed") setNodeStatus(nodeState.nodeId, "error");
1726
- else if (status === "running") setNodeStatus(nodeState.nodeId, "running");
1727
- const existingLog = useFlowStore.getState().execution.logs.find((l) => l.id === logId);
1917
+ const status = toRunLogStatus(nodeState.status);
1918
+ const canvasStatus = status === "completed" ? "success" : status === "failed" ? "error" : status === "running" ? "running" : null;
1919
+ if (canvasStatus && execution.nodeStatuses[nodeState.nodeId] !== canvasStatus) setNodeStatus(nodeState.nodeId, canvasStatus);
1920
+ const existingLog = logsById.get(logId);
1728
1921
  if (!existingLog) {
1729
1922
  if (status === "pending") continue;
1730
1923
  const newLog = {
@@ -1734,8 +1927,8 @@ function useNodeExecution() {
1734
1927
  nodeType: nodeState.nodeType,
1735
1928
  nodeName: getNodeName(nodeState.nodeId),
1736
1929
  status,
1737
- inputArgs: nodeState.inputArgs ?? null,
1738
- output: nodeState.output ?? null,
1930
+ inputArgs: null,
1931
+ output: null,
1739
1932
  error: nodeState.error ?? null,
1740
1933
  duration: nodeState.duration ?? null,
1741
1934
  startTime: nodeState.startTime ?? (/* @__PURE__ */ new Date()).toISOString(),
@@ -1744,10 +1937,8 @@ function useNodeExecution() {
1744
1937
  reusedFromRunId: nodeState.reusedFromRunId ?? null
1745
1938
  };
1746
1939
  addLog(newLog);
1747
- } else if (existingLog.status !== status || status === "completed" && !existingLog.output) updateLog(logId, {
1940
+ } else if (existingLog.status !== status) updateLog(logId, {
1748
1941
  status,
1749
- inputArgs: nodeState.inputArgs ?? existingLog.inputArgs,
1750
- output: nodeState.output ?? existingLog.output,
1751
1942
  error: nodeState.error ?? existingLog.error,
1752
1943
  duration: nodeState.duration ?? existingLog.duration,
1753
1944
  endTime: nodeState.endTime ?? existingLog.endTime,
@@ -1755,34 +1946,46 @@ function useNodeExecution() {
1755
1946
  reusedFromRunId: nodeState.reusedFromRunId ?? existingLog.reusedFromRunId
1756
1947
  });
1757
1948
  }
1949
+ detailsLoader().request(runId, latest);
1758
1950
  }, [
1759
1951
  setNodeStatus,
1760
- setNodeItemCount,
1761
1952
  addLog,
1762
1953
  updateLog,
1763
- getNodeName
1954
+ getNodeName,
1955
+ detailsLoader
1764
1956
  ]);
1765
1957
  /**
1766
- * Poll the workflow run status and node states.
1767
- * Replaces the broken WebSocket subscriptions with periodic GraphQL queries.
1958
+ * Follow a run: poll its status (`BuilderRunStatus`) from the moment it was
1959
+ * triggered, fast at first and then every 1.5 s, until it ends. Each poll
1960
+ * reaches the server (`no-cache`; fe-libs sends such reads past its response
1961
+ * cache) on its own request.
1768
1962
  */
1769
1963
  const pollRunUpdates = useCallback((runId, analyticsTrigger) => {
1770
1964
  const client = getFluidGridsClient();
1771
1965
  pollStartRef.current = Date.now();
1772
1966
  activeRunIdRef.current = runId;
1967
+ shownNodeStatesRef.current = /* @__PURE__ */ new Map();
1968
+ detailsLoader().follow(runId);
1969
+ let poll = 0;
1970
+ const scheduleNext = (startedAt) => {
1971
+ pollTimerRef.current = setTimeout(doPoll, nextPollDelayMs(poll, startedAt, Date.now()));
1972
+ poll += 1;
1973
+ };
1773
1974
  const doPoll = async () => {
1774
1975
  if (activeRunIdRef.current !== runId) return;
1976
+ const startedAt = Date.now();
1775
1977
  try {
1776
1978
  const result = await client.query({
1777
- query: WORKFLOW_RUN,
1979
+ query: BuilderRunStatusDocument,
1778
1980
  variables: { id: runId },
1779
- fetchPolicy: "network-only"
1981
+ fetchPolicy: "no-cache",
1982
+ context: SEND_UNBATCHED$1
1780
1983
  });
1781
1984
  if (activeRunIdRef.current !== runId) return;
1782
1985
  const run = result.data?.workflowRun;
1783
1986
  if (!run) {
1784
1987
  console.warn("[useNodeExecution] Poll returned no run data for", runId);
1785
- if (Date.now() - pollStartRef.current < MAX_RUN_CREATION_WAIT) pollTimerRef.current = setTimeout(doPoll, POLL_INTERVAL);
1988
+ if (Date.now() - pollStartRef.current < MAX_RUN_CREATION_WAIT) scheduleNext(startedAt);
1786
1989
  else {
1787
1990
  console.warn("[useNodeExecution] Run data not found after timeout for", runId);
1788
1991
  completeExecution();
@@ -1814,21 +2017,22 @@ function useNodeExecution() {
1814
2017
  cleanup();
1815
2018
  return;
1816
2019
  }
1817
- pollTimerRef.current = setTimeout(doPoll, POLL_INTERVAL);
2020
+ scheduleNext(startedAt);
1818
2021
  } catch (error) {
1819
2022
  console.error("[useNodeExecution] Poll error:", error);
1820
2023
  if (activeRunIdRef.current !== runId) return;
1821
- pollTimerRef.current = setTimeout(doPoll, POLL_INTERVAL * 2);
2024
+ pollTimerRef.current = setTimeout(doPoll, RUN_POLL_RETRY_MS);
1822
2025
  }
1823
2026
  };
1824
- pollTimerRef.current = setTimeout(doPoll, 800);
2027
+ pollTimerRef.current = setTimeout(doPoll, 0);
1825
2028
  }, [
1826
2029
  processNodeStates,
1827
2030
  completeExecution,
1828
2031
  cleanup,
1829
2032
  setRunMetadata,
1830
2033
  bus,
1831
- workspaceId
2034
+ workspaceId,
2035
+ detailsLoader
1832
2036
  ]);
1833
2037
  /**
1834
2038
  * Execute exactly one node as a TEST run. The service derives a safe plan
@@ -1853,6 +2057,7 @@ function useNodeExecution() {
1853
2057
  const client = getFluidGridsClient();
1854
2058
  const stepResult = throwIfResultError(await client.mutate({
1855
2059
  mutation: EXECUTE_STEP,
2060
+ context: SEND_UNBATCHED$1,
1856
2061
  variables: { input: {
1857
2062
  workflowKey,
1858
2063
  version,
@@ -1967,6 +2172,7 @@ function useNodeExecution() {
1967
2172
  const client = getFluidGridsClient();
1968
2173
  const triggerResult = throwIfResultError(await client.mutate({
1969
2174
  mutation: TRIGGER_WORKFLOW,
2175
+ context: SEND_UNBATCHED$1,
1970
2176
  variables: { input: {
1971
2177
  workflowKey,
1972
2178
  version,
@@ -2103,6 +2309,7 @@ function useNodeExecution() {
2103
2309
  const client = getFluidGridsClient();
2104
2310
  const runFromNodeResult = throwIfResultError(await client.mutate({
2105
2311
  mutation: RUN_FROM_NODE,
2312
+ context: SEND_UNBATCHED$1,
2106
2313
  variables: { input: {
2107
2314
  sourceRunId,
2108
2315
  nodeId,
@@ -2206,8 +2413,7 @@ function useNodeExecution() {
2206
2413
  error: "The selected run belongs to a different workflow version."
2207
2414
  };
2208
2415
  const logs = (run.nodeStates ?? []).map((nodeState) => {
2209
- const rawStatus = nodeState.status.toLowerCase();
2210
- const status = rawStatus === "completed" ? "completed" : rawStatus === "failed" || rawStatus === "timeout" ? "failed" : rawStatus === "running" || rawStatus === "waiting" || rawStatus === "delayed" || rawStatus === "waiting_subworkflow" ? "running" : "pending";
2416
+ const status = toRunLogStatus(nodeState.status);
2211
2417
  return {
2212
2418
  id: `${runId}-${nodeState.nodeId}`,
2213
2419
  runId,
@@ -2250,6 +2456,7 @@ function useNodeExecution() {
2250
2456
  return () => {
2251
2457
  if (pollTimerRef.current) completeExecution();
2252
2458
  cleanup();
2459
+ detailsLoaderRef.current?.follow(null);
2253
2460
  };
2254
2461
  }, [cleanup, completeExecution]);
2255
2462
  return {
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { t as __exportAll } from "./rolldown-runtime-hDbaFkMy.js";
3
- import { d as useRestoreWorkflowVersion, h as useWorkflowDefinitions } from "./useWorkflows-D1-rYzGK.js";
4
- import { i as versionsOfWorkflow, t as VersionDiffDialog } from "./VersionDiffDialog-DSN0mU0f.js";
3
+ import { d as useRestoreWorkflowVersion, h as useWorkflowDefinitions } from "./useWorkflows-D9BlhpWH.js";
4
+ import { i as versionsOfWorkflow, t as VersionDiffDialog } from "./VersionDiffDialog-B00qeGiE.js";
5
5
  import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
6
6
  import { x as getFluidGridsConfig } from "./client-C9XSzSXr.js";
7
7
  import { n as useFluidGridsPageControls } from "./pageControlsBridge-0pX9s-3k.js";