Group issue tracker shows labels from archived projects
Summary
When viewing the issues for a group, all of the labels used within the group are shown. This list includes labels from any projects that have been archived.
Steps to reproduce
- Create a group
- Create a project in the group
- Create an issue with a new label
- Archive the project
- Go to the group issue tracker and observe the labels shown in the dropdown
Example group: https://gitlab.com/groups/archive-label-example/issues
Archived project: https://gitlab.com/archive-label-example/archived1/issues
Expected behavior
Issues from archived projects are not shown, so the labels should not be shown either
Actual behavior
The issue tracker labels dropdown includes those from archived projects.
Relevant logs and/or screenshots
Example group: https://gitlab.com/groups/archive-label-example/issues
Archived project: https://gitlab.com/archive-label-example/archived1/issues
Output of checks
This bug happens on GitLab.com
Results of GitLab application Check
This bug happens on GitLab.com
Results of GitLab environment info
This bug happens on GitLab.com
Possible fixes
(If you can, link to the line of code that might be responsible for the problem)