256 Commits
Author SHA1 Message Date
Gitea Actions abf5d36a7f Update manifest.json for version 1.5.0 2026-09-27 00:10:13 +00:00
Gitea Actions 0fd1e61979 Nightly: 1.0.20260926.227 (aa47de9) 2026-09-26 23:51:31 +00:00
dtourolleandClaude Opus 5.5 aa47de9912 Record into a Jellyfin library by default; configurable recording location
🏗️ Build Plugin / build (push) Successful in 12m31s
Nightly Build / nightly-build (push) Successful in 2m44s
🧪 Test Plugin / test (push) Successful in 11m14s
🚀 Release Plugin / build-and-release (push) Successful in 12m33s
When no custom directory is set, recordings go to an "SRF Recordings" folder
in the chosen library, or the first TV Shows library, so they show up without
adding a library by hand. The settings page gets a library picker, a check
that the directory is writable, and help for sandboxed systemd services.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
v1.5.0 latest
2026-09-26 19:35:55 -04:00
Gitea Actions 9467cb28c7 Update manifest.json for version 1.4.0 2026-09-26 16:03:07 +00:00
Gitea Actions ac16cf7394 Nightly: 1.0.20260926.223 (71a65aa) 2026-09-26 15:44:30 +00:00
dtourolleandClaude Opus 5.5 71a65aab6e Fix recordings dying mid-stream; record to growing .ts with live buffer playback
🏗️ Build Plugin / build (push) Successful in 12m44s
Nightly Build / nightly-build (push) Successful in 2m49s
🧪 Test Plugin / test (push) Successful in 11m18s
🚀 Release Plugin / build-and-release (push) Successful in 12m24s
A recording of a live event crashed partway through: when its short
Akamai token expired, the proxy's stale-alias check swapped the
recording's mapping to the most recently registered deferred stream,
of any content. Segment requests were then built against the wrong CDN
path, returned 403, and ffmpeg exited, splitting the recording into
several files.

Proxy:
- Never swap URN-backed livestreams; they refresh themselves from the
  API. Only consider swap candidates with the same URN.

Recording lifecycle:
- Complete a recording once its stream has been gone from the API for
  5 minutes (broadcasts can end before ValidTo).
- Fail a recording still waiting for its stream after ValidTo (or 12h
  after ValidFrom) instead of retrying forever.
- Wait for a DVR window whose start= is still in the future instead of
  starting ffmpeg against a 400/404.
- Keep the original start time across restarts; don't mark a recording
  failed on shutdown cancellation.

Growing .ts recordings:
- ffmpeg writes MPEG-TS (-c copy -copyts) to stdout and the plugin
  appends it to one file per recording, so restarts continue the same
  file and timeline.
- The Recordings folder lists any recording with a file on disk, not
  only completed ones.
