我正在尝试让 SONAR Quber 分析使用 .Net 2.0 中的 .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
结束项目
错误信息(更多):
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)
...
任何帮助表示赞赏!
史蒂夫