Zoekt multi-match is not always returning requested chunks

Summary

From: #509938 (comment 2330968745)

The search looks like it doesn't match the results being returned. However, the issue is that the chunks are not being returned consistently from the backend.

Steps to reproduce

  1. Enable exact code search
  2. run this search: https://gitlab.com/search?group_id=9970&project_id=278964&repository_ref=master&scope=blobs&search=licensed_and_indexing_enabled&regex=true
  3. Note how many results come back from the first file: ee/app/models/search/zoekt.rb
  4. That file has 6 matches but only 3 show up and no "see more results" button is shown

What is the current bug behavior?

All matches should be shown and displayed to user

What is the expected correct behavior?

Only some matches are returned

Relevant logs and/or screenshots

Possible fixes

Assignee Loading
Time tracking Loading