Random filter does not respect pagination

Created on 12 December 2017, about 7 years ago
Updated 9 August 2023, over 1 year ago

Sorting a view by "Global: Random" is currently incompatible with pagination.

Steps to reproduce:

  1. Install Drupal core
  2. Install the Devel Generate module from the Devel project
  3. Use Devel Generate to generate 50 article nodes.
  4. Create a View of article node teasers. In the sort criteria, sort by "Global: Random".
  5. In the paging settings, make sure the view is paged. I found it convenient to use a mini pager with 3 items.

Expected behavior:
Every page of the view results should be a partial result of the same random list. Each page should list the correct number (in my case, 3) of unique nodes until we reach the last page, never repeating a node.

What actually happens:
Each page of the view appears to re-randomize the view results, resulting in repeated nodes on some pages.

🐛 Bug report
Status

Active

Version

11.0 🔥

Component
Views 

Last updated about 1 hour ago

Created by

🇧🇪Belgium Pascal-

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024