Repository navigation
webadmin: link raw thermal streams to the live flight viewer - #52
Conversation
The video page could only point a raw thermal (Matroska) slot at desktop tools. Link it to a web viewer that plays the stream from the video port's TLS WebSocket, with the flight path on a map. The viewer defaults to plot.ardupilot.org/video-live/ and is set with WEBADMIN_LIVE_VIEWER_URL or "live_viewer" in webui.json; empty removes the link. The link carries only the address: a viewer password is entered in the viewer.
Previous review (2026-11-25)Automated review note — AI-generated (Claude+Codex), validated against the live diff. Please sanity-check before acting. Reviewed at head This adds a live-viewer link for raw thermal slots. It works and is tested, with two non-blocking points about the default viewer and URL construction. Should fix
Low
Not fully reviewed: the link was not opened in a real browser against a TLS video port, so CSP enforcement and live playback are untested. |
The live viewer has to allow a proxy's host in its Content-Security-Policy, so a default viewer gave other proxies a link to a page that could not connect. The link now appears only when a viewer is configured. A configured viewer URL with a fragment had live= appended inside the fragment, where the viewer does not read it; it is now added to the query.
Previous review (2026-11-27)Automated review note — AI-generated (Claude+Codex), validated against the live diff. Please sanity-check before acting. Reviewed at head This adds a live-viewer link for raw thermal slots and is close to ready, with one low-severity robustness point. Since the last review both earlier points are fixed: there is no default viewer now, and a configured URL keeps its #fragment after the new live= query. Low
Not fully reviewed: the link was not opened in a real browser against a TLS video port, so CSP enforcement, live playback and the viewer password dialog are untested. |
urlsplit() raises on a URL such as https://[bad/, which made the video page fail whenever a raw thermal slot was active.
|
Automated review note — AI-generated (Claude+Codex), validated against the live diff. Please sanity-check before acting. Reviewed at head This adds a live-viewer link for raw thermal slots and has no open findings at head 7718ba2. Since the last review the one Low point is fixed: a malformed Not fully reviewed: the link was not opened in a real browser against a TLS video port, so CSP enforcement, live playback and the viewer password dialog are untested. |
The video page could only point a raw thermal (Matroska) slot at desktop tools. This adds an Open live in the flight viewer link for each slot with an active raw thermal publisher. It opens a web viewer that plays the stream from the video port's TLS WebSocket (
wss://HOST:PORT/), with the flight path on a map and seek back over what it has received.https://plot.ardupilot.org/video-live/. SetWEBADMIN_LIVE_VIEWER_URL, or"live_viewer"inwebui.json, to use another; an empty string removes the link. A value that is not an http(s) URL also gives no link.The viewer is added by ArduPilot/AP_CameraGimbal#84. It needs TLS on the video port, and its Content-Security-Policy must list the proxy's host, so on a proxy it does not list the link opens the viewer and the viewer reports the refusal.
Testing
tests/webadmin/test_video_page.py: the link appears once, on the raw thermal slot only, with the slot's port; the configured viewer is used; an empty or non-http value removes it. The web UI tests pass (339).