diff --git a/CHANGELOG.md b/CHANGELOG.md index 0e32c811b..b4cf0aaa8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,7 +10,6 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). - Add `MediaItem_Resolution` template data (the current `Resolution` variable is the FFmpeg Profile resolution) - Add `MediaItem_Start` template data (DateTimeOffset) - Add `MediaItem_Stop` template data (DateTimeOffset) -- Time shift on-demand playouts every hour to prevent XMLTV from appearing empty ### Fixed - Fix HLS Direct playback with Jellyfin 10.11 @@ -23,6 +22,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). - Properly set explicit audio decoder on combined audio and video input file - Fix building sequential schedules across a UTC offset change - Fix block start time calculation across a UTC offset change +- Fix XMLTV generation for channels using on-demand playout mode ### Changed - Use smaller batch size for search index updates (100, down from 1000) diff --git a/ErsatzTV.Application/Playouts/Commands/BuildPlayoutHandler.cs b/ErsatzTV.Application/Playouts/Commands/BuildPlayoutHandler.cs index f6ea6b8db..25ff0c8b3 100644 --- a/ErsatzTV.Application/Playouts/Commands/BuildPlayoutHandler.cs +++ b/ErsatzTV.Application/Playouts/Commands/BuildPlayoutHandler.cs @@ -298,7 +298,7 @@ public class BuildPlayoutHandler : IRequestHandler 0; + bool hasChanges = changeCount > 0 || referenceData.Channel.PlayoutMode is ChannelPlayoutMode.OnDemand; if (request.Mode != PlayoutBuildMode.Continue && hasChanges) { diff --git a/ErsatzTV/Services/SchedulerService.cs b/ErsatzTV/Services/SchedulerService.cs index 6a400eb10..a01e250c1 100644 --- a/ErsatzTV/Services/SchedulerService.cs +++ b/ErsatzTV/Services/SchedulerService.cs @@ -213,18 +213,13 @@ public class SchedulerService : BackgroundService .Include(p => p.Channel) .ToListAsync(cancellationToken); - foreach (Playout playout in playouts.OrderBy(p => decimal.Parse(p.Channel.Number, CultureInfo.InvariantCulture))) + foreach (Playout playout in playouts.OrderBy(p => decimal.Parse( + p.Channel.Number, + CultureInfo.InvariantCulture))) { await _workerChannel.WriteAsync( new BuildPlayout(playout.Id, PlayoutBuildMode.Continue), cancellationToken); - - if (playout.Channel.PlayoutMode is ChannelPlayoutMode.OnDemand) - { - await _workerChannel.WriteAsync( - new TimeShiftOnDemandPlayout(playout.Id, DateTimeOffset.Now, false), - cancellationToken); - } } }