My project does not appear on the sonarLint listing in visual studio

  • Good afternoon, can someone help me? When I’m going to set up the connection in visual studio, only the first 300 projects appear, and the project I need is not among the 300, can you help me?
  • steps to reproduce

Hi @thiago4664, welcome to the community.

If you don’t see your project in the list, it’s a permissions issue. You need to input a token that has permissions to view the project. Or, if you’re using username+password combination, then you need to grant permissions to your user account to view the project.

I am allowed to see this project on sonar qube. I saw that it was referring to the maximum number because if I add a new project now that it starts with the letter A for example, and the last projects are:

  • CA

When adding this new project, the CB leaves the list and the CA becomes the last

@thiago4664 the limit on number of projects is set to 10,000, so 300 is not the maximum number and it should not be a problem.

What is your SQ version and edition?
Also, can you please do a quick test to help pin-point the issue?

  1. Execute a GET request to your SQ server on the following path [SQ full ur]/api/components/search_projects?asc=true&p=1&ps=500
    along with the credentials that you input in the IDE (token/username+password) – see here for an example. Let me know if you’d like me to provide further step-by-step instructions.
  2. You should be getting a response in the format of
"paging": {
"pageIndex": 1,
"pageSize": 500,
"total": <number of projects in your SQ server>
"organizations": [...],
"components": [...],
"facets": [...],
  1. When you execute this request, do you see the expected number of projects under “total” field? and what is the HTTP status code of the response?
  2. Do you see the project that you’re looking for in the response under the components field? You can find it based on the name field.

Please let me know the results so I could assist you further.

Community Edition - Version 7.8 (build 26217)

In the total field I see the total number of projects right and receive status code 200, but the project I am looking for is not within these 500 that return in the body

Thanks for the response @thiago4664! I’m sorry for the late reply, I missed the notification of your response.

Is the “total” number of projects that you receive back bigger than 500?
If so, can you please re-run the request [SQ full ur]/api/components/search_projects?asc=true&p=1&ps=500 but this time change p=1 to p=2, p=3 and so on? (p=page number).

Do you see your project in any of the other pages? If so, on which page is it? (middle, last?) and what is the http response of that request? (is it still 200 OK?)

Thank you very much for your help!

1 Like