Repository navigation
Serve the page with relative addresses so it works under a path prefix - #46
Merged
Merged
Conversation
The page and its scripts asked for /static and /api by absolute path, so behind a proxy that serves WhatsOn from a sub-path (a Home Assistant ingress panel at /api/ingress/whatson/) every request went to the proxy's root instead. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Merged
jpittelkow
added a commit
that referenced
this pull request
Nov 26, 2026
Version files and CHANGELOG for 0.2.9: the page works under a path prefix (#46). After merge, tag `v0.2.9` on the merge commit. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Jeff Pittelkow <6314033+jpittelkow@users.noreply.github.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes and why
WhatsOn asked for its files and the API by absolute path (
/static/...,/api/...). Behind a proxy that serves it from a sub-path, such as a Home Assistant ingress panel at/api/ingress/whatson/, every one of those requests went to the proxy's root, so the page loaded with no styles or scripts.The page now uses relative addresses: a
rel()helper incore.jsused byapi(), a relativethumbUrl, relative links inindex.html, the two direct/api/statusfetches, and the Jellyfin channel thumbnail URL built on the server. Opening WhatsOn at its own address works as before.How it was tested
python scripts/check.pyprints "all checks passed" (tests, guard tests, privacy, JS)tests/test_subpath.py)CHANGELOG.md(Unreleased) updated, if a user would noticeTried on real hardware (TV model and app, or "not tried"): not tried; no TV-side change.
Not tested: the page itself inside a real Home Assistant ingress panel. Requests through a stand-in path-prefix proxy resolved, and the page at its own address loaded with no console errors.
Decisions and docs
ADRs I reviewed for this area (numbers): none cover front-end URLs.
docs/and the README still match the code, or were updated here (docs/configuration.md,docs/testing.md)Security (tick what applies)
X-WhatsOnor host checks, or the check for something already playing on a TVtests/test_guards.py(explain why the rule itself should change)AI use
Checks
🤖 Generated with Claude Code