Files
xtremflow/lib/features
MichaelandClaude Opus 5 51e6d9d693 fix(epg): stop swallowing EPG failures, cap gateway concurrency
getShortEpg ended in `catch (e) { return []; }`, so a 401, a timeout, a
rate-limited panel and a genuinely empty guide all rendered the same
"No Info" label. That made the current problem undiagnosable from the
UI. Failures are now logged with the HTTP status, the Dio error type and
the response shape.

Two concrete causes are handled while we are here:

- Some Xtream panels answer player_api.php with a textual Content-Type.
  Dio then hands back a raw String, and `response.data['epg_listings']`
  threw, landing in the silent catch. The body is now parsed explicitly
  when it arrives as a String.
- The channel grid mounts one EPG provider per visible tile, firing
  ~32 concurrent requests at player_api.php. Many panels rate-limit well
  below that and fail the whole batch. A 3-slot semaphore serialises
  them in small groups.

This does not by itself prove why the guide is empty in production; it
makes the reason visible in the browser console.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-10 22:14:47 +02:00
..