sonarqube

Quality gate widget issue in Azure DevOps

半腔热情 提交于 2021-01-29 06:49:37
问题 I have configured a quality gate widget with project key and api link in Azure dashboards. But this doesn't work and my quality widget shows a red cross mark. Could someone help what could be the issue? 回答1: We can reproduce this issue. According to the error message, we recommend that you raise a new issue here. In addition, it seems that this is a known issue on extension Quality Gate Widget , you could follow this ticket for the latest news. Update1 It seems that we cannot get sonar report

SonarQube requires separate xsd schema files and displays the error: “Error resolving component in XSD file”

依然范特西╮ 提交于 2021-01-29 06:13:31
问题 I'm using two different xsd schema files in one project. First one is input.xsd . This file uses targetNamespace : <?xml version="1.0" encoding="UTF-8"?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:w3s="https://www.w3schools.com" targetNamespace="https://www.w3schools.com"> <xsd:element name="Mobiles"> <xsd:complexType> <xsd:sequence> <xsd:element name="Mobile" type="w3s:Mobile" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:complexType name=

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 - avoiding catch generic Exception

风格不统一 提交于 2021-01-28 11:21:11
问题 Sonar complains when catching the generic type Exception , but sometimes we need to do some general exception handling for ALL (even not yet recognized) exception types. What is the solution to pass this sonar check? 回答1: Unless you are invoking a method which throws Exception , there is no need to catch Exception : catch the exceptions you know about, and the compiler will tell you when you have to start handling another one. The problem with catching "not yet recognized" Exception s is that

How to install SonarQube with Open JDK 11

一曲冷凌霜 提交于 2021-01-28 07:44:20
问题 I am trying to install SonarQube 8.5 (community version) on my local machine . My machine already has Java JRE 8 installed. SonaQube has pre-requirement JRE 11 or Open JDK 11 . Since you cannot download JRE 11 anymore, I decided to go with Open JDK 11 I want to set SonarQube to use specific JDK. How do i do that? Quick SO search suggest to use wrapper.java.command in wrapper.conf file, but this line is not available SonarQube 8.5, OS Windows: 10 回答1: If you want your sonarqube to use specific

Jenkins can't reach Sonarqube

五迷三道 提交于 2021-01-27 19:41:38
问题 I am currently trying to get my Jenkins/Sonar integration to work. Here is what I have: Jenkins is working Sonarqube is working (reachable from webinterface) Ports are open However! I tried all possible settings, Jenkins insists that Sonarqube is Localhost:9000, no matter what I tell it (and even if, this should work too). This leads to following: and ultimately lets the build fail. What could I try to rectify this? 回答1: localhost:9000 is the default sonar qube url, regarding the official

Jenkins can't reach Sonarqube

若如初见. 提交于 2021-01-27 19:16:10
问题 I am currently trying to get my Jenkins/Sonar integration to work. Here is what I have: Jenkins is working Sonarqube is working (reachable from webinterface) Ports are open However! I tried all possible settings, Jenkins insists that Sonarqube is Localhost:9000, no matter what I tell it (and even if, this should work too). This leads to following: and ultimately lets the build fail. What could I try to rectify this? 回答1: localhost:9000 is the default sonar qube url, regarding the official

How to fail a maven build, when quality gate fails?

こ雲淡風輕ζ 提交于 2021-01-27 13:21:38
问题 Earlier I use sonar-maven-plugin version 3.2 then when a Sonar quality gate fails the build also used to fail. Now I am using sonar-maven-plugin version 3.7.0.1746 , it does not happen so. Even if quality gate fails maven build succeeded. Now when I use version 3.2 in pom.xml it gives the error [ERROR] Failed to execute goal org.sonarsource.scanner.maven:sonar-maven-plugin:3.2:sonar (default-cli) on project maven-webapp: Unable to execute SonarQube: Fail to download libraries from server ->

sonar code smell for reducer used in combineReducer

主宰稳场 提交于 2021-01-27 05:48:36
问题 I am using combineReducer to combine reducers and reducer like this const todo = (state = {}, action) => { switch (action.type) { //... case 'TOGGLE_TODO': if (state.id !== action.id) { return state } return Object.assign({}, state, { completed: !state.completed }) default: return state } } My problem is if i am defining reducer like that i am getting sonar code smell Function parameters with default values should be last1 but combine reducer pass argument in this sequence only how to work on

sonar code smell for reducer used in combineReducer

梦想的初衷 提交于 2021-01-27 05:48:20
问题 I am using combineReducer to combine reducers and reducer like this const todo = (state = {}, action) => { switch (action.type) { //... case 'TOGGLE_TODO': if (state.id !== action.id) { return state } return Object.assign({}, state, { completed: !state.completed }) default: return state } } My problem is if i am defining reducer like that i am getting sonar code smell Function parameters with default values should be last1 but combine reducer pass argument in this sequence only how to work on