Hi,
Just want to add to this because we have been getting the same behaviour. From my investigations, there are 2 parts to the problem.
-
The background task is mysteriously being canceled. There is another thread that looks at this here: Why was a background task cancelled
But this is not what this problem is about -
The ADO task constantly polls the
/api/ce/task
endpoint to check the status of the task
When the task is canceled, this endpoint returnsstatus: CANCELED
However, the SonarQubePublish task checks forCANCEL
so ends up in a loop because the fall through condition just checks the endpoint again
sonar-scanner-vsts/Task.ts at e1f8ae84a2d274ce9b67a0e6f245bf13665eca91 · SonarSource/sonar-scanner-vsts · GitHub