Skip to content

refactor(catalog): resolve every library scope through AccessFilter.LibraryScope - #2006

Merged
Quick104 merged 3 commits into
Silo-Server:mainfrom
Rhainland:refactor/catalog-access-library-scope
Oct 7, 2026
Merged

Quick104 merged 3 commits into
Silo-Server:mainfrom
Rhainland:refactor/catalog-access-library-scope

Conversation

@Rhainland

@Rhainland Rhainland commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Problem

Related issue: N/A
Validation tasks: none changed (the refactor reaches #193 S1, S3 and #1196 C1; their behavior is unchanged)

#1953 and #2005 have merged. The diff is two commits: refactor(catalog): resolve every library scope through AccessFilter.LibraryScope and fix(sections): match nothing when a section's fetch scope is empty.

The rule for which libraries a read may touch was implemented several times: catalog browse and search, the preview-page plan, Recently Added TV, playable targets, discovery and home sections, server collections, the calendar, and Jellyfin compat each had their own copy. The rule is: the requested libraries (none means all), limited to the viewer's allowed libraries, minus disabled libraries, and an empty result matches nothing. #1953 and #2005 fixed copies that read an empty result as "no library filter". With one implementation, a future change can't fix one copy and leave the others wrong.

The refactor has no intended behavior change. The second commit closes one gap: applySectionLibraryScopeToQuery read an empty, non-nil fetch scope as "every library" when the section's query named no libraries. Home sections and Jellyfin compat pass the viewer's allowlist as both the fetch scope and the access filter, so their results don't change. The one caller whose result changes is the v1 admin preview, POST /api/admin/sections/preview with "library_ids": []: a query-based section such as a custom filter now previews nothing instead of every library, which is how collection rails already treated an empty list. The v2 preview turns an empty library_ids into no scope, so it is unchanged.

Approach

AccessFilter.LibraryScope is now the only implementation. It returns the scope and a flag for "nothing survives". Callers that previously used effectiveCatalogLibraryIDs, the effectiveLibraryScope wrapper, the sections fetcher's intersectLibraryIDs, or inline loops now call it, and those helpers are removed.

Some callers also exclude disabled libraries in SQL. They now get a scope that has those libraries removed already. The SQL NOT EXISTS clause still runs and already excluded those rows, so results are the same.

Validation

Evidence

This PR's own commit does not change any response. The visible change in this stack is #2005's: a section whose libraries miss the viewer's scope now returns nothing instead of filling from the viewer's other libraries. #2005's Evidence section shows that change before and after.

The two cases flagged in review give the same responses on #2005's head and on this PR's head: a section whose only library the profile has hidden, and a section or collection rail whose library is outside the viewer's scope. Test library with Movies, TV and Mixed libraries and synthetic files. Home sections "New on TV" (TV library), "New in Movies and TV", "New in Mixed" (Mixed library), and rails for the server collections "TV Classics" (TV library) and "Movie Classics" (Movies library).

Before (3aef85313, head of #2005)

# No TV profile: admin account, TV library hidden
GET /api/v2/home/sections -> 200
  New in Movies and TV   Charade, His Girl Friday, Night of the Living Dead, The General
  New in Mixed           Open Road, Detour, The Pilot Light
  TV Classics rail       (no items)
  Movie Classics rail    Charade, The General
GET /api/v2/home/sections/<New on TV>/items -> 404 Not found
GET /api/v2/home/sections/<New in Movies and TV>/items -> 200 Charade, His Girl Friday, Night of the Living Dead, The General
GET /api/v2/home/sections/<New in Mixed>/items -> 200 Open Road, Detour, The Pilot Light
GET /api/v2/home/sections/<TV Classics rail>/items -> 200 (no items)
GET /api/v2/home/sections/<Movie Classics rail>/items -> 200 Charade, The General
GET /api/v2/collections/server -> 200 Movies: Movie Classics (2 items)

# Viewer profile: account limited to Movies and TV, TV library hidden
GET /api/v2/home/sections -> 200
  New in Movies and TV   Charade, His Girl Friday, Night of the Living Dead, The General
  TV Classics rail       (no items)
  Movie Classics rail    Charade, The General
GET /api/v2/home/sections/<New on TV>/items -> 404 Not found
GET /api/v2/home/sections/<New in Movies and TV>/items -> 200 Charade, His Girl Friday, Night of the Living Dead, The General
GET /api/v2/home/sections/<New in Mixed>/items -> 404 Not found
GET /api/v2/home/sections/<TV Classics rail>/items -> 200 (no items)
GET /api/v2/home/sections/<Movie Classics rail>/items -> 200 Charade, The General
GET /api/v2/collections/server -> 200 Movies: Movie Classics (2 items)

# Jellyfin compat, Viewer account
GET /Users/{id}/Views -> Collections, Movies
GET /Users/{id}/Items?ParentId=<Collections> -> (none)
GET /Users/{id}/Items?ParentId=<Movies> -> Charade, His Girl Friday, Night of the Living Dead, The General
GET /Users/{id}/Items?Recursive=true -> Charade, His Girl Friday, Night of the Living Dead, The General

After (cdba55a1f, this PR's head)

# No TV profile: admin account, TV library hidden
GET /api/v2/home/sections -> 200
  New in Movies and TV   Charade, His Girl Friday, Night of the Living Dead, The General
  New in Mixed           Open Road, Detour, The Pilot Light
  TV Classics rail       (no items)
  Movie Classics rail    Charade, The General
GET /api/v2/home/sections/<New on TV>/items -> 404 Not found
GET /api/v2/home/sections/<New in Movies and TV>/items -> 200 Charade, His Girl Friday, Night of the Living Dead, The General
GET /api/v2/home/sections/<New in Mixed>/items -> 200 Open Road, Detour, The Pilot Light
GET /api/v2/home/sections/<TV Classics rail>/items -> 200 (no items)
GET /api/v2/home/sections/<Movie Classics rail>/items -> 200 Charade, The General
GET /api/v2/collections/server -> 200 Movies: Movie Classics (2 items)

# Viewer profile: account limited to Movies and TV, TV library hidden
GET /api/v2/home/sections -> 200
  New in Movies and TV   Charade, His Girl Friday, Night of the Living Dead, The General
  TV Classics rail       (no items)
  Movie Classics rail    Charade, The General
GET /api/v2/home/sections/<New on TV>/items -> 404 Not found
GET /api/v2/home/sections/<New in Movies and TV>/items -> 200 Charade, His Girl Friday, Night of the Living Dead, The General
GET /api/v2/home/sections/<New in Mixed>/items -> 404 Not found
GET /api/v2/home/sections/<TV Classics rail>/items -> 200 (no items)
GET /api/v2/home/sections/<Movie Classics rail>/items -> 200 Charade, The General
GET /api/v2/collections/server -> 200 Movies: Movie Classics (2 items)

# Jellyfin compat, Viewer account
GET /Users/{id}/Views -> Collections, Movies
GET /Users/{id}/Items?ParentId=<Collections> -> (none)
GET /Users/{id}/Items?ParentId=<Movies> -> Charade, His Girl Friday, Night of the Living Dead, The General
GET /Users/{id}/Items?Recursive=true -> Charade, His Girl Friday, Night of the Living Dead, The General

Home section lists are trimmed to the five sections above; "New on TV" is left out of both profiles' lists on both builds. The full JSON of all 24 native API responses, for these two profiles and an unrestricted Admin profile, is identical on both builds apart from request IDs in error bodies and the catalog window_cursor, which encodes the request time. Jellyfin compat views and item lists for the admin account are identical as well.

Surface and build: /api/v2/home/sections, /api/v2/home/sections/{id}/items, /api/v2/collections/server, /api/v2/catalog and Jellyfin compat /Users/{id}/Views and /Users/{id}/Items. Before 3aef85313 (head of #2005), after cdba55a1f (PR head), each server on a copy of the same database.

Risks

  • A wide refactor across catalog, sections and Jellyfin compat. Any behavior difference would be a bug in this PR. The end-to-end comparison found none, but it only covers what its fixture exercises.
  • No API or schema change.

Checklist

  • I read and can explain the complete diff.
  • This pull request addresses one concern.
  • The Evidence section shows every change a user can see, or says there is none.

AI Disclosure

  • Harness: Claude Code (running in T3 Code)
  • Tool(s): Claude Code, GitHub CLI
  • Model(s): claude-opus-5-5
  • Involvement: Fully AI-generated, human verified
  • Adversarial review: n/a

Note

Resolve all library access scoping through AccessFilter.LibraryScope

  • Adds a shared AccessFilter.LibraryScope resolver in access_filter.go that combines requested libraries, viewer allowlist, and disabled libraries. It distinguishes unrestricted access (nil) from an explicit empty scope, and covers table-driven tests including input aliasing.
  • Replaces local allowlist/intersection/disabled-ID helpers across the catalog, sections, and jellycompat packages. The largest change is in fetcher.go, where applySectionLibraryScopeToQuery now returns a success flag and most section fetchers short-circuit to empty results when no library scope survives.
  • Behavioral Change: sections, personal collections, editorial spotlights, seasonal/mood sections, direct content folders, and compatibility item loading now return empty results when the effective scope is empty or disjoint, instead of falling back to unrestricted queries. A requested single-library episode-catalog path can now resolve through remaining non-disabled libraries. See applySectionLibraryScopeToQuery in fetcher.go and singleEpisodeCatalogLibraryID in episode_catalog_entries_executor.go.

Macroscope summarized cdba55a.

@silo-kody

silo-kody Bot commented Oct 6, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

@coderabbitai

coderabbitai Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: a9dbcc18-6045-42ad-8f9e-827f5b5778f9
📥 Commits

Reviewing files that changed from the base of the PR and between eafb12b and c499273.

📒 Files selected for processing (2)
  • internal/sections/fetcher.go
  • internal/sections/fetcher_access_test.go

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 2 remain after this review.


📝 Walkthrough

Walkthrough

Library access scope resolution is centralized and applied across catalog queries, collections, sections, and compatibility paths. The changes distinguish unrestricted access from an empty effective scope and add tests for library intersections, disabled IDs, and disjoint collection scopes.

Changes

Library Access

Layer / File(s) Summary
Define the shared library scope contract
internal/catalog/access_filter.go, internal/catalog/access_filter_test.go
AccessFilter.LibraryScope resolves requested, allowed, and disabled library IDs. It distinguishes an unrestricted nil scope from an empty scope. Tests cover ordering, deduplication, and input-slice independence.
Apply library scope to catalog queries
internal/catalog/calendar_repo.go, internal/catalog/discovery_repo.go, internal/catalog/episode_catalog_entries_executor.go, internal/catalog/playable_targets.go, internal/catalog/query_executor.go, internal/catalog/query_executor_access_test.go, internal/catalog/recent_tv.go, internal/catalog/search_cursor.go, internal/catalog/catalog_resolver.go, internal/catalog/catalog_resolver_test.go, internal/catalog/catalog_library_scope_db_test.go, scripts/ci/db-contracts.txt
Catalog access paths use the shared scope to constrain library results or return empty results. Tests cover query behavior across paging modes and access cases.
Resolve saved and collection library scopes
internal/catalog/catalog_resolver.go, internal/catalog/catalog_collection_cursor.go, internal/catalog/catalog_collection_library_scope_test.go
Live collection resolution and collection-source loading use a shared helper to intersect saved and collection library IDs. Disjoint scopes return empty results. Unit and database-backed tests cover these cases.
Apply library scope to sections and compatibility paths
internal/api/handlers/sections.go, internal/sections/fetcher.go, internal/sections/fetcher_access_test.go, internal/jellycompat/batch_loaders.go, internal/jellycompat/content_direct.go
Section queries and compatibility access paths use the shared scope or an explicit match result. Tests cover section scope intersections and empty results.

Priority: ➖ Normal

Estimated code review effort: 3 (Moderate) | ~25 minutes

Change: Bug fix

Possibly related PRs

  • Silo-Server/silo-server#738: Both changes apply disabled-library access rules across catalog, episode, compatibility, and section query paths.

Suggested reviewers: quick104

Merge Risk: ⚪ Minimal · up to c4992

This refactor centralizes library-scope handling and tightens empty-scope behavior, with no concrete defect identified. The author reports tests and an end-to-end comparison with no response differences.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 33 functions across 20 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly and concisely describes the primary change: centralizing library-scope resolution through AccessFilter.LibraryScope.
Description check ✅ Passed The description is directly related to the changeset. It explains the centralized library-scope implementation, affected areas, behavior expectations, validation results, risks, and evidence.
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
⚔️ Resolve merge conflicts 💡
  • Resolve merge conflict in branch refactor/catalog-access-library-scope
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autopilot · 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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Quick104 commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

Silo's pull request guidance changed today (#2016). A PR that changes what a user sees now needs before-and-after evidence in its Evidence section, and a PR with no visible change says Evidence: none, no user-visible change. This PR was opened before the rule existed, so it hasn't had a chance to meet it yet.

Missing here: Needs the line 'Evidence: none, no user-visible change' (this PR's own commit is a refactor with identical responses).

The rules are in Show visible changes, and the PR template shows the Evidence section layout. I've converted this PR to draft for now. Mark it ready for review once the Evidence section is filled in.


Generated by Claude Code

@Quick104
Quick104 marked this pull request as draft October 6, 2026 19:25
@Rhainland
Rhainland marked this pull request as ready for review October 6, 2026 19:28
@silo-kody

silo-kody Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

@macroscopeapp

macroscopeapp Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

The Evidence section says there is no user-visible change, but this PR changes section responses and visibility:

  • internal/sections/fetcher.go: disjoint query/fetch library scopes, and now an empty non-nil fetch scope, return no items instead of falling back to an unscoped query. Add before-and-after API response excerpts for the same section and query, naming the surface and builds or commits.
  • internal/api/handlers/sections.go: configured sections whose libraries are disabled are now omitted from the section list. Add before-and-after API response excerpts for the same profile and section listing, naming the surface and builds or commits.

The reported tests and request-count comparison are not before-and-after response excerpts for these cases. The collection behavior previously mentioned is already in the current base, so it is not part of this diff.

Suggested fix: Add the matching before-and-after API response excerpts under Evidence, with the surface and source builds or commits identified.

Automated check: Macroscope check run agent (gpt-6-luna). Evidence was not reviewed for correctness.

Posted via Macroscope — Visible change evidence

Posted via Macroscope — Visible change evidence

@Rhainland
Rhainland force-pushed the refactor/catalog-access-library-scope branch from c499273 to 148153b Compare October 7, 2026 10:20
@silo-kody

silo-kody Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

…ch scope

Section queries intersected their own library_ids with the fetch's library
set and stored the result. When the two shared no library the intersection
was nil, which the query executor reads as "no library filter", so the
section filled from every library in the viewer's scope instead of none.
An admin previewing a custom filter scoped to one library with library_ids
naming another got every library's items back; a smart collection rail
whose saved libraries a restricted profile cannot reach filled from the
profile's other libraries.

applySectionLibraryScopeToQuery now reports when nothing survives, and
every caller returns an empty section in that case. The editorial
spotlight, seasonal and mood fetchers carried inline copies of the same
switch; they now call the helper too.
…ibraryScope

The rule "requested libraries (none = all), limited to the allowlist, minus
disabled libraries; an empty result matches nothing" lived in
effectiveCatalogLibraryIDs, its effectiveLibraryScope wrapper, and several
hand-rolled copies. AccessFilter.LibraryScope is now the one implementation.

Moved onto it: catalog browse and search access, the preview-page plan and
its episode fast path, the search sort scope, Recently Added TV library
resolution, playable-target file scope, discovery section scope, the
calendar single-library check, server collection access, home section
access filtering, the section query library scope, the collection-rail and
returning-shows section scopes, and the Jellyfin-compat library narrowing
and library listing. intersectLibraryIDs in the sections fetcher is gone.

Callers that also exclude disabled libraries in SQL now receive a scope
without them; the extra NOT EXISTS clause already removed those rows, so
results do not change.
@Rhainland
Rhainland force-pushed the refactor/catalog-access-library-scope branch from 148153b to cdba55a Compare October 7, 2026 10:21
@Rhainland

Copy link
Copy Markdown
Contributor Author

The catalog/collection fail-closed behavior belongs to prerequisite #1953, and the section-intersection fix belongs to #2005. This PR changes the AccessFilter representation and preserves behavior. The current description reports the same-fixture before/after API comparison against the #2005 prerequisite; adding screenshots of ancestor fixes would misattribute their behavior to this refactor.

@Quick104 Quick104 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed head cdba55a1f. I found no code defects. One note below on the only reachable behavior change, plus one PR-body issue that I've already fixed.

PR body (fixed). The body still said to merge after #1953 and #2005 and called the refactor "the last commit", but both prerequisites have merged and the last commit is now fix(sections): match nothing when a section's fetch scope is empty, which the body didn't describe. I updated the Problem section to list both commits and say what the second one changes. The rest of the body is untouched.

Review by Claude Code (claude-opus-5-5).

case libraryID != nil:
def.LibraryIDs = []int{*libraryID}
case libraryIDs != nil:
if len(libraryIDs) == 0 {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Low, informational. No change needed. This is the PR's only reachable behavior change. Before this line, libraryIDs = []int{} with a query that names no libraries left def.LibraryIDs nil, so the query ran unscoped.

Who reaches it:

  • Home sections pass scope.AllowedLibraryIDs as both libraryIDs and filter.AllowedLibraryIDs (loadResolvedHomeSections). Jellycompat passes filter.AllowedLibraryIDs. In both cases the filter already matched nothing, so results don't change.
  • v1 POST /api/admin/sections/preview decodes "library_ids": [] into a non-nil empty slice. For an unrestricted admin previewing a custom-filter section, the result goes from every library to nothing.
  • v2 preview runs adminSectionLibraryIDs, which turns an empty list into nil, so v2 is unchanged.

The new behavior matches collectionRailQueryAccess, which already read an empty fetch scope as no access, so I think it's right. I added this to the PR body because the body said nothing changes.

@Quick104

Quick104 commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Review summary

Reviewed head: cdba55a1f, two commits over main. It is 27 commits behind main but merges cleanly. The merged tree passes go vet and go test for internal/catalog, internal/sections, internal/jellycompat and internal/api/handlers.

Addressed

  • The PR body described the stack from before the merge and left out the second commit. I updated the Problem section. Details are in the review.

Remaining: none blocking. The inline note on applySectionLibraryScopeToQuery is informational.

What I checked

  • Every replaced helper (effectiveCatalogLibraryIDs, effectiveLibraryScope, intersectLibraryIDs, intersectOptionalInts/subtractInts, and the inline loops) against LibraryScope. Several callers now drop disabled libraries from the scope where they used to rely on a later SQL NOT clause. That doesn't change results, for two reasons. First, access.Resolver never sets both lists: it subtracts disabled libraries from AllowedLibraryIDs for restricted viewers and sets DisabledLibraryIDs only for unrestricted ones. Second, every caller that gets a nil scope still applies the disabled clause.
  • singleEpisodeCatalogLibraryID now takes the single-library path when disabled libraries leave one library, for example [3,4] with 4 disabled. It used to take the multi-library path. Both paths exclude the disabled library, so this changes the query plan, not the rows.
  • Macroscope's evidence comment says sectionAllowedByAccess now hides sections whose libraries are disabled. Given the resolver invariant above, that can't happen for a real viewer. With an allowlist, disabled libraries are already gone from it. Without one, the old loop already hid those sections. Its other points describe fix(sections): return nothing when a section's libraries miss the fetch scope #2005, which is now on main.
  • CI is green on this head, including the Go DB, integration and lint jobs. I didn't run the DB-backed tests locally.

Validated features: the body names #193 S1/S3 (Collections — Server) and #1196 C1 (User management / access groups — Server). The changes that reach them preserve behavior, and the author's 2,478-request comparison found no response differences. No re-test is needed beyond the normal hand-off after merge.

User manual: no change. Library visibility rules are unchanged.

Apple / Android: no API or response change, so no client work is needed. Jellyfin compat views and item lists are covered by the author's comparison.

Fit: 9/10 · Readiness: 9/10 — ready

Review by Claude Code (claude-opus-5-5).

@Quick104
Quick104 merged commit 9b08853 into Silo-Server:main Oct 7, 2026
17 checks passed
Quick104 added a commit that referenced this pull request Oct 8, 2026
Conflict resolution:

- internal/userdb: main took SQLite schema v30 for the profile PIN
  revision (#2020). The login-wide sharing migration moves to v31, so a
  store already at main's v30 still runs it.
- internal/catalog, internal/sections: main's fail-closed library scope
  (#1953, #2005, #2006) and this branch fixed the same empty-scope bug.
  The executor and section fetcher keep main's AccessFilter.LibraryScope;
  library collections keep this branch's ResolveLibraryCollectionMembership,
  which already returns nothing when the saved libraries miss the
  collection's own. main's scope test now exercises that resolver.
  narrowLibraryScope no longer needs the helper main removed.
- internal/policy: main's hidden-library output (#2058) and this branch's
  ContentAccessOnly input both declared `hidden`; the input side is
  renamed.
- Home sections (#2043): the admin per-profile card keeps main's row
  list but saves with this branch's override builder and a baseline, so
  like Settings > Home Screen it stores only what changed and untouched
  rows keep following the server. main's duplicate lib/sectionOverrides.ts
  is dropped; EditableSectionRows stays for that card and labels rows with
  rowKindLabel. Settings > Home Screen keeps this branch's page.
- apiv2: keep both sides' services and fixtures; the admin profile
  section settings fixture gains default_title.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants