Skip to content

Prevent duplicate refresh starts after an unknown POST outcome - #552

Merged
bttfw merged 2 commits into
krinkuto11:devfrom
bttfw:codex/fix-uncertain-refresh-551-20261116
Nov 15, 2026
Merged

bttfw merged 2 commits into
krinkuto11:devfrom
bttfw:codex/fix-uncertain-refresh-551-20261116

Conversation

@bttfw

@bttfw bttfw commented Nov 15, 2026 •

Copy link
Copy Markdown
Collaborator

When Dispatcharr may have accepted a playlist refresh but its HTTP response is lost, the next scheduler pass can send the same start again. Persist an atomic start intent before the POST and retain protection after ambiguous outcomes, including across restarts and concurrent callers. Bulk refreshes use the same per-account admission path and keep their originally captured Dispatcharr target throughout the operation.

Unresolved starts appear under Settings → Scheduling → Playlist refresh protection. After checking in Dispatcharr that both live and VOD work have finished or stopped, an operator can allow future starts. Recovery validates the current account status and exact attempt; it does not itself start a refresh. Dispatcharr 0.33's live success status cannot establish completion of its separately queued VOD work, so uncertainty does not expire automatically. The existing 30-second HTTP timeout is unchanged.

Validation on final head 969de4f1:

  • All six PR checks passed: 2,452 stable backend tests and 84 integration contracts, each with one existing skip; 334 frontend tests and production build; Python/JavaScript CodeQL and dependency audits.
  • Native Unraid DockerMan installations with isolated Dispatcharr data reproduced two POSTs while the first import was active on the previous image, using a delayed reply and a deliberately stale account snapshot. The final candidate sends one POST across two scheduler passes and retains protection after a real container restart. Direct single-account and bulk calls cannot bypass it.
  • The actual Settings UI disables resolution while busy, requires confirmation after completion, and resolves without starting a refresh. Two subsequent regular intervals complete successfully. No browser errors; installed backend files match the candidate and template configuration is preserved across updates.

Refs #551. This fixes the StreamFlow replay path; the reporter's VOD deletion and the cause of the delayed acknowledgement have not been independently reproduced.

@bttfw
bttfw marked this pull request as ready for review November 15, 2026 11:22
@bttfw
bttfw merged commit bae6163 into krinkuto11:dev Nov 15, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant