Skip to content

No loader on Workflows > User Metadata tab while summary/details decode #4208

Open

Description

@ShilpThapak

Problem

Opening Workflows > <workflow> > User Metadata shows no loading indicator while summary/details are being decoded (codec server round-trip via decodePayloadAndParseDataToJSON), and the Current Details panel (backed by the __temporal_workflow_metadata query, e.g. /api/v1/namespaces/<ns>/workflows/<id>/query/__temporal_workflow_metadata) renders blank while the query is in flight — no spinner, no skeleton, nothing.

Root cause:

  1. src/lib/layouts/workflow-run-layout.svelte awaits decodeWorkflowUserMetadata() before setting $workflowRun.workflow, so a slow codec server blocks the entire workflow page behind the generic skeleton.
  2. Even once rendered, src/lib/stores/workflow-run.ts initialises userMetadata as { summary: '', details: '' }, so the store cannot distinguish "loading" from "loaded empty" — src/lib/components/user-metadata.svelte ({#if summary} … {:else} No Summary Available) can render the empty state during decoding.
  3. The User Metadata page has no loading flag, no <Loading />, no {#await} pending block — unlike e.g. src/lib/pages/batch-operations.svelte ({#await listBatchOperations …} <Loading />). Same for the Current Details panel: its loading flag exists but was never wired into the markup.

Impact — why this matters

On Temporal Cloud this query/decode path is slow, and without a loader it is impossible to tell "still loading" from "no metadata available". So you cannot move on — you keep waiting to see if anything is going to appear. A loader resolves the ambiguity: spinner means wait, the empty state means there is genuinely nothing there and you can move on. The missing loader wastes real triage time on every workflow inspection.

Reproduction (before fix)

Recorded against a mock workflow with sample Current Details data and a simulated slow query: Summary/Details render, but the Current Details panel sits blank until the query resolves. (Before video attached below.)

before-current-details-loading.mp4

Suggested fix

  • Add userMetadataLoading: boolean to WorkflowRunWithWorkers (mirrors existing workersLoaded), initialised to true.
  • Render the workflow immediately and decode user metadata in the background (don't block first render on the codec round-trip), setting the flag false in a finally with a run-identity guard against stale writes after navigation.
  • Render <Loading /> in src/lib/pages/workflow-user-metadata.svelte while userMetadataLoading is true, and in the Current Details panel while its query is pending with nothing to show yet.

Fix proposed in #4209.

Activity

  1. added a commit that references this issue on Nov 23, 2026
    cdffb6f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions