Skip to content

Retry transient episode errors during YouTube sync - #24

Merged
meoyawn merged 3 commits into
masterfrom
codex/retry-sync-network-errors
Sep 30, 2026
Merged

meoyawn merged 3 commits into
masterfrom
codex/retry-sync-network-errors

Conversation

@meoyawn

@meoyawn meoyawn commented Sep 30, 2026 •

Copy link
Copy Markdown
Member

Transient DNS, connection, timeout, and interrupted HTTP body errors now retry the individual episode up to four times after its initial attempt. The sync engine owns exactly two episode error categories: Retryable and Skip. Non-retryable errors and exhausted retries skip the episode for this run, retaining its reason under Not imported while successful siblings continue.

Retries reuse the existing upload journal, operation identity, prepared media, completed ranges, and uploaded parts. Stop interrupts the retry wait and leaves unfinished work queued; playlist, inventory, and durable outcome errors still stop the whole run. The embedded JavaScript fetch bridge preserves generic error metadata, while classification stays in sync-engine.

Parent repository pin, fixtures, and integrated coverage: https://github.com/listenbox/listenbox2/pull/105

Validation: the three transport regressions fail on the parent baseline and pass with this change, each under one second. They prove DNS, embedded JavaScript transport, and interrupted completion-body errors enter the retry state; Stop leaves work queued; explicit process restart preserves prepared uploads and reconciles publication without duplicates. Existing integrated tests cover skipped reasons, sibling publication, partial upload resumption, and source-scan deletion safeguards. Client and API Moon lints passed; autoreview reported no blocking findings at its default P0 scope.

Applied test-audit: removed two automatic retry-loop scenarios and the accelerated clock. Tests stop after one failed attempt and explicitly restart, following repository testing policy. Audit changes removed 53 net test lines and changed no production code.

Full verification: root moon ci passed on the final rebased commits: 49 actions completed (35 cached) in 1m 33s, including API and dashboard integrated suites.

@meoyawn
meoyawn force-pushed the codex/retry-sync-network-errors branch from 6d0ab3c to 97f517c Compare September 30, 2026 21:01
@meoyawn
meoyawn merged commit 3bbc05e into master Sep 30, 2026
4 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