You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(gui): retain Subsonic covers for current rows - #1165
Large Subsonic lists could lose their first cover references at the registry's 4096-entry limit.
Keep the covers used by the latest rows on each GUI channel. Release a cover once no current channel uses it.
An older channel revision can only reuse references that are still active.
Testing
Ran on macOS arm64 after rebasing onto upstream 536f080, with isolated app and temporary paths.
$ GUI_FEATURES=telemetry,gui,streaming,discord-rpc,self-update,scripting,mcp-server,mpris,local-files,subsonic,internet-radio,youtube,qobuz,audio-viz,audio-viz-cpal
$ cargo fmt --all --check
Exit 0. No output.
$ cargo clippy --locked --no-default-features --features telemetry,tui -- -D warnings
Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.36s
$ cargo clippy --locked -- -D warnings
Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.42s
$ cargo check --locked --no-default-features --features "$GUI_FEATURES"
Finished `dev` profile [unoptimized + debuginfo] target(s) in 4.06s
$ cargo clippy --locked --no-default-features --features "$GUI_FEATURES" -- -D warnings
Finished `dev` profile [unoptimized + debuginfo] target(s) in 4.02s
$ cargo test --locked --no-default-features --features "$GUI_FEATURES" gui::covers::tests::
test result: ok. 8 passed; 0 failed; 0 ignored; 0 measured; 2493 filtered out; finished in 0.05s
$ cargo test --locked --no-default-features --features telemetry,tui
test result: ok. 2050 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 3.70s
$ cargo test --locked --no-default-features --features "$GUI_FEATURES"
test result: FAILED. 2466 passed; 5 failed; 30 ignored; 0 measured; 0 filtered out; finished in 6.73s
$ cargo test --locked --no-default-features --features "$GUI_FEATURES" typescript_bindings_are_written_to_the_frontend_source_tree
test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 2500 filtered out; finished in 0.32s
The full runs fail only the cli::plugin::tests git-transport tests: the local Homebrew git 2.51.1 answers transport 'ext' not allowed. They fail the same way on upstream 536f080 here and are not touched by this change.
The regression failed with test-only changes on upstream 810e19d.
The bindings test produced no diff.
The test-directory cleanup case passed on its own and in the GUI suite rerun.
No actionable comments were generated in the recent review.
Walkthrough
The cover registry now tracks references by GUI channel and revision instead of evicting entries at a global limit. Current messages update channel references, while stale messages cannot register new covers or replace stored channel state.
Changes: GUI cover reference retention
Layer / File(s)
Summary
Channel-scoped cover registry src/gui/covers.rs
The registry stores each channel's revision and referenced cover IDs. The global cover-count limit is removed.
Revision-aware rewriting and reference lifecycle src/gui/covers.rs, changelog.d/fixed/gui-subsonic-cover-references.md
Rewriting tracks cover IDs by message revision. Replacing channel state releases references that no other channel uses. Tests cover large lists, shared references, and stale revisions. The changelog records the large-list cover behavior.
LargeModGames/spotatui#1006: Introduced the GUI cover proxy and the reference registry that this change updates.
Merge Risk: Minimal · up to eb4c0
This change keeps covers for the current rows of large Subsonic lists from being dropped when the registry fills up. No concrete merge-blocking risk was found, and the new tests cover the changed behavior.
Pre-merge checks: 4
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title "fix(gui): retain Subsonic covers for current rows" uses a conventional-commit prefix (fix) with a scope (gui), which matches the required format. It is concise and imperative. The changeset…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title "fix(gui): retain Subsonic covers for current rows" uses a conventional-commit prefix (fix) with a scope (gui), which matches the required format. It is concise and imperative. The changeset matches the title: src/gui/covers.rs now retains cover references per channel and revision so that covers for current rows survive the former 4096-entry eviction, and the changelog entry documents the same fix.
Finishing Touches
Generate unit tests (beta)
Commit to this branch
Create a new PR
Simplify code
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Large Subsonic lists could lose their first cover references at the registry's 4096-entry limit.
Keep the covers used by the latest rows on each GUI channel. Release a cover once no current channel uses it.
An older channel revision can only reuse references that are still active.
Testing
Ran on macOS arm64 after rebasing onto upstream
536f080, with isolated app and temporary paths.The full runs fail only the
cli::plugin::testsgit-transport tests: the local Homebrew git 2.51.1 answerstransport 'ext' not allowed. They fail the same way on upstream536f080here and are not touched by this change.The regression failed with test-only changes on upstream
810e19d.The bindings test produced no diff.
The test-directory cleanup case passed on its own and in the GUI suite rerun.
Additional notes
This follows up on the GUI cover proxy. #1006
The checks used local fixtures. Live Subsonic and interactive GUI sessions were unverified.
Summary by CodeRabbit