[Bug]: A short (non-empty) provider response still deletes auto-synced channels
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 57/100
Research direction
Start in apps/m3u/tasks.py around lines 3914–3938 and trace how the refresh counts parsed streams before stale marking, cleanup_streams, and sync_auto_channels. Check how Redis stores the last accepted count and how refresh failures are handled. Reproduce with a short provider response, then verify that responses below the stated threshold skip destructive sync work and accepted responses update the stored count.
Written by the indexing model from the issue text.
Description
Describe the bug
#1378 stops an empty provider response from wiping channels. A short but non-empty one still does.
- Problem: a response with ~440 streams where ~39,000 is normal parses cleanly and still runs stale marking,
cleanup_streamsandsync_auto_channels(apps/m3u/tasks.py:3914-3938, v0.32.0). Auto-synced channels and their EPG links are deleted, then recreated when the full list comes back. - Fix: before line 3914, compare streams seen with the last count that passed (kept in Redis). At 0 or under 80%, log an error and skip stale marking, cleanup and auto sync for that run; otherwise store the new count. If the check itself errors, skip.
- Proven: 205 refreshes skipped over ten weeks, each a real partial response from the provider, with no channels lost.
How can we recreate this bug?
- Reproduce: Auto Channel Sync on, serve the account ~1% of its streams for one refresh (mock or proxy), and the synced channels are gone.
Dispatcharr Version
v0.32.0
Docker Version
29.2.1
What's in your Docker Compose file?
Stock docker/docker-compose.aio.yml
Client Information
TiviMate (Android) over XC
- Dominant language
- Python
- Stars
- 4.2k
- Forks
- 324
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 29
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Dispatcharr/Dispatcharr
-
Area: Frontend Available In Dev P2 S
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
Dispatcharr/Dispatcharr#1954 · 2 comments ·
Maintainers usually reply within 1 day
-
Area: Backend Area: M3U Available In Dev P3 S
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
Dispatcharr/Dispatcharr#1872 · 9 comments ·
Maintainers usually reply within 1 day
-
[Bug]: Logo URLs with a double slash in the path fail to loadPossibly taken A pull request linked to this issue is open or already merged. OpenArea: Logos Area: M3U Area: Xtream Codes P3 S
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Dispatcharr/Dispatcharr#1863 · 2 comments ·
Maintainers usually reply within 1 day
-
Area: Frontend Area: M3U P4 S
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Dispatcharr/Dispatcharr#1861 · 2 comments ·
Maintainers usually reply within 1 day
-
Area: Backend Area: M3U Area: Streams M P3
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Dispatcharr/Dispatcharr#1786 · 1 comment ·
Maintainers usually reply within 1 day
All issues in Dispatcharr/Dispatcharr
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
Maintainers usually reply within 1 day
-
comp/desktop P3 type/feature
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
NousResearch/hermes-agent#154285 ·
Maintainers usually reply within 1 day
-
docs: qualify copied and custom kubectl debug policy notesPossibly taken @nym01 claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
kubescape/cel-admission-library#166 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
SACGF/variantgrid#2804 · 1 comment ·
Maintainers usually reply within 1 day
-
[BUG] HTTP lifecycle dispatch treats a NO_PROXY-only environment as corporate egress and skips the resolve-and-pinned sessionPossibly taken @bodapatisaikrishna claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day