Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Editors getting a 403 from REST API when attempting to search author list in a post #30360

Closed
orenwolf opened this issue Mar 30, 2021 · 5 comments
Labels
REST API Interaction Related to REST API [Type] Regression Related to a regression in the latest release

Comments

@orenwolf
Copy link

Description

I'm betting related to #26476 and #26554 - editors cannot pull the full list of authors (we have hundreds on our site) - they receive:

{
  "code": "rest_forbidden_context",
  "message": "Sorry, you are not allowed to list users.",
  "data": {
    "status": 403
  }
}

..and subsequently can't search for a username beyond what was initially loaded.

Step-by-step reproduction instructions

While all steps may not be required, this is what works:

As an Editor, on a site where more Authors exist than will fit in the dropdown:

  • Edit an existing post
  • Go to the Author dropdown, to change the user. Type in the name of an existing Author that did not load in the Author dropdown due to truncation.
  • Author search will not complete.

Expected behaviour

Author search should take place, and dropdown should now include authors matching the search term

Actual behaviour

Nothing happens. Author list does not update.

Screenshots or screen recording (optional)

Screen Shot 2021-03-22 at 10 25 10 PM

(truncated at "C", searching for an author name of "dave" will not result in a search or an update)

WordPress information

  • WordPress version: 5.7
  • Gutenberg version: As included in WP 5.7
  • Are all plugins except Gutenberg deactivated? Nope.
  • Are you using a default theme (e.g. Twenty Twenty-One)? Nope.

Device information

  • Device: attempted in FF / Safari, current version, OSX Big Sur Desktop

Happy to provide further details. Thanks!

@cjyabraham
Copy link

This fails for me as well. I'm having to upgrade Editors to be Administrators in order for them to do their work which is not a great workaround. It'd be great to not have to give them those permissions once this is fixed.

@marcorroma
Copy link

I also have the same problem with the editors of my site.
I fixed it momentarily by reverting to version 5.6.2.

@skorasaurus skorasaurus added [Type] Regression Related to a regression in the latest release and removed [Type] Bug An existing feature does not function as intended labels May 23, 2021
@Mamaduka
Copy link
Member

Hi, @orenwolf

I'm no longer able to reproduce this issue in WP 5.7.2.

I fixed a similar issue in April. PR #30218.

@cjyabraham
Copy link

This issue is fixed for me in v 5.7.2.

@Mamaduka
Copy link
Member

Mamaduka commented Jun 4, 2021

Hello, @orenwolf

I'm no longer able to reproduce this. Like @cjyabraham mentioned, this should be fixed in WP 5.7.2.

I am going to close the issue. Feel free to reopen it if you're still experiencing the errors.

@Mamaduka Mamaduka closed this as completed Jun 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
REST API Interaction Related to REST API [Type] Regression Related to a regression in the latest release
Projects
None yet
Development

No branches or pull requests

5 participants