Error toasts show the browser's or server's raw text, with no next step #304

Closed
opened 2026-10-19 12:39:50 -07:00 by rays · 1 comment
Owner

Many error toasts print the exception as given, with nothing about what to do:

  • web/src/player.ts:79-80: 'Playback failed: '+err.message, e.g. "Playback failed: NotSupportedError: The element has no supported sources."
  • web/src/player.ts:34: 'Playback failed: '+d.details (hls.js's internal codes, such as manifestLoadError)
  • web/src/native.ts:168, web/src/events.ts:53 ('Download failed: '+ev.msg)
  • web/src/items.ts:286, web/src/gestures.ts:54: err.message alone
  • every toast(why(e),true): whatever text the API returned, which for a 5xx is the daemon's internal error (crates/ipx/src/web.rs:1259, format!("{:#}", self.error))

Found in an interface review (2026-10-19), by reading every toast(...,true) call.

Fix: say what failed and what to do, in the page's voice ("Unable to play this file. Try downloading it again." / "Unable to reach iPX. Check your connection and try again."), and put the technical detail in the log, not the toast. For a 5xx, a fixed message on the page side, not the server's text.

Many error toasts print the exception as given, with nothing about what to do: - `web/src/player.ts:79-80`: `'Playback failed: '+err.message`, e.g. "Playback failed: NotSupportedError: The element has no supported sources." - `web/src/player.ts:34`: `'Playback failed: '+d.details` (hls.js's internal codes, such as `manifestLoadError`) - `web/src/native.ts:168`, `web/src/events.ts:53` (`'Download failed: '+ev.msg`) - `web/src/items.ts:286`, `web/src/gestures.ts:54`: `err.message` alone - every `toast(why(e),true)`: whatever text the API returned, which for a 5xx is the daemon's internal error (`crates/ipx/src/web.rs:1259`, `format!("{:#}", self.error)`) Found in an interface review (2026-10-19), by reading every `toast(...,true)` call. Fix: say what failed and what to do, in the page's voice ("Unable to play this file. Try downloading it again." / "Unable to reach iPX. Check your connection and try again."), and put the technical detail in the log, not the toast. For a 5xx, a fixed message on the page side, not the server's text.
rays added the bug label 2026-10-19 12:39:50 -07:00
Author
Owner

Fixed in 6ec2c35: api() says 'Unable to reach iPX. Check your connection and try again.' for a lost connection and 'iPX could not do that just now. Try again in a minute.' for a 500 (other statuses keep ipx's own words); a failed play() is put in words and reported to the log, an AbortError ignored; a failed download names its item and its download button. Deployed in ipx-web (1.2.1-dev).

Fixed in 6ec2c35: `api()` says 'Unable to reach iPX. Check your connection and try again.' for a lost connection and 'iPX could not do that just now. Try again in a minute.' for a 500 (other statuses keep ipx's own words); a failed play() is put in words and reported to the log, an AbortError ignored; a failed download names its item and its download button. Deployed in ipx-web (1.2.1-dev).
rays closed this issue 2026-10-19 13:13:46 -07:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: rays/ipx#304