Commit graph

1427 commits

Author SHA1 Message Date
SergeantPanda
97515c4d05 tests: fix proxy setting test 2026-06-30 10:34:40 -05:00
SergeantPanda
ac6d43af8c refactor(proxysettings): Enhance proxy settings UI by categorizing advanced options and improving documentation. The channel_client_wait_period and channel_init_grace_period are now marked as advanced settings, and the UI has been updated to allow users to expand and view these options. Additionally, the changelog has been updated to reflect these changes and clarify the behavior of grace periods. 2026-06-30 10:00:22 -05:00
SergeantPanda
391c3412d2 refactor(proxy): Add new client connect grace period setting and update channel initialization grace period defaults. The channel_client_wait_period is introduced to manage channel lifetimes before client connections, while the channel_init_grace_period default is increased to improve failover handling. 2026-06-28 11:31:21 -05:00
SergeantPanda
fd93c0dc3d fix(channel management): Implement channel initialization grace period handling to ensure proper state transitions during live stream startup. Channels now honor the configured grace period for buffer filling, promoting to active state when conditions are met. Updated related tests and documentation for clarity. (Fixes #1380)
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-06-25 14:24:30 -05:00
SergeantPanda
c44cac2e9a fix(recording playback): Complete authentication handling for DVR recordings by allowing JWT tokens via query parameters for both native video and HLS segments. Updated API views to support token propagation in redirects and playlist rewrites. Enhanced tests to validate new authentication behavior across endpoints. 2026-06-25 11:27:57 -05:00
SergeantPanda
562393b77e fix(recording playback): Enhance completed DVR recording playback by allowing JWT token via query parameter for native <video src> support. Updated authentication handling in API views and modified FloatingVideo component to append token dynamically. Updated tests to reflect new API URL structure.
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-06-24 17:32:48 -05:00
SergeantPanda
c5e5016728 fix(dvr): Fix in-progress DVR playback to prevent jumping to live edge and update FloatingVideo component for improved error handling. Added tests to verify HLS configuration behavior. (Fixes #1329) 2026-06-24 17:02:31 -05:00
SergeantPanda
6b6eb11cc0 chore(dependencies): update Vite, esbuild and js-yaml to latest versions in package.json 2026-06-24 16:31:15 -05:00
None
a29704af55 fix(channels): account for group_override in the auto-sync range-conflict check
The range-conflict warning classified each channel in the configured range as either this config's own auto-sync output or a real conflict, comparing each occupant against the source group. When a group sets a group_override, auto-sync creates its channels in the override target group, so the config's own channels failed that comparison and were misclassified as a conflict.

- Add effectiveSyncGroupId to resolve the group the sync's channels actually land in (the group_override target when set, otherwise the source group).
- Compare occupants against that effective target, so the config's own output is recognized while genuine conflicts (manual channels, channels from another account, channels in a different group, user-pinned numbers) still warn.
- Add Vitest coverage for the helper, the override case, and an over-suppression guard, plus a backend test asserting the numbers-in-range endpoint reports the override target group.
2026-06-19 23:40:10 -05:00
SergeantPanda
c27f28c0c1 Merge branch 'dev' of https://github.com/Dispatcharr/Dispatcharr into pr/FiveBoroughs/1319 2026-06-11 18:09:12 -05:00
SergeantPanda
5744a55b06
Merge pull request #1328 from CodeBormen:fix/1273-provider-numbering
Fix/1273 provider numbering
2026-06-11 17:03:17 -05:00
SergeantPanda
ed364a26c9 refactor(EPGSourceViewSet, frontend): streamline SD countries fetching and remove proxy endpoint
- Introduced a new method `_fetch_sd_countries` in `EPGSourceViewSet` to fetch SD countries directly from the backend, eliminating the need for a separate proxy endpoint.
- Updated the `sd_lineups` action to include the fetched countries in the response.
- Removed the `getSDCountries` method from the API and adjusted the frontend to fetch countries alongside lineups, improving efficiency
- Updated related components to handle the new data structure for countries.
2026-06-11 09:00:35 -05:00
Seth Van Niekerk
887a177581
proxy SD country list fetch through backend to fix CORS failure 2026-06-10 08:46:02 -04:00
SergeantPanda
4fc12bca4a refactor(m3u, channels, proxy): enhance stream assignment logic and error handling
- Improved logging in the Stream model for better debugging of profile evaluations.
- Introduced a new method `_stream_assignment_is_reusable` in the Channel model to determine if existing stream assignments can be reused, enhancing efficiency.
- Updated the release logic in `release_profile_slot` to utilize stored credential keys, reducing unnecessary database lookups.
- Simplified error handling in the `get_stream_info_for_switch` function to ensure proper stream release on exceptions.
- Enhanced tests for connection pool management and error handling in the ServerGroupsTable component to improve reliability and user feedback.
2026-06-09 17:59:12 -05:00
SergeantPanda
647c1316ba refactor(M3U): enhance form layout and streamline input handling
- Increased modal size for better visibility and user experience.
- Adjusted form layout for improved alignment and spacing between elements.
- Removed unused Checkbox component and simplified the account type selection logic.
- Consolidated VOD-related input fields under the Xtream Codes account type for clarity.
- Enhanced overall readability and maintainability of the component by reducing complexity in the form structure.
2026-06-09 16:34:27 -05:00
SergeantPanda
2dae24a02b refactor(ServerGroupsTable, ServerGroupsManagerModal): adjust layout and component structure
- Changed the size of the ServerGroupsManagerModal from "lg" to "md" for improved UI consistency.
- Refactored ServerGroupsTable to enhance the layout, including adjustments to column sizes and the addition of minimum sizes for better responsiveness.
- Simplified the RowActions component for better readability and alignment.
- Updated the loading and empty state handling in the table to provide clearer user feedback.
- Removed unused local storage hook from the component, streamlining the codebase.
2026-06-09 16:18:09 -05:00
SergeantPanda
705041ea81 refactor(channel_status, vod_proxy): remove stream URL credential extraction
- Eliminated redundant extraction of provider usernames from stream URLs in both ChannelStatus and VOD stats data functions, simplifying the codebase.
- Updated frontend components to reflect the removal of provider username display, streamlining the UI.
- Enhanced overall readability and maintainability of the code by reducing complexity in handling stream URLs.
2026-06-09 14:46:26 -05:00
SergeantPanda
bc046b3c92 refactor(m3u, channels): streamline stream assignment and server group management
- Renamed `_clear_stream_assignment_keys` to `_release_stale_stream_assignment` for clarity and updated its logic to release pool counters.
- Introduced new functions for managing credential slots during profile switches, enhancing the handling of shared connection limits across server groups.
- Removed the `max_streams` field from the `ServerGroup` model and updated related components to reflect this change, simplifying the server group management.
- Updated frontend components to integrate server group management, allowing for dynamic creation and editing of server groups.
- Enhanced error handling in stream URL generation to provide more informative feedback on connection issues.
- Added tests for stale assignment release and credential management during profile switches.
2026-06-09 13:40:16 -05:00
SergeantPanda
0f0e855507 Merge branch 'dev' of https://github.com/Dispatcharr/Dispatcharr into pr/Goldenfreddy0703/1254 2026-06-09 11:16:39 -05:00
SergeantPanda
7086f41d64 feat(epg): overhaul EPG auto-matching logic and improve performance
- Moved matching logic to a dedicated module for better organization and testability.
- Made single-channel auto-matching asynchronous, allowing for larger EPG libraries without hitting HTTP timeouts.
- Enhanced memory management and throughput during EPG matching, including optimizations for fuzzy matching and bulk processing.
- Fixed various reliability issues in the auto-matching process, ensuring accurate channel assignments and improved UI feedback.
- Updated API views and frontend components to reflect changes in the matching process and provide real-time notifications.
- Added tests for EPG matching functionality and name normalization.
- Single-channel and selected-channel auto-match always run, even when the channel already has EPG assigned; match-all (no channel IDs) still only processes channels without EPG.
2026-06-08 18:12:29 -05:00
None
57cae0e4be fix(m3u): correct auto-sync numbering field interactions from the auto-sync overhaul
The auto-sync overhaul added a [start, end] range and a shared numbering picker, but each mode's UI exposes only a subset of the persisted fields (Provider's "Start #" writes channel_numbering_fallback; Next Available exposes no Start/End) while the backend read auto_sync_channel_start and auto_sync_channel_end in every mode. Switching modes never resets the others, so a stale or auto-computed value silently changed numbering.

- Provider mode honors the provider-supplied number (stream_chno) verbatim; the group's Start (channel_numbering_fallback) and End bound only the fallback for streams the provider did not number. auto_sync_channel_start is no longer applied in provider mode.
- Next Available ignores End, since its UI exposes no range.
- Range enforcement (the overflow-delete) runs in fixed mode only, the one mode with a user-set [start, end] range.
- Provider mode gains the Start>End guard fixed mode already had, so an inverted fallback range cannot fail every numberless stream.

Includes backend and frontend regression tests.
2026-06-07 22:02:23 -05:00
SergeantPanda
b928de7d50 fix(epg): resolve EPG channel list refresh issue after parsing completion
- Addressed a bug where the EPG channel list did not refresh after a source finished parsing channels due to the `epg_refresh` WebSocket handler using a stale snapshot. The handler now correctly reads the current store state and ensures `fetchEPGData()` is called upon completion of channel parsing.
- Updated tests to verify that the frontend receives the correct parsing completion signals.
2026-06-07 09:56:25 -05:00
SergeantPanda
3caa2ca705 chore: update dependencies in package.json and package-lock.json
Upgrade vitest to version 4.1.8 and add @hookform/resolvers as a new dependency. Update related dependencies for @vitest packages to their latest versions, ensuring compatibility and improved functionality.
2026-06-05 13:33:28 -05:00
SergeantPanda
70d900f346 feat(epg): implement auto-apply functionality for EPG logos
Add support for automatically applying channel logos from EPG data during refresh. Introduce a new toggle in the UI for enabling/disabling this feature, and update the backend to handle both channel IDs and EPG source IDs for logo application. Enhance the logo application task to process large libraries efficiently in chunks, improving performance and memory usage. Update changelog to reflect these changes.
2026-06-05 12:49:05 -05:00
SergeantPanda
7e906ad78e feat(epg): enhance poster style selection and fetching logic
Introduce a new poster style selection feature in the EPG settings, allowing users to choose their preferred artwork style. Update the logic for fetching and displaying program artwork from Schedules Direct, ensuring that the selected style is honored with appropriate fallbacks. Set default poster art to 'primary'. Add comprehensive tests to validate the poster selection functionality across various scenarios.
2026-06-05 10:14:07 -05:00
SergeantPanda
ff081d7dc8 feat(epg): implement poster artwork fetching and logo auto-apply functionality
Add a new task to fetch program artwork from Schedules Direct and auto-apply logos to channels based on EPG data. Enhance the existing logic to handle poster backfill and update program records with fetched artwork. Readd the WebSocket handler to manage IP lookup events and adjust the EPGsTable component to display relevant credentials based on the source type.
2026-06-05 09:28:55 -05:00
SergeantPanda
4eab95793e refactor: rename useSDLogos to autoApplySDLogos for clarity
Update the variable name in the EPG settings to better reflect its purpose. Adjust related logic in the UI to ensure consistent handling of the auto-apply feature for SD logos.
2026-06-05 09:08:26 -05:00
Shokkstokk
b6a5738f7d refactor: remove useSDLogos guard from logo style handler
Allow logo style selection to save regardless of toggle state.
2026-06-05 07:33:03 +00:00
Shokkstokk
8ed0030223 refactor: always enable logo style picker per reviewer feedback
Logo style selection should always be available so users can set their
preference before enabling SD logos.
2026-06-05 03:37:50 +00:00
SergeantPanda
c4d73eae39 fix(epg): repair SD poster display and backfill missing artwork
Build absolute poster proxy URLs via build_absolute_uri_with_port so
program detail images resolve correctly in dev and behind reverse
proxies. Backfill sd_icon for programs when poster fetch is enabled
but a delta refresh skips program metadata. Add a dev-mode frontend
fallback for relative image paths and correct the poster caching
description in the SD settings UI.
2026-06-04 22:00:15 -05:00
Shokkstokk
e731527104 fix: add data-testid to TextInput mock in EPG test 2026-06-05 01:26:51 +00:00
Shokkstokk
c0b7cc5fe8 fix: add updateSDSettings to API mock in EPG test 2026-06-05 01:19:53 +00:00
Shokkstokk
6b5c745962 fix: add remaining Mantine component mocks to EPG test
Add UnstyledButton, Alert, Stack, Text, TextInput mocks to prevent
test failures from unmocked Mantine components in SD settings UI.
2026-06-05 00:57:19 +00:00
Shokkstokk
4ae0796b3d fix: add Switch mock to EPG test for SD logo toggle
Frontend test was failing because the Mantine core mock didn't include
the Switch component used by the SD logo style picker.
2026-06-05 00:28:50 +00:00
Goldenfreddy0703
abdf2d7864 Fix credential release on deleted profile and round 3 review items.
Store credential Redis keys at reserve so release works when the profile row is deleted. Return reserve failure reasons to avoid fingerprint DB queries on logging paths. Document unlimited profile bypass in pool logic and Server Group UI.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-04 19:51:20 -04:00
Shokkstokk
7c91508f3c fix: add missing updateSDSettings API method and EPG refresh handlers
Add updateSDSettings method to API client for SD logo style and settings
management. Add fetchEPGData and requeryChannels calls after EPG match
completion to ensure UI refreshes immediately. Add SD logo style picker
and cache-busting for channel logos.
2026-06-04 23:46:40 +00:00
mwhit
661d1690d2 feat: expose SD enrichment fields in serializer and frontend
Add content_advisory, content_ratings, event_details, runtime to
ProgramDetailSerializer. Display content advisory, sports venue/teams,
and first-aired date in ProgramDetailModal.
2026-06-04 22:28:18 +00:00
Shokkstokk
4eec542ef8
Merge branch 'dev' into feature/schedules-direct-epg 2026-06-03 23:38:54 -04:00
Five Boroughs
d204d6ad64
feat(frontend): multi-word, accent-insensitive EPG channel filter 2026-06-03 20:31:52 +02:00
None
2a5889f5b2 fix(channels): Channel Group Override interactions
- Compact numbering: resolve the source relation when an override stores channels under the target group, so hiding releases the slot, unhiding assigns one, and repack sees the channels (no more spurious RANGE_EXHAUSTED). Type-safe override match; the bulk path stays single-query on the common path.
- Channel form: keep the clear-override control available when an override's value equals the provider value (isFormFieldOverridden is now existence-aware).
- Tests: compact override hide/unhide/repack, no-override fast-path guard, repack query-scaling guard, and existence-aware override detection.
2026-06-02 00:04:44 -05:00
SergeantPanda
1fd37b9a51 feat(channel-form): reorganize channel edit form into three semantic columns for improved layout and usability 2026-06-01 19:34:39 -05:00
SergeantPanda
8e03427844 Merge branch 'dev' of https://github.com/Dispatcharr/Dispatcharr into pr/FiveBoroughs/938 2026-06-01 18:58:14 -05:00
SergeantPanda
b26d4815f1 tests: Fix frontend sidebar and settings tests. 2026-05-31 18:50:44 -05:00
SergeantPanda
f403004769 fix(environment): harden IP lookup, add WebSocket push, improve sidebar UX
- Fix socket leak in local IP detection using try/finally; replace 8.8.8.8
  with RFC 5737 test address 203.0.113.1
- Validate ipify response with ipaddress.ip_address() before using in URL
- Push ip_lookup_complete WebSocket event when background lookup finishes,
  eliminating frontend polling entirely
- Show Skeleton placeholder in sidebar while IP lookup is pending
- Replace hover-to-reveal blur with click-to-toggle for mobile support
- Fix copy button propagating click to blur toggle via stopPropagation
- Add missing city field to null-env fallback in settings store
- Add setEnvironmentFields() store action for WebSocket-driven updates
- Remove unused imports from api_views.py
2026-05-31 17:56:52 -05:00
SergeantPanda
1d07b26a01 Merge branch 'dev' of https://github.com/Dispatcharr/Dispatcharr into pr/sethwv/1308 2026-05-31 16:38:41 -05:00
SergeantPanda
5d2bc2606c fix(epg): add force refresh option for EPG data import and update related API methods 2026-05-31 11:22:04 -05:00
Five Boroughs
10d558f136
perf(epg): async index build, defer index column, tight build lock, channel-id canonicalization, retry-on-error 2026-05-31 17:13:11 +02:00
Five Boroughs
9903f0b75d
refactor(frontend): extract useEpgPreview to its own hook file 2026-05-31 17:13:11 +02:00
Five Boroughs
a7b9523352
test(frontend): update channel form mocks after preview rebase 2026-05-31 17:13:11 +02:00
Five Boroughs
7c0c513f8f
test(epg,frontend): add coverage for current-program lookup and preview behavior 2026-05-31 17:13:11 +02:00