GitLab import shows duplicate repository names when using subgroups (no full namespace in UI)

ALM used

GitLab (gitlab.com, SaaS)

CI system used

GitLab CI

Scanner command used when applicable

Standard sonar-scanner (via sonarsource/sonar-scanner-cli Docker image in GitLab CI)

sonar-scanner

Languages of the repository

TypeScript, JavaScript (Node.js, React)

SonarCloud project URL

Private organization – cannot share public URL.


Error observed

There is no runtime error, but there is a UI ambiguity issue during repository import.

When importing repositories from GitLab into SonarCloud, repositories are displayed only by their short name (for example: api, web) without showing the full GitLab namespace path (including subgroup hierarchy).

In our GitLab structure, we have multiple subgroups with repositories that share identical names.

Example:

company/projects/prj1/api
company/projects/prj2/api

However, in SonarCloud import screen, both are displayed simply as:

api
api

There is no visible full path, subgroup, or namespace information to distinguish them.

This makes it impossible to clearly understand which repository is being imported.


Steps to reproduce

  1. Use GitLab as ALM.

  2. Create multiple subgroups.

  3. Inside different subgroups, create repositories with identical names (e.g., api, web).

  4. In SonarCloud, go to Analyze Projects → Import from GitLab.

  5. Observe that repositories are listed only by short name without full namespace.


Potential workaround

Currently, there is no clear workaround in the UI.

Possible workarounds (not ideal):

  • Renaming repositories to make names globally unique.

  • Importing repositories one by one and verifying manually afterward.

  • Using API-based project provisioning (not tested yet).


Question

Is there a way to display the full GitLab path (including subgroup hierarchy) during the import process?

Does SonarCloud internally distinguish repositories by full namespace even if the UI does not display it?

This is critical for organizations using subgroup-based repository structuring.

Thank you.