Exception calling “GetFullPath” with 1 argument(s): “The path is not of a legal form.”

≡放荡痞女 提交于 2021-01-28 19:03:49

问题


I have a release configured in Visual Studio Team Services using Release Management to run a SonarQube for MSBuild task. The task starts and then fails with the following error:

Executing the powershell script: C:\LR\MMS\Services\Mms\TaskAgentProvisioner\Tools\agents\default\tasks\SonarQubePreBuild\1.0.29\SonarQubePreBuild.ps1

[error]Exception calling "GetFullPath" with "1" argument(s): "The path is not of a legal form."

Is this an error that I'm causing or is this an issue with the task?


回答1:


"SonarQube for MSBuild" is currently designed to use in "Build" process. So you will see some errors when use it in Release Management. You can submit a feature request on this page: http://visualstudio.uservoice.com/forums/330519-team-services

If you do want to use it in Release Management for now and your are using your own build agent rather than the hosted build agent. You can go to the "Tasks" folder in your build agent directory and update the "Path" variables in the PowerShell script for SonarQube task.

For example, changing the path variable "$env:BUILD_SOURCESDIRECTORY" to "$env:SYSTEM_DEFAULTWORKINGDIRECTORY" in "SonarQubePreBuildImpl.ps1", you will get the SonarQubePreBuild task finished successfully.



来源:https://stackoverflow.com/questions/34337042/exception-calling-getfullpath-with-1-arguments-the-path-is-not-of-a-legal

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!