Commit graph

2734 commits

Author SHA1 Message Date
SergeantPanda
9440bbe2ab Performance: Removed unnecessary double wait that was causing fetching of channel data to not run in parallel. 2026-01-25 20:56:41 -06:00
SergeantPanda
596d4adb5b
Merge pull request #891 from Dispatcharr/Data-Loading-Refactor
Data loading and initialization refactor: Major performance improveme…
2026-01-25 19:48:38 -06:00
SergeantPanda
e22e003be9 Data loading and initialization refactor: Major performance improvement reducing initial page load time by eliminating duplicate API requests caused by race conditions between authentication flow and route rendering:
- Fixed authentication race condition where `isAuthenticated` was set before data loading completed, causing routes to render and tables to mount prematurely
  - Added `isInitialized` flag to delay route rendering until after all initialization data is loaded via `initData()`
  - Consolidated version and environment settings fetching into centralized settings store with caching to prevent redundant calls
  - Implemented stale fetch prevention in ChannelsTable and StreamsTable using fetch version tracking to ignore outdated responses
  - Fixed filter handling in tables to use `debouncedFilters` consistently, preventing unnecessary refetches
  - Added initialization guards using refs to prevent double-execution of auth and superuser checks during React StrictMode's intentional double-rendering in development
  - Removed duplicate version/environment fetch calls from Sidebar, LoginForm, and SuperuserForm by using centralized store
2026-01-25 19:46:34 -06:00
Matt Grutza
47b591bacb Add configurable POSTGRES_PORT and REDIS_PORT for external databases
Make database ports configurable for users with external PostgreSQL/Redis.

- Add POSTGRES_PORT and REDIS_PORT to docker-compose.yml (web and celery)
- Remove hardcoded CELERY_BROKER_URL (Django builds it from components)
- Add REDIS_PORT export to entrypoint.sh and profile variables
- Add Redis connection check for modular mode (matches PostgreSQL pattern)

Users can now specify custom ports for external databases:
  [defaults]
  POSTGRES_PORT=5432
  REDIS_PORT=6379
2026-01-23 21:28:53 -06:00
Matt Grutza
557e192d4c Add UTF8 encoding check for external databases
Extend ensure_utf8_encoding() to support both internal and external PostgreSQL.

- Modular mode: Uses TCP connection with PGPASSWORD authentication
- AIO mode: Uses Unix socket as postgres user
- Explicitly set database owner during recreation (fixes missing --owner flag)
- Conversion logic (dump/drop/recreate/restore) works for both AIO and modular modes
- Skip internal PostgreSQL setup entirely when DISPATCHARR_ENV=modular
2026-01-23 19:15:27 -06:00
SergeantPanda
655760f652 When moving a channel down (higher number) don't increase channel numbers, decrease.
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-01-23 18:10:16 -06:00
SergeantPanda
22ecee4f85 Bug Fix: Fix No EPG filter on channels table. 2026-01-23 17:56:21 -06:00
SergeantPanda
e3122b1a1b Bug Fix: Fix reordering during drag and drop. 2026-01-23 17:31:46 -06:00
SergeantPanda
037b6e62e3
Merge pull request #886 from Dispatcharr/dynamic-tables
Editable Channel Table
2026-01-23 16:55:40 -06:00
SergeantPanda
86bc0e2843 changelog: Update verbiage on changelog for editable channel table and link to FR 333 2026-01-23 16:48:54 -06:00
SergeantPanda
5348a4a564 Feature: Editable Channel Table Mode:
- Added a robust inline editing mode for the channels table, allowing users to quickly edit channel fields (name, number, group, EPG, logo) directly in the table without opening a modal.
  - EPG and logo columns now support searchable dropdowns with instant filtering and keyboard navigation for fast assignment.
  - Drag-and-drop reordering of channels enabled when unlocked, with persistent order updates.
  - Group column now uses a searchable dropdown for quick group assignment, matching the UX of EPG and logo selectors.
  - All editable cells provide clear focus, hover, and disabled states for improved accessibility and usability.
  - Table unlock/edit mode toggle with clear visual cues and safe-guarded save logic to prevent accidental edits.
  - All changes are saved via API with optimistic UI updates and error handling.
