-
Hello I've been playing with revive configuration and I was wondering if the severity levels are compatible at all. For example, I have the following .golangci.yml linters:
disable-all: true
enable:
- revive
linters-settings:
revive:
severity: error
rules:
- name: cognitive-complexity
arguments: [15]
severity: warning
- name: cyclomatic
arguments: [12]
severity: warning When running <?xml version="1.0" encoding="UTF-8"?>
<checkstyle version="5.0">
<file name="internal/slack/slack_test.go">
<error column="1" line="402" message="cognitive-complexity: function okFileUpload has cognitive complexity 17 (> max enabled 15)" severity="error" source="revive">
</error>
</file>
</checkstyle> I would expect it to be: <?xml version="1.0" encoding="UTF-8"?>
<checkstyle version="5.0">
<file name="internal/slack/slack_test.go">
<error column="1" line="402" message="cognitive-complexity: function okFileUpload has cognitive complexity 17 (> max enabled 15)" severity="warning" source="revive">
</error>
</file>
</checkstyle> Is this the wrong expectation? I really need to be able to configure the severity levels on a rule level to fine-tune my SonarQube setup. |
Beta Was this translation helpful? Give feedback.
Answered by
ldez
Mar 20, 2021
Replies: 1 comment 2 replies
-
Hello, I think your problem is related to #1831 The fix will be available in the fix release. |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
ealves-pt
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello,
I think your problem is related to #1831
The fix will be available in the fix release.