The FedWiki and Discourse operator pages say a scheduled run never happened when Temporal could not be asked #297

Open
opened 2026-10-30 19:47:47 +00:00 by cgalo5758 · 0 comments
Owner

What happens

The FedWiki operator page shows when the integration's scheduled run last ran, and the Discourse operator page shows the same for its membership sweep. Both read it through workflows.ScheduleRunStatus (internal/workflows/schedule_health.go), which asks Temporal, the console's workflow engine, to describe the schedule and then its latest run.

When describing the schedule fails for any reason (a network fault, a timeout, Temporal being down), the function returns an empty status, the same answer it gives for a schedule that has never fired. The FedWiki page then shows its never-ran text and the Discourse page "No sweep has run yet" (internal/integrations/fedwiki/web/operator.go, the ScheduleRunStatus call; internal/integrations/discourse/web/operator.go, sweepHealth). Nothing is logged.

When the schedule answers but describing its latest run fails, the function falls back to "Ran" with the time the schedule fired. That fallback exists for a run whose history Temporal has already deleted, but a run Temporal could not describe for any other reason reads the same.

What should happen

A failed read is logged, and the page says the run's status could not be read. The never-ran text appears only when the schedule answered and has never fired, and "Ran" only when the run's history is gone.

Where

internal/workflows/schedule_health.go (ScheduleRunStatus, describeRun); internal/integrations/fedwiki/web/operator.go; internal/integrations/discourse/web/operator.go (sweepHealth).

Why it matters

During a Temporal fault, an operator who opens either page to find out whether the scheduled work is running is told it has never run, and may act on that, for example by triggering it by hand or by looking for a configuration mistake that is not there.

### What happens The FedWiki operator page shows when the integration's scheduled run last ran, and the Discourse operator page shows the same for its membership sweep. Both read it through `workflows.ScheduleRunStatus` (`internal/workflows/schedule_health.go`), which asks Temporal, the console's workflow engine, to describe the schedule and then its latest run. When describing the schedule fails for any reason (a network fault, a timeout, Temporal being down), the function returns an empty status, the same answer it gives for a schedule that has never fired. The FedWiki page then shows its never-ran text and the Discourse page "No sweep has run yet" (`internal/integrations/fedwiki/web/operator.go`, the `ScheduleRunStatus` call; `internal/integrations/discourse/web/operator.go`, `sweepHealth`). Nothing is logged. When the schedule answers but describing its latest run fails, the function falls back to "Ran" with the time the schedule fired. That fallback exists for a run whose history Temporal has already deleted, but a run Temporal could not describe for any other reason reads the same. ### What should happen A failed read is logged, and the page says the run's status could not be read. The never-ran text appears only when the schedule answered and has never fired, and "Ran" only when the run's history is gone. ### Where `internal/workflows/schedule_health.go` (`ScheduleRunStatus`, `describeRun`); `internal/integrations/fedwiki/web/operator.go`; `internal/integrations/discourse/web/operator.go` (`sweepHealth`). ### Why it matters During a Temporal fault, an operator who opens either page to find out whether the scheduled work is running is told it has never run, and may act on that, for example by triggering it by hand or by looking for a configuration mistake that is not there.
cgalo5758 added the
kind
bug
area/fedwikiarea/discoursearea/operator-ui
labels 2026-10-30 19:47:47 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: wiki-cafe/member-console#297