Skip to content

Commit

Permalink
Merge pull request #4224 from whisperity/chore/config/generated-doc-u…
Browse files Browse the repository at this point in the history
…rls-and-severities

chore(config): Add automatically generated `doc_url`s and `severity`s
  • Loading branch information
whisperity committed May 9, 2024
2 parents 2a6d18e + 4395c79 commit 87b2c9b
Show file tree
Hide file tree
Showing 8 changed files with 660 additions and 308 deletions.
598 changes: 454 additions & 144 deletions config/labels/analyzers/clang-tidy.json

Large diffs are not rendered by default.

229 changes: 117 additions & 112 deletions config/labels/analyzers/clangsa.json

Large diffs are not rendered by default.

36 changes: 27 additions & 9 deletions config/labels/analyzers/cppcheck.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
"severity:MEDIUM"
],
"cppcheck-assignmentInCondition": [
"severity:LOW"
"severity:STYLE"
],
"cppcheck-autoVariables": [
"profile:default",
Expand Down Expand Up @@ -132,7 +132,7 @@
"severity:HIGH"
],
"cppcheck-compareValueOutOfTypeRangeError": [
"severity:LOW"
"severity:STYLE"
],
"cppcheck-comparisonError": [
"severity:STYLE"
Expand All @@ -155,10 +155,16 @@
"severity:STYLE"
],
"cppcheck-constParameter": [
"severity:LOW"
"severity:STYLE"
],
"cppcheck-constParameterCallback": [
"severity:LOW"
"severity:STYLE"
],
"cppcheck-constParameterPointer": [
"severity:STYLE"
],
"cppcheck-constParameterReference": [
"severity:STYLE"
],
"cppcheck-constStatement": [
"profile:default",
Expand All @@ -167,6 +173,12 @@
"cppcheck-constVariable": [
"severity:STYLE"
],
"cppcheck-constVariablePointer": [
"severity:STYLE"
],
"cppcheck-constVariableReference": [
"severity:STYLE"
],
"cppcheck-containerOutOfBounds": [
"profile:default",
"severity:HIGH"
Expand Down Expand Up @@ -471,6 +483,9 @@
"cppcheck-knownEmptyContainer": [
"severity:STYLE"
],
"cppcheck-knownPointerToBool": [
"severity:STYLE"
],
"cppcheck-leakNoVarFunctionCall": [
"profile:default",
"severity:HIGH"
Expand Down Expand Up @@ -590,7 +605,7 @@
],
"cppcheck-negativeContainerIndex": [
"profile:default",
"severity:HIGH"
"severity:MEDIUM"
],
"cppcheck-negativeIndex": [
"profile:default",
Expand Down Expand Up @@ -696,6 +711,9 @@
"cppcheck-pointerOutOfBounds": [
"severity:LOW"
],
"cppcheck-pointerOutOfBoundsCond": [
"severity:LOW"
],
"cppcheck-pointerPositive": [
"severity:STYLE"
],
Expand Down Expand Up @@ -795,13 +813,13 @@
"profile:default",
"severity:HIGH"
],
"cppcheck-returnStdMoveLocal": [
"severity:LOW"
],
"cppcheck-returnTempReference": [
"profile:default",
"severity:HIGH"
],
"cppcheck-returnStdMoveLocal": [
"severity:LOW"
],
"cppcheck-sameIteratorExpression": [
"severity:STYLE"
],
Expand Down Expand Up @@ -1164,7 +1182,7 @@
],
"cppcheck-zerodivcond": [
"profile:default",
"severity:HIGH"
"severity:MEDIUM"
]
}
}
2 changes: 1 addition & 1 deletion config/labels/analyzers/gcc.json
Original file line number Diff line number Diff line change
Expand Up @@ -227,4 +227,4 @@
"severity:HIGH"
]
}
}
}
94 changes: 55 additions & 39 deletions config/labels/analyzers/mdl.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,156 +2,172 @@
"analyzer": "mdl",
"labels": {
"MD001": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md001---header-levels-should-only-increment-by-one-level-at-a-time",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md001---header-levels-should-only-increment-by-one-level-at-a-time",
"severity:STYLE"
],
"MD002": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md002---first-header-should-be-a-top-level-header",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md002---first-header-should-be-a-top-level-header",
"severity:STYLE"
],
"MD003": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md003---header-style",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md003---header-style",
"severity:STYLE"
],
"MD004": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md004---unordered-list-style",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md004---unordered-list-style",
"severity:STYLE"
],
"MD005": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md005---inconsistent-indentation-for-list-items-at-the-same-level",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md005---inconsistent-indentation-for-list-items-at-the-same-level",
"severity:STYLE"
],
"MD006": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md006---consider-starting-bulleted-lists-at-the-beginning-of-the-line",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md006---consider-starting-bulleted-lists-at-the-beginning-of-the-line",
"severity:STYLE"
],
"MD007": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md007---unordered-list-indentation",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md007---unordered-list-indentation",
"severity:STYLE"
],
"MD009": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md009---trailing-spaces",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md009---trailing-spaces",
"severity:STYLE"
],
"MD010": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md010---hard-tabs",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md010---hard-tabs",
"severity:STYLE"
],
"MD011": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md011---reversed-link-syntax",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md011---reversed-link-syntax",
"severity:STYLE"
],
"MD012": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md012---multiple-consecutive-blank-lines",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md012---multiple-consecutive-blank-lines",
"severity:STYLE"
],
"MD013": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md013---line-length",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md013---line-length",
"severity:STYLE"
],
"MD014": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md014---dollar-signs-used-before-commands-without-showing-output",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md014---dollar-signs-used-before-commands-without-showing-output",
"severity:STYLE"
],
"MD018": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md018---no-space-after-hash-on-atx-style-header",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md018---no-space-after-hash-on-atx-style-header",
"severity:STYLE"
],
"MD019": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md019---multiple-spaces-after-hash-on-atx-style-header",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md019---multiple-spaces-after-hash-on-atx-style-header",
"severity:STYLE"
],
"MD020": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md020---no-space-inside-hashes-on-closed-atx-style-header",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md020---no-space-inside-hashes-on-closed-atx-style-header",
"severity:STYLE"
],
"MD021": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md021---multiple-spaces-inside-hashes-on-closed-atx-style-header",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md021---multiple-spaces-inside-hashes-on-closed-atx-style-header",
"severity:STYLE"
],
"MD022": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md022---headers-should-be-surrounded-by-blank-lines",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md022---headers-should-be-surrounded-by-blank-lines",
"severity:STYLE"
],
"MD023": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md023---headers-must-start-at-the-beginning-of-the-line",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md023---headers-must-start-at-the-beginning-of-the-line",
"severity:STYLE"
],
"MD024": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md024---multiple-headers-with-the-same-content",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md024---multiple-headers-with-the-same-content",
"severity:STYLE"
],
"MD025": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md025---multiple-top-level-headers-in-the-same-document",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md025---multiple-top-level-headers-in-the-same-document",
"severity:STYLE"
],
"MD026": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md026---trailing-punctuation-in-header",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md026---trailing-punctuation-in-header",
"severity:STYLE"
],
"MD027": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md027---multiple-spaces-after-blockquote-symbol",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md027---multiple-spaces-after-blockquote-symbol",
"severity:STYLE"
],
"MD028": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md028---blank-line-inside-blockquote",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md028---blank-line-inside-blockquote",
"severity:STYLE"
],
"MD029": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md029---ordered-list-item-prefix",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md029---ordered-list-item-prefix",
"severity:STYLE"
],
"MD030": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md030---spaces-after-list-markers",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md030---spaces-after-list-markers",
"severity:STYLE"
],
"MD031": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md031---fenced-code-blocks-should-be-surrounded-by-blank-lines",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md031---fenced-code-blocks-should-be-surrounded-by-blank-lines",
"severity:STYLE"
],
"MD032": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md032---lists-should-be-surrounded-by-blank-lines",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md032---lists-should-be-surrounded-by-blank-lines",
"severity:STYLE"
],
"MD033": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md033---inline-html",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md033---inline-html",
"severity:STYLE"
],
"MD034": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md034---bare-url-used",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md034---bare-url-used",
"severity:STYLE"
],
"MD035": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md035---horizontal-rule-style",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md035---horizontal-rule-style",
"severity:STYLE"
],
"MD036": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md036---emphasis-used-instead-of-a-header",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md036---emphasis-used-instead-of-a-header",
"severity:STYLE"
],
"MD037": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md037---spaces-inside-emphasis-markers",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md037---spaces-inside-emphasis-markers",
"severity:STYLE"
],
"MD038": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md038---spaces-inside-code-span-elements",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md038---spaces-inside-code-span-elements",
"severity:STYLE"
],
"MD039": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md039---spaces-inside-link-text",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md039---spaces-inside-link-text",
"severity:STYLE"
],
"MD040": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md040---fenced-code-blocks-should-have-a-language-specified",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md040---fenced-code-blocks-should-have-a-language-specified",
"severity:STYLE"
],
"MD041": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md041---first-line-in-file-should-be-a-top-level-header",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md041---first-line-in-file-should-be-a-top-level-header",
"severity:STYLE"
],
"MD046": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.11.0/docs/RULES.md#md046---code-block-style",
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md046---code-block-style",
"severity:STYLE"
],
"MD047": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md047---file-should-end-with-a-single-newline-character",
"severity:STYLE"
],
"MD055": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md055---table-row-doesnt-begin-end-with-pipes",
"severity:STYLE"
],
"MD056": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md056---table-has-inconsistent-number-of-columns",
"severity:STYLE"
],
"MD057": [
"doc_url:https://github.com/markdownlint/markdownlint/blob/v0.13.0/docs/RULES.md#md057---table-has-missing-or-invalid-header-separation",
"severity:STYLE"
]
}
}
}
3 changes: 3 additions & 0 deletions config/labels/analyzers/pylint.json
Original file line number Diff line number Diff line change
Expand Up @@ -796,6 +796,9 @@
"redeclared-assigned-name": [
"severity:MEDIUM"
],
"redefine-in-handler": [
"severity:MEDIUM"
],
"redefined-argument-from-local": [
"severity:STYLE"
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,9 @@ def setup_method(self, method):
'deadcode.DeadStores': 6,
'misc-definitions-in-headers': 2}

