HlsPlaylistFilter.TrimPlaylist caught parse failures and returned an
"empty" result: no segments, media sequence 0, empty playlist text.
Callers treated that as success: the session endpoint served the empty
playlist as 200, and TrimAndDelete wrote it over live.m3u8 on disk,
turning a transient parse error into persistent corruption.
Return Option<TrimPlaylistResult> with None on failure instead. The
session endpoint now answers with the 503 retry response, and
TrimAndDelete leaves the existing playlist untouched so the session
can recover on the next cycle.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This branch is only reached when a session worker exists, so a failed
trim is transient: either ffmpeg has not written the first playlist yet,
or the read failed. Returning 404 told clients the stream was gone, and
many abandon it rather than polling again.
Return 503 with a Retry-After hint instead. Cancellation now logs at
debug rather than warning, since the client has already disconnected and
this endpoint is polled continuously by every viewer.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
ErsatzTV.Tests references NUnit, NUnit3TestAdapter and Shouldly, but not
Microsoft.NET.Test.Sdk. Without it `dotnet test` builds the project and
then discovers nothing in it, so the two MultiSelectBase tests added
alongside the project in #2738 have never actually run.
Adding the package lets them execute; both pass, and a solution-wide
`dotnet test` still reports no failures.
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
* Added `schedules` to YAML/Sequenced Playback
* Add tests for yaml playback
* `YamlPlayoutScheduleItem` now implements `IAlternateScheduleItem`
* New tests for YamlPlayoutScheduleItem instead of the old SequentialScheduleSelector
* add more safety and a couple tests
* fix shuffle_sequence instruction handler
---------
Co-authored-by: Jason Dove <1695733+jasongdove@users.noreply.github.com>