Commit graph

3018 commits

Author SHA1 Message Date
SergeantPanda
e82ec87fc3 Merge branch 'dev' of https://github.com/Dispatcharr/Dispatcharr into dev
Some checks failed
CI Pipeline / prepare (push) Has been cancelled
Build and Push Multi-Arch Docker Image / build-and-push (push) Has been cancelled
Frontend Tests / test (push) Has been cancelled
CI Pipeline / docker (amd64, ubuntu-24.04) (push) Has been cancelled
CI Pipeline / docker (arm64, ubuntu-24.04-arm) (push) Has been cancelled
CI Pipeline / create-manifest (push) Has been cancelled
2026-03-15 21:08:38 -05:00
SergeantPanda
6638ba4b77 changelog: Update changelog for proxy pr. 2026-03-15 21:08:31 -05:00
SergeantPanda
946f636837
Merge pull request #1105 from cmcpherson274/patch-1
Fix: audio loss during stream failover and ghost client accumulation
2026-03-15 21:04:16 -05:00
SergeantPanda
d4e52f70db Merge branch 'dev' into pr/cmcpherson274/1105 2026-03-15 21:02:52 -05:00
SergeantPanda
92f98a24c7 fix: increase ghost client multiplier to improve client detection timing 2026-03-15 20:45:55 -05:00
SergeantPanda
7e07c9552d changelog: Update changelog for ghost client pr. 2026-03-15 20:13:42 -05:00
SergeantPanda
cd0eba9654
Merge pull request #1098 from CodeBormen/fix/ghost-streams-stuck-initializing
fix: stuck channel states and ghost clients in TS proxy
2026-03-15 20:07:44 -05:00
None
55f0a49d68 fix: improve test coverage and add missing metadata constants
- Rewrite ghost client tests to call real ChannelStatus and ClientManager code paths instead of reimplementing detection logic in test helpers
- Rewrite initializing state tests to invoke StreamManager.run() so the real finally block executes under test
- Replace hardcoded state list tests with assertions against ChannelState.PRE_ACTIVE frozenset
- Add missing SOURCE_BITRATE and FFMPEG_BITRATE constants to ChannelMetadataField (referenced by channel_status.py but never defined, causing AttributeError on detailed stats)
2026-03-15 19:39:15 -05:00
SergeantPanda
2d2b3e45f4 fix: harden ghost client cleanup and PRE_ACTIVE state guard
- Change ChannelState.PRE_ACTIVE from list to frozenset (immutable,
  O(1) membership tests, no risk of silent mutation)

- Add optional client_ids parameter to ClientManager.remove_ghost_clients()
  so callers that have already fetched SMEMBERS can pass it through,
  eliminating a redundant Redis round-trip

- Pass pre-fetched client_ids from get_basic_channel_info() into
  remove_ghost_clients() to remove the duplicate SMEMBERS call