2026-01-23 16:03:26 -06:00
Tobias Effner
c698916a60 feat: migrate to UV 2026-01-23 22:45:37 +01:00
SergeantPanda
d4f412e352 Bug Fix: Channels table pagination error handling: Fixed "Invalid page" error notifications that appeared when filters reduced the result set while on a page beyond the new total. The API layer now automatically detects invalid page errors, resets pagination to page 1, and retries the request transparently. (Fixes #864)
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-01-23 10:33:14 -06:00
SergeantPanda
6e70753d1c changelog: Fixed nginx startup failure due to group name mismatch in non-container deployments
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-01-22 14:25:33 -06:00
SergeantPanda
9959e3d353
Merge pull request #878 from s0len/fix/nginx-group-name-mismatch
Fix: nginx startup failure due to group name mismatch
2026-01-22 14:18:57 -06:00
Matt Grutza
8c2ffbe76a CELERY_NICE_LEVEL warning
Changed the celery entrypoint to include a warning if CELERY_NICE_LEVEL is negative AND SYS_NICE is not configured (SYS_NICE is required for negative levels)
2026-01-21 17:59:23 -06:00
Matt Grutza
7a46577d2e Remove health check conditions
Not supported on compose v3+
2026-01-21 17:46:07 -06:00
Matt Grutza
236b2307e1 Add health check and fix dangerous checks
- docker-compose: added service health checks

- dockerfile: added if logic for sed command so missing files do not cause build fail

- entrypoint.celery: change migration detection to not continue until ALL migrations are applied

- entrypoint: trim django key and change external postgres check to python in case postgres binaries are missing
2026-01-21 17:40:36 -06:00
SergeantPanda
3311a38aae Bug fix: Fixed long IP addresses overlapping adjacent columns in stream connection card by adding truncation with tooltips displaying the full address. (Fixes #712)
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) Has been cancelled
2026-01-21 16:55:25 -06:00
SergeantPanda
e79622f513 adjust arrow to be next to title always. 2026-01-21 16:44:31 -06:00
SergeantPanda
58d14664e3 Enhancement: Adjust layout and spacing in StreamConnectionCard for improved UI consistency and readability 2026-01-21 16:35:00 -06:00
Matt Grutza
3706e63bed feat: Add DISPATCHARR_ENV=modular support for multi-container deployments
- docker/entrypoint.sh: Conditional PostgreSQL init/startup for modular mode
- docker/entrypoint.celery.sh: New dedicated entrypoint for celery container - prevents race condition in modular deployment
- docker/uwsgi.modular.ini: New uWSGI config without Redis/Celery daemons
- docker/Dockerfile: Add line ending fixes and chmod for entrypoints - adds cross-platform support for image builds
- docker/docker-compose.yml: Configure modular mode with DISPATCHARR_ENV - uses new celery entrypoint and adds depends_on to prevent race condition
2026-01-21 11:14:28 -06:00
Mattias Svensson
cbb8a52163 Fix: nginx startup failure due to group name mismatch
The script was creating a group named 'dispatch' (hardcoded) while
nginx.conf expected a group matching POSTGRES_USER (e.g., 'dispatcharr').

Changes:
- Use $POSTGRES_USER for group name instead of hardcoded 'dispatch'
- Make sed command more robust to match any existing user directive

This ensures the group name matches the user name, fixing the error:
"getgrnam("dispatcharr") failed in /etc/nginx/nginx.conf:1"

Fixes #877

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-21 08:04:49 +01:00
SergeantPanda
e43aba67e7 Enhancement: Refactor StreamConnectionCard layout for improved UI, separating channel name and current program display. 2026-01-20 19:35:19 -06:00
SergeantPanda
2fc2486c34 Enhancement: Added "Hide Stale" filter to quickly hide streams marked as stale.
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-01-20 18:51:13 -06:00
SergeantPanda
c9b454431c Enhancement: Streams table UI: Added descriptive tooltips to top-toolbar buttons (Add to Channel, Create Channels, Filters, Create Stream, Delete) and to row action icons (Add to Channel, Create New Channel). Tooltips now use a 500ms open delay for consistent behavior with existing table header tooltips.
Streams table button labels: Renamed "Remove" to "Delete" and "Add Stream to Channel" to "Add to Channel" for clarity and consistency with other UI terminology.
2026-01-20 18:01:17 -06:00
SergeantPanda
8bc88112aa Enhancement: Improved pill functionality and sizing. 2026-01-20 17:09:28 -06:00
SergeantPanda
0984ec9834 Enhancement: Add Progress bar showing elapsed and remaining time for currently playing programs 2026-01-20 16:31:41 -06:00
SergeantPanda
6b9e6b2d8a tests: Fix frontent tests for new stats features. 2026-01-20 15:38:36 -06:00
SergeantPanda
091c1686e5 Enhancement: Added tooltip on filter pills showing all selected items in a vertical list (up to 10 items, with "+N more" indicator) Also fixed +N not working as intended. 2026-01-20 15:31:34 -06:00
SergeantPanda
c6f359c159 Enhancement: Refactor StreamsTable component to improve MultiSelect UI with tooltips and pill displays for selected groups and M3Us. 2026-01-20 14:56:32 -06:00
SergeantPanda
0e1db3e39c Enhancement: - Stats page enhancements: Added "Now Playing" program information for active streams with smart polling that only fetches EPG data when programs are about to change (not on every stats refresh). Features include:
- Currently playing program title displayed with live broadcast indicator (green Radio icon)
  - Expandable program descriptions via chevron button
  - Efficient POST-based API endpoint (`/api/epg/current-programs/`) supporting batch channel queries or fetching all channels
  - Smart scheduling that fetches new program data 5 seconds after current program ends
  - Only polls when active channel list changes, not on stats refresh
- Channel preview button: Added preview functionality to active stream cards on stats page
2026-01-20 13:37:40 -06:00
SergeantPanda
3a5a676097 changelog: Update changelog to reference github issue for streamlink.
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-01-19 21:28:22 -06:00
SergeantPanda
3646ec5e46 changelog: Update changelog to reflect streamlink update. 2026-01-19 21:13:02 -06:00
SergeantPanda
2c5cc636a7 Security: - Updated react-router from 7.11.0 to 7.12.0 to address two security vulnerabilities:
- **High**: Open Redirect XSS vulnerability in Action/Server Action Request Processing ([GHSA-h5cw-625j-3rxh](https://github.com/advisories/GHSA-h5cw-625j-3rxh), [GHSA-2w69-qvjg-hvjx](https://github.com/advisories/GHSA-2w69-qvjg-hvjx))
  - **Moderate**: SSR XSS vulnerability in ScrollRestoration component ([GHSA-8v8x-cx79-35w7](https://github.com/advisories/GHSA-8v8x-cx79-35w7))
- Updated react-router-dom from 7.11.0 to 7.12.0 (dependency of react-router)
2026-01-19 21:03:18 -06:00
SergeantPanda
7fc2cbc45b tests: Fixed frontend tests failing after datetime utility changes. 2026-01-19 20:16:06 -06:00
SergeantPanda
cbcf2ac3c2 Bug fix: - Fixed date/time formatting across all tables to respect user's UI preferences (time format and date format) set in Settings page:
- Stream connection card "Connected" column
  - VOD connection card "Connection Start Time" column
  - M3U table "Updated" column
  - EPG table "Updated" column
  - Users table "Last Login" and "Date Joined" columns
  - All components now use centralized `format()` helper from dateTimeUtils for consistency
- Removed unused imports from table components for cleaner code
2026-01-19 20:07:31 -06:00
SergeantPanda
0b83137ac6 Enhancement: DVR recording remux fallback strategy: Implemented two-stage TS→MP4→MKV fallback when direct TS→MKV conversion fails due to timestamp issues. On remux failure, system now attempts TS→MP4 conversion (MP4 container handles broken timestamps better) followed by MP4→MKV conversion, automatically recovering from provider timestamp corruption. Failed conversions now properly clean up partial files and preserve source TS for manual recovery.
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-01-19 18:56:23 -06:00
SergeantPanda
cf323f15a5 changelog: Update changelog for dev build script.
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) Has been cancelled
2026-01-18 17:52:27 -06:00
SergeantPanda
8012f372cd
Merge pull request #865 from JeffreyBytes:fix/build-dev-logic
fix: stabilize build-dev paths and push behavior
2026-01-18 17:50:28 -06:00
SergeantPanda
235467a1ac changelog: Update changelog for logo caching. 2026-01-18 17:31:20 -06:00
SergeantPanda
8b15e6e52f
Merge pull request #871 from Dispatcharr/main
Merge main into dev
2026-01-18 17:29:24 -06:00
SergeantPanda
8521df94ad
Merge pull request #868 from DawtCom:main
Some checks failed
Build and Push Multi-Arch Docker Image / build-and-push (push) Has been cancelled
Move caching to client to remove burden on dispatch server
2026-01-18 17:26:49 -06:00
SergeantPanda
fec868ac30
Merge pull request #867 from JeffreyBytes/hotfix/streamtable-filter-bug
Fix streams requery to respect table filters
2026-01-18 17:01:29 -06:00
SergeantPanda
39bf57bf40 Bug Fix: Fixed TypeError on streams table load after container restart: Added robust data validation and type coercion to handle malformed filter options during container startup. The streams table MultiSelect components now safely convert group names to strings and filter out null/undefined values, preventing "right-hand side of 'in' should be an object, got number" errors when the backend hasn't fully initialized. API error handling returns safe defaults. 2026-01-18 16:24:26 -06:00
SergeantPanda
620d65d1de Bug Fix: Fixed XtreamCodes API crash when channels have NULL channel_group: The player_api.php endpoint (xc_get_live_streams) now gracefully handles channels without an assigned channel_group by dynamically looking up and assigning them to "Default Group" instead of crashing with AttributeError. Additionally, the Channel serializer now auto-assigns new channels to "Default Group" when channel_group_id is omitted during creation, preventing future NULL channel_group issues. 2026-01-18 15:52:50 -06:00
DawtCom
c970cfcf9a Move caching to client to remove burden on dispatch server 2026-01-18 00:49:17 -06:00
Jeffrey C
4f9088c6fc
Fix: requery streams using table filters 2026-01-17 21:15:02 -06:00
SergeantPanda
fe60c4f3bc Enhancement: Update frontend tests workflow to ensure proper triggering on push and pull request events only when frontend code changes.
Some checks failed
Build and Push Multi-Arch Docker Image / build-and-push (push) Waiting to run
Frontend Tests / test (push) Has been cancelled
2026-01-17 18:30:13 -06:00
SergeantPanda
a772f892bd changelog: Update changelog for recent stream table PR.
Some checks are pending
Build and Push Multi-Arch Docker Image / build-and-push (push) Waiting to run
Frontend Tests / test (push) Waiting to run
2026-01-17 18:26:33 -06:00