# ECP-0074: Archive HLS Engine Selection For Chromium

Status: Implemented

## Context

Archive mode currently chooses native HLS whenever `video.canPlayType("application/vnd.apple.mpegurl")` is non-empty.

Chromium may report support but still fail to actually play event-style fMP4 HLS in this path, leaving the player stuck at `readyState = 0`.

## Decision

Use native HLS only on Safari/iOS user agents. For all other browsers (including Chromium), force `hls.js` playback.

## Why

- Restores archive playback on Chrome/Chromium.
- Keeps Safari native path where it is reliable.
- Preserves a single URL and UI flow (`/api/archive/.../master.m3u8`).

## Alternatives considered

- Keep `canPlayType` as the only gate. Rejected because Chromium reports support but fails event-style playback.
- Force `hls.js` for all browsers including Safari. Rejected because Safari native playback is already reliable and simpler.

## Rollout / teardown

- Deploy UA-gated engine selection in web app and validate archive playback on Chromium and Safari.
- Teardown by reverting to the previous generic `canPlayType` gate.

## Reversibility

Revert the UA gate and return to the previous `canPlayType`-only check.
