Commit graph

1375 commits

Author SHA1 Message Date
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
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
Five Boroughs
8f1dd2ffeb
Revert unintended whitespace changes in apps.py and Channel.jsx 2026-05-31 17:13:11 +02:00
Five Boroughs
2bf4e8cd0f
WIP: EPG channel preview with byte-offset index lookup 2026-05-31 17:13:11 +02:00
FiveBoroughs
ef1518a8dd
Fix: Auto-parse EPG programs for unlinked channels on preview
When selecting an EPG channel in the channel form, if that EPG entry's
programs had never been parsed, the preview showed "No current program".
This was because parse_programs_for_tvg_id requires a linked channel.

- Add force parameter to parse_programs_for_tvg_id to bypass channel check
- Auto-trigger parsing from current-programs API when no programs exist
- Check Redis task lock to prevent duplicate parse tasks from concurrent requests
- Frontend retries up to 3 times with 10s delay to pick up parsed results
- Skip parsing for dummy EPG sources
2026-05-31 17:13:11 +02:00
FiveBoroughs
e733b9872f
Refactor: Extract shared ProgramPreview component and fix EPG preview bugs
- Extract ProgramPreview component from duplicated code in Channel.jsx
  and StreamConnectionCard.jsx (~80+ lines each)
- Fix watch('epg_data_id') called directly in useEffect dependency array,
  which could cause infinite re-renders