- In-progress recordings are exposed as infinite streams reading through
  a new endpoint that follows the growing file (same pattern as
  Jellyfin's DVR), so they can be watched from the start like a
  livestream buffer.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
v1.4.0
2026-09-26 10:14:24 -04:00
Gitea Actions c6a1fd9f63 Update manifest.json for version 1.3.0 2026-09-25 23:32:45 +00:00
Gitea Actions fb32d5c5e2 Nightly: 1.0.20260925.219 (95ce4ed) 2026-09-25 23:30:39 +00:00
dtourolleandClaude Opus 5.5 95ce4edf9b Show times in a configurable time zone
Nightly Build / nightly-build (push) Successful in 1m32s
🧪 Test Plugin / test (push) Successful in 48s
🚀 Release Plugin / build-and-release (push) Successful in 1m18s
🏗️ Build Plugin / build (push) Successful in 12m28s
SRG sends times with an offset (e.g. 13:55+02:00). They are stored as
DateTime, which deserialisation converts to server-local time, and two
places then wrote that straight into text: the "[dd.MM HH:mm]" prefix
on upcoming livestream names and the timestamp in recording file names
(DateTime.Now). On a server running in UTC both were two hours behind
Swiss time, e.g. a qualifying starting at 13:55 was listed as 11:55.

A new "Display Time Zone" setting (IANA id, e.g. Europe/Zurich) now
decides the zone for both; empty keeps the server's zone, and an
unknown id falls back to it rather than breaking the listing.
Utilities/DisplayTime does the conversion.

Also fixes PremiereDate on upcoming livestreams, which was set to that
server-local value although Jellyfin expects UTC. It was only correct
on UTC servers; it is now converted, like the other channel items.

Verified on simulated UTC and Europe/Paris servers: the same instant
gives 11:55 / 13:55 / 07:55 for server zone / Europe/Zurich /
America/New_York, and PremiereDate is 11:55 UTC on both.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
v1.3.0
2026-09-25 19:29:05 -04:00
Gitea Actions 536fef85a8 Nightly: 1.0.20260924.216 (3c321b4) 2026-09-24 03:01:30 +00:00
dtourolleandClaude Opus 5.5 3c321b4036 ci: run on any runner, amd64 or arm64
🧪 Test Plugin / test (push) Successful in 13m13s
Nightly Build / nightly-build (push) Successful in 1m35s
🏗️ Build Plugin / build (push) Successful in 12m26s
The builder image is now multi-arch (linux/amd64 + linux/arm64, pushed
as srfplay-builder:latest after building all three plugin zips in each
variant), so jobs no longer need an amd64 host. runs-on moves from
linux/amd64 to ubuntu-latest, which draco-x86, freebox and oracle-a1
all carry, so a job no longer waits behind long jobs on draco while
the ARM runners sit idle.

.gitea/runner/cloud-init.yaml sets up such a runner on an Oracle Cloud
Always Free Ampere VM (Ubuntu 24.04): Docker, act_runner registered
instance-wide with the instance's label set, and a weekly image prune.
The registration token and the optional console password hash are
placeholders here and must be filled in locally before use.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-24 03:58:55 +02:00
Gitea Actions 6822ea7202 Update manifest.json for version 1.2.1 2026-09-24 01:16:46 +00:00
Gitea Actions 8a5223b960 Nightly: 1.0.20260924.212 (db9461c) 2026-09-24 01:14:34 +00:00
dtourolleandClaude Opus 5.5 db9461cf59 ci: read the zip list with cut, not a bash-only IFS
🏗️ Build Plugin / build (push) Successful in 1m41s
Nightly Build / nightly-build (push) Successful in 1m18s
🧪 Test Plugin / test (push) Successful in 46s
🚀 Release Plugin / build-and-release (push) Successful in 1m26s
The upload loop used IFS=$'\t', but the job steps run under /bin/sh,
which is dash in the builder image. dash does not expand $'\t', so IFS
became the characters $, \ and t and every path was split on "t":
"artifacts/srfplay_1.2.0.9.zip" reached curl as "s/srfplay_...", which
failed with exit 26 after the release had already been created. This
broke both the v1.2.0 release and the nightly.

cut -f3 is plain POSIX. Checked by running the upload and manifest
steps under the builder image's dash with curl stubbed.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
v1.2.1
2026-09-24 02:15:09 +02:00
dtourolleandClaude Opus 5.5 b0c067ed41 Add a Docker test harness for any Jellyfin version
🏗️ Build Plugin / build (push) Successful in 1m15s
Nightly Build / nightly-build (push) Failing after 1m14s
🧪 Test Plugin / test (push) Successful in 40s
test-image.sh publishes the plugin on the host, bakes it into a stock
jellyfin/jellyfin image via Dockerfile.test, and runs it on :8096, with
optional egress through a LAN gateway (DOCKER_GATEWAY, e.g. the Swiss
VPN box) for geo-blocked streams.

JELLYFIN_TAG (default 12) selects the image and the matching plugin
build: 10.9/10.10 -> net8.0, 10.11 -> net9.0, 12 -> net10.0, with the
generated meta.json targetAbi to match. Images are tagged per version
(srfplay-test:<tag>) so several can coexist.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-24 01:44:34 +02:00
dtourolleandClaude Opus 5.5 582c94f5f9 Build one plugin per Jellyfin generation (10.9, 10.11, 12)
🏗️ Build Plugin / build (push) Successful in 2m27s
Nightly Build / nightly-build (push) Failing after 1m18s
🧪 Test Plugin / test (push) Successful in 43s
🚀 Release Plugin / build-and-release (push) Failing after 1m12s
The single net8.0 build compiled against Jellyfin 10.9.11 still loads on
10.11 and 12, so channels and browsing keep working, but 10.11 changed
APIs in ways that only fail at runtime. A binary audit of the DLL against
the real server assemblies found 9 broken references on both 10.11 and
12 (none on 10.9/10.10):

- TaskTriggerInfo.Type became an enum. GetDefaultTriggers throws, so
  Jellyfin silently gives every SRF task a 24h fallback trigger. The
  recording scheduler therefore ran about once a day and scheduled
  recordings never started.
- ILibraryManager.GetItemList changed its return type: the expiration
  check crashed on every run.
- Jellyfin.Data.Entities.User moved (IUserManager.Users, GetUserData,
  SaveUserData, PlaybackProgressEventArgs.Users): resume cleanup returned
  500 and the playback-stop guard threw on every stop.

Jellyfin 12 also rejects the legacy X-Emby-Token header with an empty
401, which the recordings UI surfaced as "Unexpected end of JSON input".
The pages now send Authorization: MediaBrowser Token="...", verified on
10.9, 10.11 and 12.

The plugin now multi-targets net8.0/net9.0/net10.0 against Jellyfin
10.9.11/10.11.0/12.0.0 (the oldest package of each line, so each DLL
loads on every patch release of it), with JELLYFIN_10_11_OR_GREATER and
JELLYFIN_12_OR_GREATER for the differences. Trigger construction moves
into Utilities/TaskTriggers so the version switch lives in one place.

.gitea/scripts/build-plugins.sh builds one zip per generation. jprm has
no targetAbi flag, so it rewrites build.yaml per flavour and restores
it. Jellyfin installs the highest version whose targetAbi it satisfies,
so the flavour code goes into the last version segment:

  release v1.2.0 -> 1.2.0.9 / 1.2.0.11 / 1.2.0.12
  nightly        -> 1.0.<date>.<run>09 / 11 / 12

The PR, nightly and release workflows use the script and publish one
manifest entry per zip. Verified end to end against a three-entry
manifest: 10.11 installs the .11 build, 12.1 installs the .12 build.
The existing .NET 10 builder image builds all three unchanged.

Supporting changes: the test project multi-targets too, because jprm
publishes the whole solution for one framework at a time, and it drops
its Microsoft.Extensions.Logging 8.0.1 pin, which is a NU1605 downgrade
under the newer Jellyfin packages. CA1873 (new in the .NET 10 analyzers)
is silenced beside CA1848. The release manifest step checks out
origin/master like the nightly does since 7e1973a.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
v1.2.0
2026-09-24 01:42:38 +02:00
Gitea Actions dc2dd09e49 Update manifest.json for version 1.1.2 2026-09-08 17:31:01 +00:00
Gitea Actions 3cbbd20e71 Nightly: 1.0.20260908.201 (d0d5d06) 2026-09-08 17:28:03 +00:00
dtourolleandClaude Opus 5 d0d5d06a5e ci: move builder image to the .NET 10 SDK
🏗️ Build Plugin / build (push) Successful in 1m36s
Nightly Build / nightly-build (push) Successful in 1m35s
🧪 Test Plugin / test (push) Successful in 1m8s
🚀 Release Plugin / build-and-release (push) Successful in 1m40s
Jellyfin 12.0.0 targets net10.0, and the .NET 8 SDK refuses to even restore
a project that lists net10.0 among its TargetFrameworks (NETSDK1045) -- so
the multi-targeted net8.0;net10.0 build that will produce one plugin DLL per
Jellyfin generation cannot start until the builder image moves first.

Verified as a drop-in against the current net8-only master, inside the image:
restore + build are clean (0 errors, 0 warnings) and jprm produces the same
two-file zip as before. Analyzer levels still track each TFM, so the net8.0
leg stays warning-free; CA1873 will only need silencing on the net10.0 leg
once multi-targeting lands.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
v1.1.2
2026-09-08 19:24:21 +02:00
Gitea Actions 97b644a3b4 Nightly: 1.0.20260903.198 (699b543) 2026-09-03 19:09:41 +00:00
dtourolle 699b5432b9 Merge PR #2: the nightly manifest is edited on a stale master
🏗️ Build Plugin / build (push) Successful in 1m30s
Nightly Build / nightly-build (push) Successful in 1m45s
🧪 Test Plugin / test (push) Successful in 1m6s
2026-09-03 18:48:41 +00:00
dtourolleandClaude Opus 5 7e1973aca7 fix(ci): the nightly manifest is edited on a stale master
🏗️ Build Plugin / build (pull_request) Successful in 3m1s
🧪 Test Plugin / test (pull_request) Successful in 45s
`git checkout master` after `git fetch origin master` switches to the
LOCAL master -- the one actions/checkout left at this run's own SHA --
not the ref just fetched. A nightly build takes long enough that master
has usually moved by the time it finishes, so the manifest gets its new
entry prepended to a stale copy and the push is rejected:

    ! [rejected]  master -> master (non-fast-forward)

Run 1045 failed this way, and the log is unambiguous about it: "Your
branch is behind 'origin/master' by 1 commit, and can be fast-forwarded"
appears one line before the commit that could not be pushed.

`checkout -B master origin/master` is the fix, and it is right rather
than merely convenient. This step appends one version entry to the
manifest as it stands on master, so the base it edits has to be master.
Editing the copy this build happened to start from and then forcing it
through would silently drop whatever landed in between.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-03 20:36:09 +02:00
Gitea Actions 47bf506dc6 Update manifest.json for version 1.1.1 2026-08-12 16:59:31 +00:00
dtourolleandClaude Opus 5 390146e8d4 Clean up stale Continue Watching entries
🏗️ Build Plugin / build (push) Successful in 1m43s
🧪 Test Plugin / test (push) Successful in 34s
🚀 Release Plugin / build-and-release (push) Successful in 51s
Nightly Build / nightly-build (push) Failing after 50s
Livestreams and ended broadcasts accumulated in every user's resume row
because Jellyfin saves a playback position for channel items regardless
of whether the position means anything. A livestream has nothing to
return to, so the entry stayed pinned forever.

Two parts:

- PlaybackResumeGuard, an IHostedService on ISessionManager.PlaybackStopped.
  Jellyfin saves the resume point before raising the event, so the guard
  zeroes it afterwards for livestreams. Stops new entries at the source.
- ResumeCleanupService plus a daily 4 AM task (after the 3 AM expiration
  check) for the existing backlog. Clears livestreams, resume points older
  than N days, positions under N seconds and playback past N% of runtime,
  each threshold configurable.

Only plugin-owned items are touched, matched by the SRF provider ID with a
fallback to the owning channel ID so recordings are covered too. Clearing
sets PlaybackPositionTicks to 0 and leaves Played false: nothing is deleted
and the item stays unwatched.

Config page gains the thresholds plus "Clean Up Stale Entries Now" and
"Clear All SRF Play Entries" buttons, backed by MaintenanceController
under RequiresElevation.

Also folds the duplicated urn.Contains("livestream") check in
MediaSourceFactory and RecordingService into UrnHelper.IsLivestreamUrn.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
v1.1.1
2026-08-12 18:55:41 +02:00
Gitea Actions a9db0aa09c Nightly: 1.0.20260627.189 (7c81ef9) 2026-06-27 13:46:17 +00:00
dtourolle 7c81ef94ca fix Start stream 3 seconds behind edge
🏗️ Build Plugin / build (push) Successful in 33s
Nightly Build / nightly-build (push) Successful in 44s
🧪 Test Plugin / test (push) Successful in 29s
2026-06-27 15:44:56 +02:00
Gitea Actions f715130302 Update manifest.json for version 1.1.0 2026-06-27 09:33:05 +00:00
Gitea Actions affc87bd38 Nightly: 1.0.20260627.185 (1101385)
🚀 Release Plugin / build-and-release (push) Successful in 31s
v1.1.0
2026-06-27 09:30:57 +00:00
dtourolle 1101385107 Really fix CI
🏗️ Build Plugin / build (push) Successful in 36s
Nightly Build / nightly-build (push) Successful in 43s
🧪 Test Plugin / test (push) Successful in 28s
2026-06-27 11:29:32 +02:00
dtourolle 4fc79f39f7 Fix CI
🏗️ Build Plugin / build (push) Successful in 41s
Nightly Build / nightly-build (push) Failing after 35s
🧪 Test Plugin / test (push) Successful in 30s
2026-06-27 11:23:53 +02:00
dtourolle 5875f81b9b fix correct guid
🏗️ Build Plugin / build (push) Successful in 42s
Nightly Build / nightly-build (push) Failing after 35s
🧪 Test Plugin / test (push) Successful in 28s
2026-06-27 11:18:48 +02:00
dtourolle cedef6d6aa Add nightly job
🏗️ Build Plugin / build (push) Successful in 29s
Nightly Build / nightly-build (push) Has been cancelled
🧪 Test Plugin / test (push) Has been cancelled
2026-06-27 11:17:57 +02:00
dtourolle 4b5d7e2a7f info add github cross-login info 2026-06-27 11:17:57 +02:00
Gitea Actions 8281960f0b Update manifest.json for latest build (7a719ee) 2026-06-27 09:01:57 +00:00
dtourolle 7a719ee4ac Feature: All bussiness units get a tile
🏗️ Build Plugin / build (push) Successful in 43s
Latest Release / latest-release (push) Successful in 42s
🧪 Test Plugin / test (push) Successful in 29s
2026-06-27 11:00:07 +02:00
dtourolle 5667c2e12f Cache manageent for bussines units 2026-06-27 09:34:07 +02:00
Gitea Actions fef1bd6b17 Update manifest.json for version 1.0.32 2026-06-27 07:16:38 +00:00
Gitea Actions 763217c43d Update manifest.json for latest build (c2feaae) 2026-06-27 07:15:27 +00:00
dtourolle c2feaae89c Fix really fix redirect
🏗️ Build Plugin / build (push) Successful in 29s
Latest Release / latest-release (push) Successful in 47s
🧪 Test Plugin / test (push) Successful in 28s
🚀 Release Plugin / build-and-release (push) Successful in 43s
v1.0.32
2026-06-27 09:14:07 +02:00
Gitea Actions 35b103c056 Update manifest.json for version 1.0.31 2026-06-27 06:54:02 +00:00
Gitea Actions 7af1d9b8f4 Update manifest.json for latest build (10a76f8) 2026-06-27 06:52:52 +00:00
dtourolle 10a76f8d45 Fix settings no longer redirect.
🏗️ Build Plugin / build (push) Successful in 1m16s
Latest Release / latest-release (push) Successful in 42s
🧪 Test Plugin / test (push) Successful in 27s
🚀 Release Plugin / build-and-release (push) Successful in 42s
v1.0.31
2026-06-27 08:50:49 +02:00
Gitea Actions a39a10636b Update manifest.json for version 1.0.30 2026-05-03 16:45:02 +00:00
Gitea Actions 029fb78049 Update manifest.json for latest build (729f82b) 2026-05-03 16:39:53 +00:00
dtourolle 729f82b26d More tizen based changes
🏗️ Build Plugin / build (push) Successful in 56s
Latest Release / latest-release (push) Successful in 2m28s
🧪 Test Plugin / test (push) Successful in 52s
🚀 Release Plugin / build-and-release (push) Successful in 1m1s
v1.0.30
2026-05-03 18:36:26 +02:00
Gitea Actions aad0c21d4b Update manifest.json for version 1.0.29 2026-05-03 16:07:24 +00:00
Gitea Actions 7a52b3da3b Update manifest.json for latest build (80598ea) 2026-05-03 16:05:38 +00:00
dtourolle 80598ea8cb Fix CI
🏗️ Build Plugin / build (push) Successful in 2m40s
Latest Release / latest-release (push) Successful in 1m22s
🧪 Test Plugin / test (push) Successful in 46s
🚀 Release Plugin / build-and-release (push) Successful in 1m1s
v1.0.29
2026-05-03 17:10:46 +02:00
dtourolle 24f53ef13e Add support for Tizen via transcoding
🏗️ Build Plugin / build (push) Failing after 15m44s
Latest Release / latest-release (push) Has been cancelled
🧪 Test Plugin / test (push) Has been cancelled
🚀 Release Plugin / build-and-release (push) Failing after 3m23s
v1.0.28
2026-05-03 10:41:27 +02:00
Gitea Actions 86b22c69d7 Update manifest.json for latest build (8ffa0a0) 2026-03-07 17:41:15 +00:00