Multistage based approach with Sonar cloud

Hi ,

We are trying to implement sonar cloud in stage based approach like Sonar prep template will be called in build stage before to dotnet build and sonar analyze and publish will be totally a separate stage after the dev deployment and when we try to go with this approach we found like sonar prepare is not communicating with analyze which is causing an issue and erroring as below.

“##[error][SQ] The ‘Prepare Analysis Configuration’ task was not executed prior to this task”

How can we go with this kind of approach?

Hey there.

These need to be run in the same environment/context/stage because the Prepare Analysis Configuration task directly influences the build (so that the analyzers run during the build, which is arctehicture of our .NET analysis).