0
我想讓SONAR Quber分析一個ASP.NET網站中使用.aspx文件構建的ASP.NET網站。我得到一個錯誤:java.lang.NullPointerException(更多細節如下)。聲納導致:參數'目錄'不是目錄
我相信原因與我的.sln文件中的「PhysicalPath」設置有關(請參見下文)。我試過在這個值中使用相對和完整的物理路徑。
Project("{E24C65DC-7377-472B-9ABA-BC803B73C61A}") = ""ECommerce", "..\ECommerce", "{9155C3E9-E34B-4C39-AE8A-ABD5B44FAB8A}"
ProjectSection(WebsiteProperties) = preProject
TargetFramework = "2.0"
Debug.AspNetCompiler.VirtualPath = "/ECommerce"
Debug.AspNetCompiler.PhysicalPath = "..\..\Projects\ECommerce\"
Debug.AspNetCompiler.TargetPath = "PrecompiledWeb\ECommerce\"
Debug.AspNetCompiler.Updateable = "true"
Debug.AspNetCompiler.ForceOverwrite = "true"
Debug.AspNetCompiler.FixedNames = "false"
Debug.AspNetCompiler.Debug = "True"
Release.AspNetCompiler.VirtualPath = "/ECommerce"
Release.AspNetCompiler.PhysicalPath = "..\..\Projects\ECommerce\"
Debug.AspNetCompiler.TargetPath = "PrecompiledWeb\ECommerce\"
Release.AspNetCompiler.Updateable = "true"
Release.AspNetCompiler.ForceOverwrite = "true"
Release.AspNetCompiler.FixedNames = "false"
Release.AspNetCompiler.Debug = "False"
VWDPort = "3687"
EndProjectSection
EndProject
錯誤消息(更多):
Caused by: java.lang.NullPointerException
at java.io.File.<init>(Unknown Source)
at org.sonar.plugins.dotnet.api.microsoft.ModelFactory.getWebProject(ModelFactory.java:465)
at org.sonar.plugins.dotnet.api.microsoft.ModelFactory.getProjects(ModelFactory.java:287)
at org.sonar.plugins.dotnet.api.microsoft.ModelFactory.getSolution(ModelFactory.java:198)
at org.sonar.plugins.dotnet.core.VisualStudioProjectBuilder.createVisualStudioSolution(VisualStudioProjectBuilder.java:185)
at org.sonar.plugins.dotnet.core.VisualStudioProjectBuilder.build(VisualStudioProjectBuilder.java:82)
at org.sonar.api.batch.bootstrap.ProjectBuilder.build(ProjectBuilder.java:67)
at org.sonar.batch.scan.ProjectReactorReady.start(ProjectReactorReady.java:63)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
...
任何幫助表示讚賞!
史蒂夫
我不認爲這適用,因爲我在Windows服務器上運行SONAR Qube,而不是Linux。 – Steve
好吧,我仔細看了看,發現你的問題,所以我編輯了我的答案。 –
你是對的。謝謝! – Steve