Project variables inherited from the Group, produces a 404 error when trying to view the Group variable from within the Project CI/CD Settings

What does this MR do and why?

This MR updates the inherited CI/CD variables table. The link to the group's CI/CD settings should only be displayed for users who have permission to navigate to that page. For other users, the static text with a tooltip is rendered.

References

Screenshots or screen recordings

Owner of the group Owner of the subgroup, but not the top-level group Project maintainer
Screenshot_2025-06-18_at_21.36.23 Screenshot_2025-06-19_at_16.38.16 Screenshot_2025-06-18_at_21.36.07

How to set up and validate locally

  1. Create a group and a subgroup, and add a project to the subgroup
  2. Navigate to Group -> Settings -> CI/CD -> Variables and create a group variable
  3. Navigate to Subgroup -> Settings -> CI/CD -> Variables and create a group variable
  4. Navigate to Ptoject -> Settings -> CI/CD -> Variables and view the inherited variables
  5. Verify the group name links to the group's CI/CD settings page for the user who is the owner of the group
  6. Verify the group name is rendered as static text for the user who is not the owner of the group

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #393197 (closed) https://gitlab.com/gitlab-org/gitlab/-/issues/211335

Edited by Anna Vovchenko

Merge request reports

Loading