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

Ramdom users can be added as reviewers via API, while not via UI #32637

Open
AdamMajer opened this issue Nov 25, 2024 · 3 comments · May be fixed by #32642
Open

Ramdom users can be added as reviewers via API, while not via UI #32637

AdamMajer opened this issue Nov 25, 2024 · 3 comments · May be fixed by #32642
Assignees
Labels

Comments

@AdamMajer
Copy link
Contributor

Feature Description

I'm not certain if this is a bug, a feature request or a UI issue.

I would like to add a review that is not a collaborator or member of organization. In the UI, I cannot seem to be able to add them. For example, to

https://demo.gitea.com/test2/repo/pulls/1

I can't add a user "gnuman". But programatically via API this works.

curl -X 'POST' 'https://demo.gitea.com/api/v1/repos/test2/repo/pulls/1/requested_reviewers' ....

Would it be possible to add explicit users to reviews outside of the teams/org? For example, typing a username in the UI should allow that user to be added even if we do not auto-complete users outside of the organizations.

Screenshots

image

@AdamMajer AdamMajer added the type/proposal The new feature has not been accepted yet but needs to be discussed first. label Nov 25, 2024
@wxiaoguang
Copy link
Contributor

IIRC it is by design ..... the reviewers could only be chosen from the candidate list.

The candidate list is constructed by GetReviewers and GetReviewerTeams (with various permission checks)

So if you'd like to relax the check, that would be a new design.

image

@wxiaoguang
Copy link
Contributor

wxiaoguang commented Nov 25, 2024

I can't add a user "gnuman". But programatically via API this works.
curl -X 'POST' 'https://demo.gitea.com/api/v1/repos/test2/repo/pulls/1/requested_reviewers' ....

Maybe there are some inconsistent logics between the API and Web UI (well, it happened a lot ...... bug)

@AdamMajer AdamMajer changed the title Ability to add reviewers outside of Organization in UI Ramdom users can be added as reviewers via API, while not via UI Nov 25, 2024
@AdamMajer
Copy link
Contributor Author

I've just tried this on github, and I also cannot add individual outside of the target organization.. So, yes, I think this can be re-classified as a bug in API then.

@kemzeb kemzeb added type/bug and removed type/proposal The new feature has not been accepted yet but needs to be discussed first. labels Nov 25, 2024
@lunny lunny self-assigned this Nov 25, 2024
@lunny lunny linked a pull request Nov 25, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants