within a VSTS Build Definition when using the "Prepare anylasis on SonarQube". we are trying to pass the $(System.PullRequest.PullRequestNumber) into the Additional options like such
sonar.github.oauth=****
sonar.github.repository=****
sonar.github.pullRequest=$(System.PullRequest.PullRequestNumber)
sonar.analysis.mode=preview
however when the "Run Code Analysis" step is run, the following error is throw.
2018-04-10T22:26:56.9961964Z ERROR: Error during SonarQube Scanner execution
2018-04-10T22:26:56.9977598Z ERROR: Failed to execute project builder: org.sonar.plugins.github.PullRequestProjectBuilder
2018-04-10T22:26:56.9978166Z ERROR: Caused by: For input string: "$(System.PullRequest.PullRequestNumber)"
our source is in github hence the use of System.PullRequest.PullRequestNumber
instead of System.PullRequest.PullRequestId
which also fails when Source is Pulled from VSTSs Git Repo.
SonarQube 7.0.