GRI-1962: push the changed playlist to its devices on a media delete #167
No reviewers
Labels
No labels
Area/Backend
Area/Database
Area/Docs
Area/Frontend
Area/Infra
Area/Security
Area/Tests
Area/Tooling
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Lang/Python
Lang/Rust
Lang/Shell
Lang/SQL
Lang/TypeScript
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Routing
Auto
Routing
Hold
Routing
Human
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Grimoirix/grimoire-of-digital-signage!167
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/GRI-1962-push-playlist-on-media-delete"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
DELETE /api/v1/media/{id}?remove_from_playlists=trueremoved the playlist items referencing the deleted media but never pushed the updated playlist to the devices showing it — a screen kept the deleted document on air until some unrelated edit happened to push it a fresh assignment.media::store::delete_removing_playlist_refsnow also returns, inside the same transaction, the distinct playlist ids it detached an item from.media::handlers::delete_mediapushes each of those playlists to its assigned devices through a newplaylists::handlers::push_playlist_to_assigned_devices, the sameMediaManifest/PlaylistPush/TransferOffersequence aPUT .../itemsedit already sends — refactoredreplace_itemsto share the per-device push loop (push_to_assigned_devices) instead of duplicating it a third time.Follow-up to #163 (GRI-1962), field feedback from the product owner after merge (forge #155 comment, 2026-11-13T17:54Z).
Test plan
ws_integration::deleting_media_used_by_an_assigned_playlist_pushes_the_change_to_its_device: a connected device, assigned a playlist with the one item being deleted, receives a freshPlaylistPush(items: []) from the delete itself, no further edit needed.cargo test -p server --test media_integration --test ws_integration --test playlist_integration --test playlist_acceptance_integration -- --include-ignored— 56/56 pass.cargo test -p server --lib— 162/162 pass.cargo clippy -p server --all-targets -- -D warnings— clean.