Skip to content

API: Add 'topics' field to 'project' entity in place of 'tag_list' [RUN ALL RSPEC]

Introduction

In GitLab, a project can have topics and tags (git tags) on its repository. Unfortunately, topics appear in various places under the name tags, which leads to a lot of confusion. As discussed in #328226 (closed), this confusion is to be cleared up. So I submitted the MR !60834 (closed) for that. However, the MR was too big. So I closed the MR and will submit several separate MRs instead.

What does this MR do?

When a project entity was returned via the API, the topics were previously included at the tag_list attribute. As described in the introduction above, this attribute name is not correct.

This MR adds the topics attributes to the project entity (API), whereby the deprecated attribute tag_list remains for the time being for compatibility reasons.

API request Before: response After: response
GET /api/v4/projects/1 {
tag_list: ['topic1', 'topic2'],
...
}
{
tag_list: ['topic1', 'topic2'],
topics: ['topic1', 'topic2'],
...
}

🛠 with at Siemens

/cc @bufferoverflow

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

Does this MR contain changes to processing or storing of credentials or tokens, authorization and authentication methods or other items described in the security review guidelines? If not, then delete this Security section.

  • [-] Label as security and @ mention @gitlab-com/gl-security/appsec
  • [-] The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • [-] Security reports checked/validated by a reviewer from the AppSec team
Edited by Douglas Barbosa Alexandre

Merge request reports

Loading