Shell 7 + 14: wire [notifications.sounds] to NotificationPrefs after both merge #858

Closed
opened 2026-11-18 03:44:06 +00:00 by charles · 0 comments
Owner

Found while building Shell 14 (#806).

Shell 7 (shell-7-platform-settings-shell-keybinds) stores [notifications.sounds] in an opaque carrier, LocalSettings::notification_sounds: Box<StoredNotificationSounds>, "until shell::notif_prefs (Task 14) reads it". Shell 14 adds the typed LocalSettings::notification_prefs: Box<NotificationPrefs> with stored() / apply_stored() in the same shape (master_volume int, disabled bool, one bool switch per sound by the original name: mute, deaf, incoming-ring, ...).

Once both are on shell, one of them has to read the other, or the sound settings are not kept across restarts:

  • either fluxer-platform::settings reads/writes settings.notification_prefs.stored() / apply_stored() directly and the opaque notification_sounds goes away,
  • or persist::load does notification_prefs.apply_stored(notification_sounds.stored()) and persist::reduce copies notification_prefs.stored() back before a save.

The first matches the plan (Task 7 "reads and writes whatever stored() lists"). Neither branch could do it alone because they were built in different waves.

Also: fluxer-devserver does not answer PATCH /users/@me (the mention preference write); against the devserver that write fails and the radio goes back, which is the intended revert behaviour but not a demo of the happy path.

Found while building Shell 14 (#806). Shell 7 (`shell-7-platform-settings-shell-keybinds`) stores `[notifications.sounds]` in an opaque carrier, `LocalSettings::notification_sounds: Box<StoredNotificationSounds>`, "until `shell::notif_prefs` (Task 14) reads it". Shell 14 adds the typed `LocalSettings::notification_prefs: Box<NotificationPrefs>` with `stored()` / `apply_stored()` in the same shape (`master_volume` int, `disabled` bool, one bool switch per sound by the original name: `mute`, `deaf`, `incoming-ring`, ...). Once both are on `shell`, one of them has to read the other, or the sound settings are not kept across restarts: - either `fluxer-platform::settings` reads/writes `settings.notification_prefs.stored()` / `apply_stored()` directly and the opaque `notification_sounds` goes away, - or `persist::load` does `notification_prefs.apply_stored(notification_sounds.stored())` and `persist::reduce` copies `notification_prefs.stored()` back before a save. The first matches the plan (Task 7 "reads and writes whatever `stored()` lists"). Neither branch could do it alone because they were built in different waves. Also: `fluxer-devserver` does not answer `PATCH /users/@me` (the mention preference write); against the devserver that write fails and the radio goes back, which is the intended revert behaviour but not a demo of the happy path.
charles added this to the Desktop shell milestone 2026-11-18 03:44:06 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
charles/fluxer-native#858
No description provided.