"No results were found" for site user list

Continuing the discussion from Why does the user list remain empty?:

Coming up short when searching for advice on troubleshooting this problem. My user list e.g. Discourse Meta is empty for all time groups, with the message “No results were found” for each.


The last post in the topic above suggested there was at one time a potential solution to this issue but the support topic was apparently deleted…

Does anyone have any ideas where to check?

Is this happening on a site that we host? If so, send us a PM about it and we’ll have a look at what is going on.

The suggested solution was to make sure that Sidekiq is running and wait for the daily background job that updates the user list to run - the user list is updated once per day by a background job. If the user list is not getting updated once per day, then there is a problem that will need to be looked at.

No, it’s a self-hosted installation. I did see something about manually kicking off two different sidekiq jobs Jobs::DirectoryRefreshOlder and Jobs::DirectoryRefreshDaily which I did with result OK, but no improvements to the list itself.

Granted, this may have been broken a while, I don’t think anyone was regularly making use of that leaderboard on the particular site in question.

If folks have ideas of what kind of logs could be informative, that could be helpful. It doesn’t seem like a plugin that is breaking rendering with the “No results were found” message, but I could be wrong…


Another small piece of data.

When visiting https://discourse.example.org/directory_items.json?period=all&order=days_visited on a site where I have normal non-admin membership, this API request returns a nice long list of users for me.

On my site with the “No results were found” error (both as an anonymous not-logged in user and as myself with admin rights), the API returns:

  "errors": [
    "You are not permitted to view the requested resource."
  "error_type": "invalid_access"

Does this error happen to ring any bells for anyone that could help me to figure out what is misconfigured on my site?

UPDATE: OK, I’ve officially been around Discourse too long. I forgot there is a site setting enable user directory that was turned off a long time ago. Unsurprisingly, re-enabling it back to its default active state resolved this error. :laughing: