- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
将Sonar 4.2(正常运行)与gradle(已测试版本1.11和1.12)一起使用,配置了sonar-runner:
allprojects {
if (rootProject == project) {
apply plugin: 'sonar-runner'
sonarRunner {
sonarProperties {
// server props
property "sonar.host.url", project.ext.hostUrl
property "sonar.jdbc.url", project.ext.jdbcUrl
property "sonar.jdbc.driverClassName", project.ext.jdbcDriverClassName
property "sonar.jdbc.username", project.ext.jdbcUsername
property "sonar.jdbc.password", project.ext.jdbcPassword
// project label props
property "sonar.projectName", project.name
property "sonar.projectVersion", project.version
}
}
}
}
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':sonarRunner'.
> No such property: reports for class: java.lang.Boolean
] * Exception is:
15:52:09.907 [ERROR] [org.gradle.BuildExceptionReporter] org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':sonarRunner'.
15:52:09.907 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:69)
15:52:09.908 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:46)
15:52:09.909 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.PostExecutionAnalysisTaskExecuter.execute(PostExecutionAnalysisTaskExecuter.java:35)
15:52:09.909 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:64)
15:52:09.910 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:58)
15:52:09.911 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:42)
15:52:09.912 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:52)
15:52:09.912 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:53)
15:52:09.913 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43)
15:52:09.914 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.AbstractTask.executeWithoutThrowingTaskFailure(AbstractTask.java:289)
15:52:09.914 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.executeTask(AbstractTaskPlanExecutor.java:79)
15:52:09.915 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.processTask(AbstractTaskPlanExecutor.java:63)
15:52:09.916 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.run(AbstractTaskPlanExecutor.java:51)
15:52:09.916 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor.process(DefaultTaskPlanExecutor.java:23)
15:52:09.917 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter.execute(DefaultTaskGraphExecuter.java:86)
15:52:09.918 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.SelectedTaskExecutionAction.execute(SelectedTaskExecutionAction.java:29)
15:52:09.919 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:61)
15:52:09.920 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.DefaultBuildExecuter.access$200(DefaultBuildExecuter.java:23)
15:52:09.921 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.DefaultBuildExecuter$2.proceed(DefaultBuildExecuter.java:67)
15:52:09.921 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.DryRunBuildExecutionAction.execute(DryRunBuildExecutionAction.java:32)
15:52:09.922 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:61)
15:52:09.922 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:54)
15:52:09.923 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:166)
15:52:09.924 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:113)
15:52:09.924 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:81)
15:52:09.924 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.exec.InProcessBuildActionExecuter$DefaultBuildController.run(InProcessBuildActionExecuter.java:64)
15:52:09.926 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.ExecuteBuildAction.run(ExecuteBuildAction.java:33)
15:52:09.927 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.ExecuteBuildAction.run(ExecuteBuildAction.java:24)
15:52:09.927 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:35)
15:52:09.928 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:26)
15:52:09.929 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.RunBuildAction.run(RunBuildAction.java:50)
15:52:09.937 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.internal.Actions$RunnableActionAdapter.execute(Actions.java:171)
15:52:09.938 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.execute(CommandLineActionFactory.java:201)
15:52:09.938 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.execute(CommandLineActionFactory.java:174)
15:52:09.939 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(CommandLineActionFactory.java:170)
15:52:09.939 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(CommandLineActionFactory.java:139)
15:52:09.940 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionReportingAction.java:33)
15:52:09.941 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionReportingAction.java:22)
15:52:09.941 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.Main.doAction(Main.java:46)
15:52:09.942 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.bootstrap.EntryPoint.run(EntryPoint.java:45)
15:52:09.942 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.Main.main(Main.java:37)
15:52:09.943 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.bootstrap.ProcessBootstrap.runNoExit(ProcessBootstrap.java:50)
15:52:09.943 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.bootstrap.ProcessBootstrap.run(ProcessBootstrap.java:32)
15:52:09.944 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.GradleMain.main(GradleMain.java:23)
15:52:09.944 [ERROR] [org.gradle.BuildExceptionReporter] Caused by: groovy.lang.MissingPropertyException: No such property: reports for class: java.lang.Boolean
15:52:09.945 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.sonar.runner.SonarRunnerPlugin$_addGradleDefaults_closure7.doCall(SonarRunnerPlugin.groovy:187)
15:52:09.946 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.ClosureBackedAction.execute(ClosureBackedAction.java:58)
15:52:09.946 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.internal.Actions$FilteredAction.execute(Actions.java:203)
15:52:09.947 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.DefaultDomainObjectCollection.all(DefaultDomainObjectCollection.java:110)
15:52:09.948 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.DefaultDomainObjectCollection.all(DefaultDomainObjectCollection.java:115)
15:52:09.949 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.DefaultDomainObjectCollection.withType(DefaultDomainObjectCollection.java:126)
15:52:09.950 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.DomainObjectCollection$withType.call(Unknown Source)
15:52:09.951 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.sonar.runner.SonarRunnerPlugin.addGradleDefaults(SonarRunnerPlugin.groovy:179)
15:52:09.952 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.sonar.runner.SonarRunnerPlugin.this$2$addGradleDefaults(SonarRunnerPlugin.groovy)
15:52:09.952 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.sonar.runner.SonarRunnerPlugin$this$2$addGradleDefaults.callCurrent(Unknown Source)
15:52:09.953 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.sonar.runner.SonarRunnerPlugin.computeSonarProperties(SonarRunnerPlugin.groovy:134)
15:52:09.963 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.sonar.runner.SonarRunnerPlugin$_apply_closure2_closure12.doCall(SonarRunnerPlugin.groovy:113)
15:52:09.963 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.ConventionAwareHelper$1.getValue(ConventionAwareHelper.java:72)
15:52:09.964 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.ConventionAwareHelper$MappedPropertyImpl.getValue(ConventionAwareHelper.java:136)
15:52:09.964 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.ConventionAwareHelper.getConventionValue(ConventionAwareHelper.java:114)
15:52:09.965 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.sonar.runner.SonarRunner_Decorated.getSonarProperties(Unknown Source)
15:52:09.966 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.sonar.runner.SonarRunner.run(SonarRunner.groovy:46)
15:52:09.966 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:63)
15:52:09.967 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.doExecute(AnnotationProcessingTaskFactory.java:219)
15:52:09.967 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.execute(AnnotationProcessingTaskFactory.java:212)
15:52:09.968 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.execute(AnnotationProcessingTaskFactory.java:201)
15:52:09.969 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.AbstractTask$TaskActionWrapper.execute(AbstractTask.java:533)
15:52:09.969 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.AbstractTask$TaskActionWrapper.execute(AbstractTask.java:516)
15:52:09.970 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:80)
15:52:09.970 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:61)
15:52:09.971 [ERROR] [org.gradle.BuildExceptionReporter] ... 43 more
最佳答案
看起来您在构建脚本中的某个地方引入了一个名为test
的项目属性(例如,通过project.test = true
或ext.test = true
)。这与Java插件的test
任务以及Sonar Runner插件的期望相冲突。声纳服务器版本无关紧要。
关于gradle - Sonar 运行者 Sonar 孵化插件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23390104/
在为jhipster配置以下docker容器之后,除了声纳,其他一切都很好: docker run --name jhipster -w / home / jhipster / app -v〜/ jh
最新的 3.3 sonar-maven-plugin 和 5.6 LTS 作为网络服务器。 使用 mvn sonar:sonar 运行 Sonar 分析( Scanner for Maven ) 忽略
我有一个 cobertura.ser 文件,是在集成测试和系统测试时生成的。现在我想将我的覆盖范围导入 Sonar 服务器。 如何实现这一点,以便在执行 mvn sonar:sonar 时覆盖范围应考
场景:我们有一个 Jenkins maven 构建,它在父 pom 上执行 Sonar : Sonar 。我希望此构建的所有模块都显示为单个 Sonar 项目。目前,我们只有一个带有子模块的 Sona
我有一个看起来像这样的 build.xml 文件: 当我运行文件时,我得到: The prefix "sonar" for element "sonar:sonar" is
我尝试使用标准 maven sonar:sonar 目标在 Jenkins 上使用 java 项目运行 Sonar 分析,并使用后步骤 >> 执行 SonarQube 扫描仪。我使用的maven目标是
我想知道 sonar.projectKey、sonar.projectName 和 sonar.projectVersion 是否有任何标准。 我正在 git 环境中工作,需要对同一 git 存储库的
我有一个很大的困惑,当我们有 Sonar 服务器时 Sonar 扫描仪有什么用?当我使用 soarqube 服务器分析一个项目时,它进行了分析并且运行良好。我仍然很困惑为什么我们也需要扫描仪。 与ec
Sonar 与 jenkins 一起正常运行了 6 个月,没有出现任何故障。从上周开始,我看到一些 jenkins 作业出现以下错误,导致作业失败。 [ERROR] Failed to execute
鉴于相同的代码和具有相同规则的相同 SonarQube 服务器,我在使用 mvn sonar:sonar 与 sonar-scanner 扫描时发现的错误和漏洞数量截然不同。 code> CLI 和
我正在编写一个 Sonarqube Java 自定义规则,但在我尝试分析我的代码时一直出现此错误: "SonarQube is unable to analyze file 'File Path' o
我正在尝试将 SonarQube 与 Azure Devops 集成。我已在 SonarQube 管理员中完成配置(管理 > 配置 > 常规设置 > ALM 集成,选择 Azure DevOps 选项
我正在尝试将 SonarQube 与 Azure Devops 集成。我已在 SonarQube 管理员中完成配置(管理 > 配置 > 常规设置 > ALM 集成,选择 Azure DevOps 选项
我想与Jenkins一起针对Maven 2项目启动SonarQube分析。我首先在构建配置中使用了目标sonar:sonar。 但是我刚刚找到了Jenkins的SonarQube插件。为什么要使用它?
将Sonar 4.2(正常运行)与gradle(已测试版本1.11和1.12)一起使用,配置了sonar-runner: allprojects { if (rootProject == pr
我将 Sonar 与 Jenkins 一起使用以进行持续集成和代码分析。我learned该 Sonar 默认包括 Checkstyle、FindBugs、JaCoCo、PMD ,所以我们不需要配置项目
我们想在我们的项目中使用 SonarQube 和一些 CI 工具。 Sonar 服务器 url 在主 pom.xml 中配置。 项目中有几个团队成员。那么当一个团队成员在本地执行 sonar:sona
命令 mvn sonar:sonar 执行的 Maven 生命周期阶段是什么? 虽然我看到了在屏幕上运行的日志,但在非常高的水平上,我发现了测试、安装。 考虑下面的例子, 我有一个像下面这样的mave
我有几个 groovy/grails 项目,我正在使用 sonar-runner 来分析它们。他们工作得很好,直到今天我开始收到这个错误: ERROR: Error during Sonar runn
当我运行声纳时,我的代码覆盖率总是为 0。我使用的是三叶草。 pom.xml 文件中的条目下方 11 1.18.20 Hoxton.SR11
我是一名优秀的程序员,十分优秀!