Cannot set explicit group permission that matches inherited permission
Summary
When a user is a member of a group, they cannot be added explicitly to a subgroup with the same permission level that is inherited. This becomes a problem when some features of GitLab (by design or by issue) may require explicit membership of a group.
This behavior worked as expected in prior versions of GitLab EE, and broke recently (possibly broken in 11.6?). My team had been using it as a workaround to an issue that required explicit permissions on subgroups.
Steps to reproduce
- Create a group.
- Add a user to the group with the Developer role.
- Create a subgroup in that group.
- Attempt to add the same user to the subgroup as a Developer.
The request is successful, but the permissions on the group do not change.
Example Project
https://gitlab.com/asoborov-test
In this group, I am unable to add the second user to the subgroup test-2
explicitly as a Developer.
What is the current bug behavior?
When performing reproduction steps, the request is successful, but the permissions on the group do not change.
What is the expected correct behavior?
The user should be able to get explicitly added to the group, replacing the inherited permission with an explicit one at the subgroup level.
Output of checks
This bug happens on GitLab.com.