self.run1_sev_counts = {Severity.MEDIUM: 6,
self.run1_sev_counts = {Severity.MEDIUM: 11,
Severity.LOW: 6,
Severity.HIGH: 32}
Severity.HIGH: 27}

self.run2_sev_counts = {Severity.MEDIUM: 5,
Severity.LOW: 6,
Expand Down
2 changes: 1 addition & 1 deletion web/tests/projects/cpp/project_info.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
{ "file": "path_begin.cpp", "line": 12, "checker": "core.DivideZero", "hash": "73e6a2e1091295da065a6527f8540366" },
{ "file": "path_begin.cpp", "line": 18, "checker": "core.DivideZero", "hash": "73e6a2e1091295da065a6527f8540366" }
],
"filter_severity_levels": [{"MEDIUM": 6}, {"LOW": 6}, {"HIGH": 32}, {"STYLE": 0}, {"CRITICAL": 0}],
"filter_severity_levels": [{"MEDIUM": 11}, {"LOW": 6}, {"HIGH": 27}, {"STYLE": 0}, {"CRITICAL": 0}],
"filter_checker_id": [{"*unix*": 1}, {"core*": 22}, {"*DeadStores": 6}],
"filter_analyzer_name": [{"clang-tidy": 10}, {"clangsa": 34}],
"filter_filepath": [{"*null*": 5}],
Expand Down

0 comments on commit 87b2c9b

Please sign in to comment.