Repository navigation
FE-1994: Pass whole EntityId around for Flow Runs instead of just the EntityUuid - #10072
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
PR SummaryHigh Risk Overview GraphQL & API: Clients: Frontend context, Apollo cache keys, dashboards/goals/workers UI, and worker routes build the selected run’s Browser plugin: WebSocket and local messages use Reviewed by Cursor Bugbot for commit 7852622. Bugbot is set up for automated code reviews on this repo. Configure here. |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #10072 +/- ##
=======================================
Coverage 68.22% 68.23%
=======================================
Files 1990 1993 +3
Lines 205165 205225 +60
Branches 8699 8713 +14
=======================================
+ Hits 139979 140038 +59
Misses 63520 63520
- Partials 1666 1667 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
🟡 Changes recommended
Workflow-target authorization and compatibility with persisted browser and Temporal inputs remain unresolved.
3 open issues
What changed in this PR
Migrates flow-run identification from UUIDs to full entity IDs across shared libraries, the API, frontend, and browser plugin, enabling web-scoped lookups.
Changes:
- Updates GraphQL contracts, client state, and browser messages.
- Scopes run lookups by web and resolves Temporal targets from stored workflow IDs.
- Updates navigation while retaining UUID-based URL segments.
| File | Description |
|---|---|
| libs/@local/hash-isomorphic-utils/src/graphql/type-defs/knowledge/flow.typedef.ts | Updates GraphQL contracts. |
| libs/@local/hash-isomorphic-utils/src/graphql/queries/flow.queries.ts | Updates shared operations. |
| libs/@local/hash-isomorphic-utils/src/flows/temporal-types.ts | Renames workflow input field. |
| libs/@local/hash-isomorphic-utils/src/flows/frontend-paths.ts | Extracts UUIDs for URLs. |
| libs/@local/hash-isomorphic-utils/src/create-apollo-client.ts | Updates cache identity. |
| libs/@local/hash-isomorphic-utils/src/ai-inference-types.ts | Updates WebSocket contracts. |
| libs/@local/hash-backend-utils/src/flows/shared/get-flow-run-entity-by-id.ts | Adds web-scoped lookup. |
| libs/@local/hash-backend-utils/src/flows/process-flow-workflow/common-activities/persist-flow-activity.ts | Renames persistence input. |
| libs/@local/hash-backend-utils/src/flows/process-flow-workflow.ts | Forwards renamed input. |
| libs/@local/hash-backend-utils/src/flows/get-flow-run-details.ts | Returns full run IDs. |
| libs/@local/hash-backend-utils/src/flows.ts | Threads full run IDs. |
| apps/plugin-browser/src/shared/storage.ts | Updates stored run type. |
| apps/plugin-browser/src/shared/messages.ts | Updates cancellation messages. |
| apps/plugin-browser/src/scripts/background/infer-entities.ts | Updates messages and optimistic IDs. |
| apps/plugin-browser/src/pages/popup/popup-contents/action-center/shared/use-flow-runs.ts | Reconciles by entity ID. |
| apps/plugin-browser/src/pages/popup/popup-contents/action-center/history/shared/history-row/flow-status-cell.tsx | Sends full cancellation ID. |
| apps/plugin-browser/src/pages/popup/popup-contents/action-center/history/shared/history-row/flow-metadata-cell-contents.tsx | Accepts entity IDs for usage. |
| apps/plugin-browser/src/pages/popup/popup-contents/action-center/history/shared/history-row.tsx | Updates history links. |
| apps/plugin-browser/src/pages/popup/popup-contents/action-center/history/manually-triggered.tsx | Updates row keys. |
| apps/plugin-browser/src/pages/popup/popup-contents/action-center/history/automatically-triggered.tsx | Updates row keys. |
| apps/plugin-browser/src/graphql/queries/flow.queries.ts | Requests full run IDs. |
| apps/hash-frontend/src/pages/workers.page/flow-run-table.tsx | Updates links and usage keys. |
| apps/hash-frontend/src/pages/workers.page.tsx | Updates context property. |
| apps/hash-frontend/src/pages/shared/use-flow-runs-usage.ts | Groups usage by entity ID. |
| apps/hash-frontend/src/pages/shared/flow-runs-context.ts | Updates selected-run type. |
| apps/hash-frontend/src/pages/shared/flow-runs-context-provider.tsx | Queries by entity ID. |
| apps/hash-frontend/src/pages/shared/entity/entity-editor/history-section/history-table/provenance.tsx | Passes full provenance run ID. |
| apps/hash-frontend/src/pages/goals/new.page.tsx | Updates post-start navigation. |
| apps/hash-frontend/src/pages/goals.page/goals-list/goal-list-section/goal-row.tsx | Updates goal run links. |
| apps/hash-frontend/src/pages/goals.page/goals-list/goal-list-section.tsx | Updates goal row keys. |
| apps/hash-frontend/src/pages/goals.page/goals-list.tsx | Stores full run IDs. |
| apps/hash-frontend/src/pages/goals.page.tsx | Updates context property. |
| apps/hash-frontend/src/pages/flows.page.tsx | Updates context property. |
| apps/hash-frontend/src/pages/dashboard/hooks/use-dashboard-item-generations.ts | Polls with entity IDs. |
| apps/hash-frontend/src/pages/dashboard/hooks/use-dashboard-item-config.ts | Updates generation state and polling. |
| apps/hash-frontend/src/pages/dashboard/[dashboard-id].page/item-config-modal.tsx | Updates callback contract. |
| apps/hash-frontend/src/pages/dashboard/[dashboard-id].page.tsx | Updates generation callback. |
| apps/hash-frontend/src/pages/@/[shortname]/workers/[run-id].page.tsx | Reconstructs ID from route namespace. |
| apps/hash-frontend/src/pages/@/[shortname]/shared/flow-visualizer/topbar.tsx | Updates selection and cancellation. |
| apps/hash-frontend/src/pages/@/[shortname]/shared/flow-visualizer/shared/question-modal.tsx | Submits full run ID. |
| apps/hash-frontend/src/pages/@/[shortname]/shared/flow-visualizer/outputs/claims-output.tsx | Uses full provenance ID directly. |
| apps/hash-frontend/src/pages/@/[shortname]/shared/flow-visualizer/flow-run-sidebar.tsx | Updates usage lookup. |
| apps/hash-frontend/src/pages/@/[shortname]/shared/flow-visualizer/activity-log.tsx | Updates reset input. |
| apps/hash-frontend/src/pages/@/[shortname]/shared/flow-visualizer.tsx | Updates navigation and run state. |
| apps/hash-frontend/src/pages/@/[shortname]/flows/[flow-def-id].page.tsx | Updates context property. |
| apps/hash-frontend/src/graphql/queries/knowledge/flow.queries.ts | Updates mutation arguments. |
| apps/hash-api/src/graphql/resolvers/flows/submit-external-input-response.ts | Resolves stored workflow target. |
| apps/hash-api/src/graphql/resolvers/flows/start-flow.ts | Returns full entity ID. |
| apps/hash-api/src/graphql/resolvers/flows/reset-flow.ts | Resolves stored reset target. |
| apps/hash-api/src/graphql/resolvers/flows/get-flow-run-by-id.ts | Accepts full entity ID. |
| apps/hash-api/src/graphql/resolvers/flows/cancel-flow.ts | Resolves stored cancellation target. |
| apps/hash-api/src/ai/infer-entities-websocket/handle-infer-entities-request.ts | Sets predictable run UUID. |
| apps/hash-api/src/ai/infer-entities-websocket/handle-cancel-infer-entities-request.ts | Cancels through entity lookup. |
| apps/hash-api/src/ai/infer-entities-websocket.ts | Updates validation and signaling. |
Review effort: Balanced
…d a run's workflow from its entity
…so its workflow id
b3e57ad to
0a96dc3
Compare
kostandinang
left a comment
There was a problem hiding this comment.
Looks good. Left couple of notes, maybe worth checking.
… so for scheduled runs
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 7852622. Configure here.



🌟 Purpose
A flow run was previously identified in various functions by
flowRunId, the uuid of itsFlow Runentity. A uuid alone doesn't say which web a run is in, so finding a run searched every web for an entity with that uuid, and code that needed the run's web had to find the entity first.This PR identifies a run by its full entity id everywhere: the GraphQL API, the backend, the frontend and the browser plugin.
FE-2006 will do the same exercise for Flow Definitions.
🔍 Changes
Entirely function signature update and consequential mechanical changes.