2026-03-15 19:08:38 -05:00
SergeantPanda
159c2d0de7 Merge branch 'dev' of https://github.com/Dispatcharr/Dispatcharr into dev 2026-03-15 17:46:44 -05:00
SergeantPanda
d84580710b changelog: Update changelog for uWSGI config PR. 2026-03-15 17:46:37 -05:00
SergeantPanda
cc5a0eb7f7
Merge pull request #929 from jcasimir/fix/uwsgi-gevent-segfault-clean
Fix uWSGI segfaults by disabling threads when using gevent
2026-03-15 17:45:24 -05:00
SergeantPanda
41ce381130 changelog: Update changelog for tests PR. 2026-03-15 17:28:00 -05:00
SergeantPanda
28b9de94dc Merge branch 'dev' of https://github.com/Dispatcharr/Dispatcharr into dev 2026-03-15 17:00:00 -05:00
SergeantPanda
c44a3ad5f9 Bug Fix: Stream.last_seen and ChannelGroupM3UAccount.last_seen model defaults now use django.utils.timezone.now instead of datetime.datetime.now, eliminating spurious RuntimeWarning: DateTimeField received a naive datetime warnings emitted during test database creation and on new record creation when USE_TZ=True. 2026-03-15 16:59:51 -05:00
SergeantPanda
c4a8e01fb4
Merge pull request #1108 from nick4810/tests/frontend-unit-tests
Tests/frontend unit tests
2026-03-15 16:54:02 -05:00
SergeantPanda
e0ed2296b2
Merge pull request #1096 from Dispatcharr/xc-account-expiration-management
Some checks are pending
CI Pipeline / prepare (push) Waiting to run
CI Pipeline / docker (amd64, ubuntu-24.04) (push) Blocked by required conditions
CI Pipeline / docker (arm64, ubuntu-24.04-arm) (push) Blocked by required conditions
CI Pipeline / create-manifest (push) Blocked by required conditions
Build and Push Multi-Arch Docker Image / build-and-push (push) Waiting to run
Frontend Tests / test (push) Waiting to run
Enhancement: Account expiration tracking and notifications for M3U profiles
2026-03-15 16:42:33 -05:00
SergeantPanda
0815b3df14 tests: Add backend test for expiration feature. 2026-03-15 16:42:11 -05:00
Nick Sandstrom
e421c007cc Conforming to style guide 2026-03-15 14:05:54 -07:00
Nick Sandstrom
e95285ec8c Added forms/settings tests 2026-03-15 14:05:54 -07:00
SergeantPanda
bd11b0e832 Change notification for account expiry to admin only. 2026-03-15 16:03:41 -05:00
SergeantPanda
09d5f6bb9f Update expiration date handling in M3U components to ensure UTC format 2026-03-15 16:00:23 -05:00
cmcpherson274
d34e05bc5f
Merge pull request #1 from CodeBormen/fix/1105-keepalive-timeout-cap
fix: cap keepalive mode duration to prevent indefinite client hold
2026-03-15 16:16:01 -04:00
None
40d0bc9567 fix: cap keepalive mode duration to prevent indefinite client hold
- Add MAX_KEEPALIVE_DURATION = 300s to TSConfig
- Track keepalive_start_time in _stream_data_generator; disconnect after cap is exceeded with a warning log
- Reset timer on real data so independent stalls don't accumulate
- Fix pre-existing test helper missing throttle attributes in NonOwnerWorkerKeepaliveTests
2026-03-15 14:22:57 -05:00
cmcpherson274
c8b665dc98
Update last_active timestamp in keepalive logic
Update last active timestamp for clients during failover.
2026-03-15 14:08:43 -04:00
cmcpherson274
10ea165c2c
Refactor packet handling with locking mechanism 2026-03-15 14:04:59 -04:00
SergeantPanda
1d4603dadd Enhancement: Optimize profile expiration handling and update task naming for clarity 2026-03-15 12:42:34 -05:00
cmcpherson274
f7085e5dc2
Add 'last_active' field to stats in stream_generator 2026-03-15 12:10:38 -04:00
cmcpherson274
fd9ca28316
Modify client TTL handling in client_manager.py
Updated client manager to refresh TTL without updating last_active timestamp.
2026-03-15 12:08:32 -04:00
cmcpherson274
cf1aef6747
Implement buffer reset method for stream transitions
Added a method to reset internal buffers to prevent corruption during stream transitions.
2026-03-15 12:06:32 -04:00
None
c65ace1a7c fix: stuck channel states and ghost clients in TS proxy
- Write ERROR via ownership check OR state guard fallback when ownership TTL expired during retries
- Add INITIALIZING to cleanup task grace period monitoring
- Validate client SET entries against metadata hashes in orphaned channel cleanup; remove ghosts and clean up when no real clients remain
- Stats page self-heals by removing ghost SET entries on read
- Extract remove_ghost_clients() helper to ClientManager
- Add ChannelState.PRE_ACTIVE constant
- Fix 6 pre-existing NonOwnerWorkerKeepalive test failures
2026-03-14 19:24:01 -05:00
SergeantPanda
b22f9e8e07 Enhancement: Account expiration tracking and notifications for M3U profiles 2026-03-14 18:38:59 -05:00
SergeantPanda
5b9b0162da Merge branch 'main' of https://github.com/Dispatcharr/Dispatcharr into dev
Some checks failed
CI Pipeline / prepare (push) Waiting to run
CI Pipeline / docker (amd64, ubuntu-24.04) (push) Blocked by required conditions
CI Pipeline / docker (arm64, ubuntu-24.04-arm) (push) Blocked by required conditions
CI Pipeline / create-manifest (push) Blocked by required conditions
Build and Push Multi-Arch Docker Image / build-and-push (push) Waiting to run
Frontend Tests / test (push) Waiting to run
Base Image Build / prepare (push) Has been cancelled
Base Image Build / docker (amd64, ubuntu-24.04) (push) Has been cancelled
Base Image Build / docker (arm64, ubuntu-24.04-arm) (push) Has been cancelled
Base Image Build / create-manifest (push) Has been cancelled
2026-03-14 13:10:08 -05:00
SergeantPanda
c33a7b72f8 Security: Update Django and django celery beat. Also update license in pyproject.toml
Some checks failed
Build and Push Multi-Arch Docker Image / build-and-push (push) Waiting to run
Base Image Build / prepare (push) Has been cancelled
Base Image Build / docker (amd64, ubuntu-24.04) (push) Has been cancelled
Base Image Build / docker (arm64, ubuntu-24.04-arm) (push) Has been cancelled
Base Image Build / create-manifest (push) Has been cancelled
2026-03-14 13:09:39 -05:00
SergeantPanda
9ac113cd88 Update license in pyproject.toml 2026-03-14 13:03:40 -05:00
SergeantPanda
7b60a958a5 Security: Update dependencies for Django and django-celery-beat to address security vulnerabilities 2026-03-14 12:57:07 -05:00
SergeantPanda
2b8ebc7882 Security: Updated flatted to 3.4.1, resolving **high** unbounded recursion DoS in the parse() revive phase 2026-03-14 12:32:38 -05:00
SergeantPanda
f30e044689 Enhancement: When selecting an EPG source for a channel, the EPG source dropdown now only lists enabled (active) EPGs, sorted alphabetically.
Some checks are pending
CI Pipeline / prepare (push) Waiting to run
CI Pipeline / docker (amd64, ubuntu-24.04) (push) Blocked by required conditions
CI Pipeline / docker (arm64, ubuntu-24.04-arm) (push) Blocked by required conditions
CI Pipeline / create-manifest (push) Blocked by required conditions
Build and Push Multi-Arch Docker Image / build-and-push (push) Waiting to run
Frontend Tests / test (push) Waiting to run
2026-03-13 17:21:31 -05:00
SergeantPanda
12e7d6219d Enhancement: Add icon to programdetailmodal for custom dummy epgs. 2026-03-13 17:12:32 -05:00
SergeantPanda
4dffe36d63 Changelog: Add change for guide PR 2026-03-13 16:52:43 -05:00
SergeantPanda
216dd7fc40
Merge pull request #1072 from CodeBormen/feat/1065-Add-Subtitle-and-Season-Episode-to-Guide
feat: Add subtitle and season/episode to TV Guide (#1065)
2026-03-13 16:48:20 -05:00
SergeantPanda
a0cea5abb4 Remove vite deps and add to gitignore. 2026-03-13 16:45:46 -05:00
SergeantPanda
115e0de55b Remove shadow filter from logo. 2026-03-13 16:13:28 -05:00
SergeantPanda
284aafcf5e Bug Fix: EPG programme parsing crash when an XMLTV source contains programme titles exceeding 255 characters. Previously, a single oversized title would cause the entire bulk_create batch to fail with a database truncation error, silently dropping all programmes in that batch. Titles are now truncated to 255 characters before being saved. (Fixes #1039)
Some checks are pending
CI Pipeline / prepare (push) Waiting to run
CI Pipeline / docker (amd64, ubuntu-24.04) (push) Blocked by required conditions
CI Pipeline / docker (arm64, ubuntu-24.04-arm) (push) Blocked by required conditions
CI Pipeline / create-manifest (push) Blocked by required conditions
Build and Push Multi-Arch Docker Image / build-and-push (push) Waiting to run
2026-03-13 15:35:43 -05:00
SergeantPanda
03e1061716 Bug Fix: Fix postgres lock file permissions before starting and upgrading Postgres. 2026-03-13 14:59:46 -05:00
SergeantPanda
1f50217dbe perf(epg): speed up TV guide grid load 2k channels from 18s to ~8s
Replace DRF ModelSerializer with .values() + plain dict construction in
EPGGridAPIView, eliminating per-row serializer instantiation, field
object creation, and OrderedDict overhead across ~12k programs.

Pre-compute season/episode at import time instead of on every API request:
- Extract S/E from onscreen episode-num inline in extract_custom_properties()
  immediately after storing the raw value, rather than in a separate pass
- Add missing description-based S/E fallback to parse_programs_for_tvg_id(),
  bringing it in line with parse_programs_for_source()

Remove runtime extract_season_episode() call from ProgramDataSerializer and
EPGGridAPIView — values are now guaranteed to be in custom_properties after
import, so season/episode resolution is a plain dict lookup at request time.

Also remove unnecessary select_related("epg") JOIN and .count() query from
the grid endpoint.
2026-03-13 12:16:10 -05:00
SergeantPanda
850692cc30 changelog: Add thanks to to changelog for startup pr. 2026-03-13 10:28:03 -05:00
SergeantPanda
d8ca703862
Merge pull request #1091 from CodeBormen:fix/1078-puid-pgid-postgres-conflict
fix: Run PostgreSQL as PUID/PGID user to resolve container startup failures
2026-03-13 10:23:23 -05:00
None
93032a6c18 Correct tests to reflect recent changes 2026-03-12 21:42:32 -05:00
None
fc01a6d04d Improve ProgramDetailModal layout per feedback
- Move channel name/number into modal header title bar (was empty after removing duplicate title)
- Remove channel logo from modal (didn't fit well)
- Remove custom background color override, inherit from Mantine dark theme for consistency with VOD/Series modals
- Fix wrong channel shown in modal: pass channel directly from renderProgram instead of re-looking up by tvg_id
- Clean up unused imports (getChannelLogoUrl, Image/Group no longer needed in title)
2026-03-12 21:33:58 -05:00