- Add request cancellation for rapid EPG selection changes in channel form
- Remove unused imports (Radio, Progress, ChevronDown, ChevronRight)
2026-05-31 17:13:11 +02:00
FiveBoroughs
9367d76dac
Add EPG program preview to channel edit/create modal
- Extended CurrentProgramsAPIView to accept epg_data_ids parameter
- Added getCurrentProgramForEpg() API method in frontend
- Added UI in Channel form showing current program with tooltip
- Shows loading state, no program state, and program details
- Includes expandable description, progress bar with elapsed/remaining time
- Matches stats page 'Now Playing' feature behavior
2026-05-31 17:13:11 +02:00
Seth Van Niekerk
4e5ecc80aa
add city to flag hover 2026-05-31 10:27:55 -04:00
Seth Van Niekerk
a9b729c3f5
blur just the first two octets/four segments 2026-05-31 10:24:28 -04:00
SergeantPanda
2156ea6283
Merge pull request #1284 from nemesbak:fix/delete-last-playlist-error
fix(frontend): clean up profiles state when playlists are deleted
2026-05-30 12:49:26 -05:00
SergeantPanda
df6f98a806 tests: Add tests for playlist deletion. 2026-05-30 12:43:41 -05:00
Seth Van Niekerk
16cb9edcbd
blur public IP in sidebar, add ip lookup toggle and env var, make lookup non-blocking 2026-05-30 13:07:07 -04:00
SergeantPanda
36968631a6 tests: Fix frontend series and vod tests. 2026-05-30 11:28:07 -05:00
SergeantPanda
72d1520400 feat(auth): add QueryParamJWTAuthentication for token retrieval via query parameters
feat(vod): include token in stream URL for episode and movie requests (Fixes #1224)
2026-05-30 11:14:59 -05:00
SergeantPanda
d29a9ef88c fix(tests): update API call expectations in useVODStore tests to include null parameter 2026-05-29 20:00:55 -05:00
SergeantPanda
d8ead97049 Merge branch 'dev' of https://github.com/Dispatcharr/Dispatcharr into pr/nemesbak/1285 2026-05-29 19:24:35 -05:00
SergeantPanda
7cbc71f7fb refactor(vod): Apply prettier. 2026-05-29 19:23:51 -05:00
SergeantPanda
36879c10f2 fix(vod): validate relation_id and handle loading state in VODModal 2026-05-29 19:23:13 -05:00
SergeantPanda
87accc2f63
Merge pull request #1305 from nemesbak:fix/output-profile-guide-player
fix(frontend): apply web-player output profile in TV Guide and all live stream calls
2026-05-29 14:53:49 -05:00
nemes
c717df50f9 fix(frontend): update getShowVideoUrl tests to expect output_format and output_profile 2026-05-29 17:32:24 +02:00
nemes
98d7acd3c0 fix(frontend): apply output_profile and output_format in all live stream player calls
getShowVideoUrl was returning a raw proxy URL without calling
buildLiveStreamUrl, so the web-player output profile preference stored in
localStorage was ignored when starting a live stream from the TV Guide,
Program Detail modal, DVR page, Recording Details modal, and Recording Card.

Fixes #1304
2026-05-29 17:32:22 +02:00
SergeantPanda
e04afff04a
Merge pull request #1274 from nick4810:tests/frontend-unit-tests
Tests/frontend unit tests
2026-05-29 09:35:00 -05:00
nemes
17ce532326 fix(frontend): update getShowVideoUrl tests to verify output_format and output_profile 2026-05-29 13:23:22 +02:00
nemes
14c54b60f1 fix(frontend): apply output_profile and output_format in all live stream player calls
getShowVideoUrl was building raw proxy URLs without calling buildLiveStreamUrl,
so the web-player output profile preference stored in localStorage was silently
ignored when starting a live stream from the TV Guide, Program Detail modal,
DVR page, Recording Details modal, and Recording Card.

Fix: import buildLiveStreamUrl in RecordingCardUtils and call it at the end of
getShowVideoUrl so every caller inherits the correct output_format=mpegts
param and any configured output_profile automatically.

Fixes #1304
2026-05-29 13:20:35 +02:00
Nick Sandstrom
714f1b5cf5 Updated rendering behavior 2026-05-28 18:46:57 -07:00
Nick Sandstrom
5eeca5fc94 Fixed test behavior 2026-05-28 18:46:57 -07:00
Nick Sandstrom
cc59718997 Small cleanup 2026-05-28 18:46:57 -07:00
nemesbak
16f4f0c9ed fix(frontend): clean up profiles state when playlists are deleted
removePlaylists() filtered the playlists array but never removed the
corresponding entries from the profiles map (the @TODO left since the
store was introduced). Any component reading profiles[id] after
deletion would get undefined and crash with
'undefined is not an object (evaluating P[R].name)'.

Fix: build a copy of profiles with the deleted IDs removed and include
it in the state update alongside the filtered playlists array.

Fixes #1269

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-28 13:39:04 +02:00
nemesbak
5fbe38f8d2 fix(vod): respect relation_id when switching providers in SeriesModal/VODModal
The provider-info endpoints for both series and movies always returned
data from the highest-priority relation, ignoring the provider the user
had selected in the dropdown. Switching sources in the UI produced no
change in the episode list or movie details.

Root cause: the endpoints had no support for a relation_id query param,
and the frontend never passed one when the user changed the selection.

Fix (backend):
- series provider-info: accept ?relation_id=<id> and query that specific
  M3USeriesRelation; fall back to highest-priority when omitted
- movie provider-info: same treatment for M3UMovieRelation

Fix (frontend):
- api.getSeriesInfo / api.getMovieProviderInfo accept an optional
  relationId argument and append it to the query string
- useVODStore.fetchSeriesInfo / fetchMovieDetailsFromProvider forward
  the argument to the API layer
- SeriesModal.onChangeSelectedProvider re-fetches series info (episodes
  included) with the newly selected relation's id
- VODModal.onChangeSelectedProvider re-fetches movie details with the
  newly selected relation's id

Fixes #1250

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-28 13:39:04 +02:00
Nick Sandstrom
284ba87fe7 Minor formatting changes 2026-05-25 18:15:18 -07:00
Nick Sandstrom
fee8913824 Added tests for components 2026-05-25 18:08:41 -07:00
Nick Sandstrom
e766c4dd54 Refactored components 2026-05-25 18:08:41 -07:00
Nick Sandstrom
688ca2b405 Updated Guide component and utils 2026-05-25 18:08:41 -07:00
Nick Sandstrom
275a93b9b5 Added functionality to dateTimeUtils.js 2026-05-25 18:08:41 -07:00
Nick Sandstrom
1dd0446701 Added tests for utils 2026-05-25 18:08:40 -07:00
Nick Sandstrom
6021bdf741 Extracted utils 2026-05-25 18:08:40 -07:00
Seth Van Niekerk
0db557384a
configurable per-page, sticky pagination footer, fix update sort order and disabled button badge color 2026-05-24 10:59:53 -04:00
SergeantPanda
61c187fc72 Merge branch 'dev' of https://github.com/Dispatcharr/Dispatcharr into pr/JCBird1012/1255 2026-05-23 21:43:13 -05:00
SergeantPanda
92d3068be0 fix: ensure migrations run automatically after restoring backups to prevent missing schema issues 2026-05-23 21:25:44 -05:00
Jonathan Caicedo
0d1d1f2722 fix: revert nginx timeouts; fire stats fetch on mount regardless of interval 2026-05-23 14:20:13 -04:00
SergeantPanda
1ab1f638a3 tests: Fix frontend test for sidebar.
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-05-21 17:08:01 -05:00
SergeantPanda
f416c7c251 Enhancement: add About modal with version info and community links; refactor SVG icons into separate module 2026-05-21 16:00:52 -05:00
Jonathan Caicedo
a2c69be861 fix: update Stats tests to expect single mount fetch after removing duplicate useEffect
Tests were asserting fetchActiveChannelStats/getVODStats were called twice
on mount, encoding React strict mode's double-invoke behavior rather than
testing actual application logic. Update all affected call count assertions
to reflect the correct single-fetch behavior.
2026-05-20 22:23:11 -04:00
Jonathan Caicedo
e2074c1921 fix: reduce intermittent 503s on stats page and API requests 2026-05-20 21:52:28 -04:00