Tag 'linter-like' quality queries that use pointto

Excluded for now: unnecassary-delete; since the pattern is often intentional to break reference cycles, which the query doesn't account for; so uncertain about its claim of high precision
This commit is contained in:
Joe Farebrother
2025-06-18 10:04:47 +01:00
parent 5c4548df45
commit 869e33e38c
13 changed files with 30 additions and 17 deletions

View File

@@ -2,7 +2,8 @@
* @name Comparison of constants
* @description Comparison of constants is always constant, but is harder to read than a simple constant.
* @kind problem
* @tags maintainability
* @tags quality
* maintainability
* useless-code
* external/cwe/cwe-570
* external/cwe/cwe-571

View File

@@ -2,10 +2,9 @@
* @name Comparison of identical values
* @description Comparison of identical values, the intent of which is unclear.
* @kind problem
* @tags reliability
* correctness
* @tags quality
* maintainability
* readability
* convention
* external/cwe/cwe-570
* external/cwe/cwe-571
* @problem.severity warning

View File

@@ -2,8 +2,9 @@
* @name Maybe missing 'self' in comparison
* @description Comparison of identical values, the intent of which is unclear.
* @kind problem
* @tags reliability
* maintainability
* @tags quality
* reliability
* correctness
* external/cwe/cwe-570
* external/cwe/cwe-571
* @problem.severity warning

View File

@@ -2,8 +2,9 @@
* @name Testing equality to None
* @description Testing whether an object is 'None' using the == operator is inefficient and potentially incorrect.
* @kind problem
* @tags efficiency
* maintainability
* @tags quality
* reliability
* correctness
* @problem.severity recommendation
* @sub-severity high
* @precision very-high

View File

@@ -2,7 +2,8 @@
* @name Unnecessary lambda
* @description A lambda is used that calls through to a function without modifying any parameters
* @kind problem
* @tags maintainability
* @tags quality
* maintainability
* useless-code
* @problem.severity recommendation
* @sub-severity high

View File

@@ -2,7 +2,8 @@
* @name `__init__` method returns a value
* @description Explicitly returning a value from an `__init__` method will raise a TypeError.
* @kind problem
* @tags reliability
* @tags quality
* reliability
* correctness
* @problem.severity error
* @sub-severity low

View File

@@ -2,7 +2,9 @@
* @name Use of the return value of a procedure
* @description The return value of a procedure (a function that does not return a value) is used. This is confusing to the reader as the value (None) has no meaning.
* @kind problem
* @tags maintainability
* @tags quality
* maintainability
* readability
* @problem.severity warning
* @sub-severity low
* @precision high

View File

@@ -2,7 +2,8 @@
* @name Statement has no effect
* @description A statement has no effect
* @kind problem
* @tags maintainability
* @tags quality
* maintainability
* useless-code
* external/cwe/cwe-561
* @problem.severity recommendation

View File

@@ -2,7 +2,8 @@
* @name Unreachable code
* @description Code is unreachable
* @kind problem
* @tags maintainability
* @tags quality
* maintainability
* useless-code
* external/cwe/cwe-561
* @problem.severity warning

View File

@@ -2,7 +2,9 @@
* @name Use of exit() or quit()
* @description exit() or quit() may fail if the interpreter is run with the -S option.
* @kind problem
* @tags maintainability
* @tags quality
* reliability
* correctness
* @problem.severity warning
* @sub-severity low
* @precision very-high

View File

@@ -2,7 +2,8 @@
* @name Suspicious unused loop iteration variable
* @description A loop iteration variable is unused, which suggests an error.
* @kind problem
* @tags maintainability
* @tags quality
* reliability
* correctness
* @problem.severity error
* @sub-severity low

View File

@@ -2,7 +2,8 @@
* @name Unused local variable
* @description Local variable is defined but not used
* @kind problem
* @tags maintainability
* @tags quality
* maintainability
* useless-code
* external/cwe/cwe-563
* @problem.severity recommendation

View File

@@ -2,7 +2,8 @@
* @name Unused global variable
* @description Global variable is defined but not used
* @kind problem
* @tags efficiency
* @tags quality
* maintainability
* useless-code
* external/cwe/cwe-563
* @problem.severity recommendation