sp-dev-docs icon indicating copy to clipboard operation
sp-dev-docs copied to clipboard

SharePoint Search SortList Random Seed stops working

Open natpdeee opened this issue 2 years ago • 2 comments

Target SharePoint environment

SharePoint Online

What SharePoint development model, framework, SDK or API is this about?

SharePoint REST API

Developer environment

Windows

What browser(s) / client(s) have you tested

  • [ ] 💥 Internet Explorer
  • [X] 💥 Microsoft Edge
  • [X] 💥 Google Chrome
  • [ ] 💥 FireFox
  • [ ] 💥 Safari
  • [ ] mobile (iOS/iPadOS)
  • [ ] mobile (Android)
  • [ ] not applicable
  • [ ] other (enter in the "Additional environment details" area below)

Additional environment details

No response

Describe the bug / error

We used the random seed as specified by Microsoft's documentation here to apply a random sorting of the query results. It used to work and it stops working recently. I tested this in multiple tenants and I always get the same error message.

image

Steps to reproduce

  1. Use Postman / other network tool and create a Post request to <tenantname.sharepoint.com>/_api/search/postquery
  2. Make sure that SortList contains [random:seed=5432]
  3. Check the response

Expected behavior

Search will return results in a random order

natpdeee avatar Jun 27 '22 00:06 natpdeee

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

ghost avatar Jun 27 '22 00:06 ghost

We noticed a very same problem (with [random:seed=1234] syntax in sortlist) a few weeks ago (on 23rd of May) on some of our tenants (not all). Issue was fully persistent for few weeks but quite recently it is back functional, seems like they must have act on it. Maybe patch for your tenant is on its way too. We have planned to report it on support but had no time for mailing we just put it on the 'for observation' list and have added work around in our code so once this issue appears again the impact for users shouldn't be critical. Interesting to see how many users knows about this search capability.

dev-a11y avatar Jun 27 '22 17:06 dev-a11y