Protected tags API wildcards broken
Summary
After upgrading gitlab we noticed that the protected API endpoint is no longer working as intended.
Steps to reproduce
Create a protected tag on a repo and use the wildcards on the API endpoint.
Example Project
https://gitlab.com/tvlooy/foobar
What is the current bug behavior?
Using wildcards in the API returns 404's.
https://gitlab.com/api/v4/projects/45339514/protected_tags
-> ok: lists 2 tags
https://gitlab.com/api/v4/projects/45339514/protected_tags/1.0.0
-> ok: returns 1 tag
https://gitlab.com/api/v4/projects/45339514/protected_tags/1.0.*
https://gitlab.com/api/v4/projects/45339514/protected_tags/*.0.0
https://gitlab.com/api/v4/projects/45339514/protected_tags/*
-> NOK: these return 404's instead of results
What is the expected correct behavior?
Using wildcards in the API should return tags.
https://gitlab.com/api/v4/projects/45339514/protected_tags/1.0.*
https://gitlab.com/api/v4/projects/45339514/protected_tags/*.0.0
https://gitlab.com/api/v4/projects/45339514/protected_tags/*
This used to work and is still a documented feature https://docs.gitlab.com/ee/api/protected_tags.html
Results of GitLab environment info
We noticed since upgrading from 15.10.1-ce.0 to 15.10.2-ce.0. We now run 15.10.3-ce.0 where the bug is still present.
@gitlab-bot label api typebug
Edited by Tom Van Looy