Skip to content

[Bug] Unplayed progress filter is dropped after the first page of results #421

Closed

Description

@Alfagun74

Reported on Discord by larva.

Describe the bug
On a library of ~600 games where 200 are marked completed, filtering the library by unplayed returns the correct games on the first page (50), but loading further pages starts including games marked completed. The header shows a correct 50/400 at first, then reaches 600/400 once the whole library is scrolled through.

Filtering by the completed tag does not have this problem — the filter holds for all loaded pages. Games with recorded playtime that are now marked completed also show up, so this is not a playtime artifact.

Reproduced on the web UI of a TrueNAS-hosted server and on the standalone Windows client, both logged in as the only admin account.

To Reproduce

  1. Library with ~600 games, 200 of them marked completed (400 unplayed).
  2. Open the library and filter by state: unplayed.
  3. The first page of 50 games is correct.
  4. Scroll down to load more pages.
  5. Completed games appear, and the loaded count exceeds the reported total (600/400).

Expected behavior
The unplayed filter applies to every page: only unplayed games are listed and the loaded count never exceeds the total.

Possible cause
In GamesController.findGames, the UNPLAYED case deletes progresses.state and progresses.user.id from query.filter and uses a pre-queried excludedGameIds where condition instead. nestjs-paginate serializes query.filter into links.next, so the filter is missing from the next-page URL. The follow-up request has no progresses.state, the pre-query branch never runs, where is undefined, and the page is unfiltered (meta.totalItems also jumps back to the full library size). Filters that remain in query.filter (e.g. the completed tag) are preserved in the link, which matches the reporter's observation that only the unplayed filter breaks.

Both clients follow links.next (useGames.loadMore in the web frontend and ViewModel.NextPage in the Windows client), which is why the behaviour is identical on both.

Workaround currently used
Splitting the library into "finished"/"unfinished" install folders and using the search bar (which matches titles and install paths). This is per-library only, so it doesn't help multiple user profiles that need to browse by the completed/unplayed markers.

Activity

  1. Alfagun74 commented on Nov 5, 2026

    @Alfagun74
    ContributorAuthor

    Fixed in 17.2.1.

    GET /api/games dropped the progress filters from the query before handing it to nestjs-paginate, and nestjs-paginate builds the pagination links from that query. links.next therefore had no unplayed filter, so every page after the first came back unfiltered, which also explains the count reaching 600/400. The resolved filters are now written back into the pagination links and into meta.filter, so the unplayed filter holds for all pages in both the web UI and the desktop client.

    Thanks for the detailed report.

  2. moved this from 📃 New Issues to ✅ Closed in GameVault: Public Roadmapon Nov 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    🎛️ serverThere are things to do on the server🪲 bugSomething isn't working

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions