KT.ABSENT_OR_WRONG_FILE_LICENSE
|
Comments and documentation of the code |
Source file doesn't have the required license header |
3 |
False |
KT.ANNOTATION_ON_SEPARATE_LINE
|
Formatting issues |
Multiple annotations should be placed on separate lines |
3 |
False |
KT.ANNOTATION_SPACING
|
Formatting issues |
There should not be empty lines between an annotation and the object that it's annotating |
3 |
False |
KT.ARGUMENT_LIST_WRAPPING
|
Formatting issues |
Incorrect argument list wrapping |
3 |
False |
KT.ARRAY_PRIMITIVE
|
Potential performance problems |
Using 'Array' primitive type |
3 |
True |
KT.AVOID_REFERENTIAL_EQUALITY
|
Potential bugs |
Referential equality checks |
3 |
True |
KT.BLOCK_COMMENT_INITIAL_STAR_ALIGNMENT
|
Formatting issues |
Comment lines are not aligned with the opening of the block comment. |
3 |
False |
KT.BOOLEAN_PROPERTY_NAMING
|
Naming of different parts of the codebase |
Boolean property doesn't match a pattern |
3 |
False |
KT.CAN_BE_NON_NULLABLE
|
Style of the code |
Variable can be non-nullable |
3 |
False |
KT.CASCADING_CALL_WRAPPING
|
Style of the code |
Chained call is not placed on a new line when a preceding one is |
3 |
False |
KT.CAST_TO_NULLABLE_TYPE
|
Potential bugs |
Cast to nullable types |
3 |
False |
KT.CHAIN_WRAPPING
|
Formatting issues |
Condition chaining is wrapped right |
3 |
True |
KT.CLASS_NAMING
|
Naming of different parts of the codebase |
Class or Object name does not follow the specified naming convention |
3 |
True |
KT.CLASS_ORDERING
|
Style of the code |
Class contents not ordered |
3 |
False |
KT.COLLAPSIBLE_IF_STATEMENTS
|
Style of the code |
Two 'if' statements can be collapsed |
3 |
False |
KT.COMMENT_OVER_PRIVATE_FUNCTION
|
Comments and documentation of the code |
Comments and documentation added to private functions |
3 |
False |
KT.COMMENT_OVER_PRIVATE_PROPERTY
|
Comments and documentation of the code |
Comments and documentation above private properties |
3 |
False |
KT.COMMENT_SPACING
|
Formatting issues |
Comments have the right spacing |
3 |
True |
KT.COMMENT_WRAPPING
|
Formatting issues |
Wrong placement of a block comment |
3 |
False |
KT.COMPLEX_CONDITION
|
Complex code |
Complex conditions should be extracted into into well-named functions or variables |
3 |
True |
KT.COMPLEX_INTERFACE
|
Complex code |
Complex interface should be split into smaller interfaces and have clear responsibility |
3 |
False |
KT.COMPLEX_METHOD
|
Complex code |
Complex method with high Cyclomatic Complexity |
3 |
True |
KT.CONSTRUCTOR_PARAMETER_NAMING
|
Naming of different parts of the codebase |
Constructor parameter names do not follow the specified naming convention |
3 |
True |
KT.COULD_BE_SEQUENCE
|
Potential performance problems |
Possible performance penalty due to a new list being created for each call |
3 |
False |
KT.DATA_CLASS_CONTAINS_FUNCTIONS
|
Style of the code |
Function inside data class have not been marked as a conversion function |
3 |
False |
KT.DATA_CLASS_SHOULD_BE_IMMUTABLE
|
Style of the code |
Mutable properties inside data class |
3 |
False |
KT.DEPRECATED_BLOCK_TAG
|
Comments and documentation of the code |
Use of the @deprecated block tag in KDoc comments |
3 |
False |
KT.DEPRECATION
|
Potential bugs |
Deprecated elements |
3 |
False |
KT.DESTRUCTURING_DECLARATION_WITH_TOO_MANY_ENTRIES
|
Style of the code |
Destructuring declaration with too many entries |
3 |
True |
KT.DISCOURAGED_COMMENT_LOCATION
|
Formatting issues |
discouraged comment location |
3 |
False |
KT.DONT_DOWNCAST_COLLECTION_TYPES
|
Potential bugs |
Down-casting immutable collection types |
3 |
False |
KT.DOUBLE_MUTABILITY_FOR_COLLECTION
|
Potential bugs |
Using var when declaring a mutable collection |
3 |
True |
KT.DUPLICATE_CASE_IN_WHEN_EXPRESSION
|
Potential bugs |
Duplicate case statements in when expressions |
3 |
True |
KT.ELSE_CASE_INSTEAD_OF_EXHAUSTIVE_WHEN
|
Potential bugs |
When expression should not contain an else case when its an enum class, sealed class or of type boolean. |
3 |
False |
KT.EMPTY_CATCH_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'catch' block |
3 |
True |
KT.EMPTY_CLASS_BLOCK
|
Empty blocks of code which should be avoided |
Empty class |
3 |
True |
KT.EMPTY_DEFAULT_CONSTRUCTOR
|
Empty blocks of code which should be avoided |
Empty default constructor |
3 |
True |
KT.EMPTY_DO_WHILE_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'do/while' loop |
3 |
True |
KT.EMPTY_ELSE_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'else' block |
3 |
True |
KT.EMPTY_FINALLY_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'finally' block |
3 |
True |
KT.EMPTY_FOR_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'for' loop |
3 |
True |
KT.EMPTY_FUNCTION_BLOCK
|
Empty blocks of code which should be avoided |
Empty function |
3 |
True |
KT.EMPTY_IF_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'if' block |
3 |
True |
KT.EMPTY_INIT_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'init' expression |
3 |
True |
KT.EMPTY_KT_FILE
|
Empty blocks of code which should be avoided |
Empty Kotlin (.kt) file |
3 |
True |
KT.EMPTY_SECONDARY_CONSTRUCTOR
|
Empty blocks of code which should be avoided |
Empty secondary constructor |
3 |
True |
KT.EMPTY_TRY_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'try' block |
3 |
True |
KT.EMPTY_WHEN_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'when' expression |
3 |
True |
KT.EMPTY_WHILE_BLOCK
|
Empty blocks of code which should be avoided |
Empty 'while' expression |
3 |
True |
KT.END_OF_SENTENCE_FORMAT
|
Comments and documentation of the code |
Improper end of the first sentence of a KDoc comment |
3 |
False |
KT.ENUM_ENTRY_NAME_CASE
|
Formatting issues |
Enum entries with names that don't meet standard conventions |
3 |
False |
KT.ENUM_NAMING
|
Naming of different parts of the codebase |
Enum name does not follow the specified naming convention |
3 |
True |
KT.EQUALS_ALWAYS_RETURNS_TRUE_OR_FALSE
|
Potential bugs |
Method equals() always return true or false |
3 |
True |
KT.EQUALS_NULL_CALL
|
Style of the code |
Method 'equals()' is called with null parameter |
3 |
True |
KT.EQUALS_ON_SIGNATURE_LINE
|
Style of the code |
Equals sign is not on the same line as the function signature |
3 |
False |
KT.EQUALS_WITH_HASH_CODE_EXIST
|
Potential bugs |
Method hashCode() is not overridden |
3 |
True |
KT.EXCEPTION_RAISED_IN_UNEXPECTED_LOCATION
|
Code throws and handles Exceptions |
Function should never throw an exception |
3 |
True |
KT.EXIT_OUTSIDE_MAIN
|
Potential bugs |
Calls of System.exit() or exitProcess() outside the main function |
3 |
False |
KT.EXPLICIT_COLLECTION_ELEMENT_ACCESS_METHOD
|
Style of the code |
Usage of 'get' or 'set' can be replaced with indexed access operator [] |
3 |
False |
KT.EXPLICIT_GARBAGE_COLLECTION_CALL
|
Potential bugs |
Explicitly trigger the Garbage Collector |
3 |
True |
KT.EXPLICIT_IT_LAMBDA_PARAMETER
|
Style of the code |
Explicit 'it' lambda parameter |
3 |
True |
KT.EXPRESSION_BODY_SYNTAX
|
Style of the code |
Function only contains a return statement |
3 |
False |
KT.FILENAME
|
Formatting issues |
Top level class matches the filename |
3 |
True |
KT.FINAL_NEWLINE
|
Formatting issues |
Missing final newlines |
3 |
True |
KT.FORBIDDEN_CLASS_NAME
|
Naming of different parts of the codebase |
Class name is forbidden per configuration |
3 |
False |
KT.FORBIDDEN_COMMENT
|
Style of the code |
Comment which is forbidden in the codebase |
3 |
True |
KT.FORBIDDEN_IMPORT
|
Style of the code |
Forbidden import |
3 |
False |
KT.FORBIDDEN_METHOD_CALL
|
Style of the code |
Forbidden method call |
3 |
False |
KT.FORBIDDEN_PUBLIC_DATA_CLASS
|
Style of the code |
Data class in public APIs |
3 |
True |
KT.FORBIDDEN_SUPPRESS
|
Style of the code |
Usages of given rule are forbidden |
3 |
False |
KT.FORBIDDEN_VOID
|
Style of the code |
Usages of 'Void' are forbidden |
3 |
False |
KT.FOR_EACH_ON_RANGE
|
Potential performance problems |
Using the 'forEach' method on ranges |
3 |
True |
KT.FUNCTION_MAX_LENGTH
|
Naming of different parts of the codebase |
Very long function name |
3 |
False |
KT.FUNCTION_MIN_LENGTH
|
Naming of different parts of the codebase |
Very short function name |
3 |
False |
KT.FUNCTION_NAMING
|
Naming of different parts of the codebase |
Function name does not follow the specified naming convention |
3 |
True |
KT.FUNCTION_ONLY_RETURNING_CONSTANT
|
Style of the code |
Function only returning a single constant |
3 |
True |
KT.FUNCTION_PARAMETER_NAMING
|
Naming of different parts of the codebase |
Function parameter names do not follow the specified naming convention |
3 |
True |
KT.FUNCTION_TYPE_REFERENCE_SPACING
|
Formatting issues |
Inconsistent spacing in the type reference before a function |
3 |
False |
KT.FUN_KEYWORD_SPACING
|
Formatting issues |
Consistent spacing after the fun keyword |
3 |
False |
KT.GLOBAL_COROUTINE_USAGE
|
Potential coroutines problems |
Usage of GlobalScope instance |
3 |
False |
KT.HAS_PLATFORM_TYPE
|
Potential bugs |
Platform type is not declared explicitly in public API |
3 |
True |
KT.IGNORED_RETURN_VALUE
|
Potential bugs |
Function, annotated with either @CheckReturnValue or @CheckResult returns value which is not used |
3 |
True |
KT.IMPLICIT_DEFAULT_LOCALE
|
Potential bugs |
Implicit default locale |
3 |
True |
KT.IMPLICIT_UNIT_RETURN_TYPE
|
Potential bugs |
Functions using expression statements have an implicit return type |
3 |
False |
KT.IMPORT_ORDERING
|
Formatting issues |
Imports in non default order |
3 |
True |
KT.INDENTATION
|
Formatting issues |
Mis-indented code |
3 |
True |
KT.INJECT_DISPATCHER
|
Potential coroutines problems |
Hardcode dispatchers |
3 |
True |
KT.INSTANCE_OF_CHECK_FOR_EXCEPTION
|
Code throws and handles Exceptions |
Catch block checks for the type of exception via 'is' checks or casts |
3 |
True |
KT.INVALID_PACKAGE_DECLARATION
|
Naming of different parts of the codebase |
File location does not match the declared package |
3 |
True |
KT.INVALID_RANGE
|
Potential bugs |
Empty range |
3 |
True |
KT.ITERATOR_HAS_NEXT_CALLS_NEXT_METHOD
|
Potential bugs |
Side effect in hasNext() method of an Iterator implementation |
3 |
True |
KT.ITERATOR_NOT_THROWING_NO_SUCH_ELEMENT_EXCEPTION
|
Potential bugs |
Implementation of the Iterator interface does not throw a NoSuchElementException |
3 |
True |
KT.KDOC_WRAPPING
|
Formatting issues |
KDoc comment should not start on a line that contain elements |
3 |
False |
KT.K_DOC_REFERENCES_NON_PUBLIC_PROPERTY
|
Comments and documentation of the code |
KDoc comments refer to non-public properties of a class |
3 |
False |
KT.LABELED_EXPRESSION
|
Complex code |
Labeled expression increases complexity of code |
3 |
False |
KT.LAMBDA_PARAMETER_NAMING
|
Naming of different parts of the codebase |
Lambda parameter names do not follow the specified naming convention |
3 |
False |
KT.LARGE_CLASS
|
Complex code |
Large class |
3 |
True |
KT.LATEINIT_USAGE
|
Potential bugs |
Usage of the lateinit modifier |
3 |
False |
KT.LIBRARY_CODE_MUST_SPECIFY_RETURN_TYPE
|
Style of the code |
Public APIs doesn't have an explicit return type |
3 |
True |
KT.LIBRARY_ENTITIES_SHOULD_NOT_BE_PUBLIC
|
Style of the code |
Library entities are internal or private |
3 |
True |
KT.LONG_METHOD
|
Complex code |
Long method |
3 |
True |
KT.LONG_PARAMETER_LIST
|
Complex code |
Functions and constructors have more parameters than a certain threshold |
3 |
True |
KT.LOOP_WITH_TOO_MANY_JUMP_STATEMENTS
|
Style of the code |
Loops with multiple breaks or continue statements |
3 |
True |
KT.MAGIC_NUMBER
|
Style of the code |
Magic number in the code |
3 |
True |
KT.MANDATORY_BRACES_IF_STATEMENTS
|
Style of the code |
Multi-line 'if' statement with no braces |
3 |
False |
KT.MANDATORY_BRACES_LOOPS
|
Style of the code |
Multi-line loop which do not have braces |
3 |
False |
KT.MAP_GET_WITH_NOT_NULL_ASSERTION_OPERATOR
|
Potential bugs |
Call to 'map.get()' with a not-null assertion operator (!!) |
3 |
True |
KT.MATCHING_DECLARATION_NAME
|
Naming of different parts of the codebase |
Single non-private class is not named as file name |
3 |
True |
KT.MAXIMUM_LINE_LENGTH
|
Formatting issues |
Lines with exceeded length |
3 |
True |
KT.MAX_CHAINED_CALLS_ON_SAME_LINE
|
Style of the code |
Reached maximum chained calls on a single line. |
3 |
False |
KT.MAX_LINE_LENGTH
|
Style of the code |
Lines of code exceed maximum line length |
3 |
True |
KT.MAY_BE_CONST
|
Style of the code |
Properties (val) may be const val |
3 |
True |
KT.MEMBER_NAME_EQUALS_CLASS_NAME
|
Naming of different parts of the codebase |
Member has the same name as the containing class or object |
3 |
True |
KT.METHOD_OVERLOADING
|
Complex code |
Method with many overloads |
3 |
False |
KT.MISSING_PACKAGE_DECLARATION
|
Potential bugs |
Package declaration is missing |
3 |
False |
KT.MISSING_WHEN_CASE
|
Potential bugs |
Expression 'when' does not check that all cases are covered |
3 |
True |
KT.MODIFIER_LIST_SPACING
|
Formatting issues |
Inconsistent spacing between modifiers |
3 |
False |
KT.MODIFIER_ORDER
|
Style of the code |
Modifiers are not in the default order from coding-conventions |
3 |
True |
KT.MODIFIER_ORDERING
|
Formatting issues |
Modifiers in non default order |
3 |
True |
KT.MULTILINE_LAMBDA_IT_PARAMETER
|
Style of the code |
Multi-line lambda with explicit usages of the 'it' parameter |
3 |
False |
KT.MULTI_LINE_IF_ELSE
|
Formatting issues |
Multiline if-else statements without braces |
3 |
False |
KT.NAMED_ARGUMENTS
|
Complex code |
Function parameters are not named |
3 |
False |
KT.NESTED_BLOCK_DEPTH
|
Complex code |
Excessive nesting depth in functions |
3 |
True |
KT.NESTED_CLASSES_VISIBILITY
|
Style of the code |
Public nested class |
3 |
True |
KT.NESTED_SCOPE_FUNCTIONS
|
Complex code |
Nested scope functions |
3 |
False |
KT.NEW_LINE_AT_END_OF_FILE
|
Style of the code |
File does not end with a line separator |
3 |
True |
KT.NON_BOOLEAN_PROPERTY_PREFIXED_WITH_IS
|
Naming of different parts of the codebase |
Property with 'is' prefix doesn't have a boolean type |
3 |
False |
KT.NOT_IMPLEMENTED_DECLARATION
|
Code throws and handles Exceptions |
Exception of the type NotImplementedError |
3 |
False |
KT.NO_BLANK_LINE_BEFORE_RBRACE
|
Formatting issues |
Blank lines before rbraces |
3 |
True |
KT.NO_CONSECUTIVE_BLANK_LINES
|
Formatting issues |
Consecutive blank lines |
3 |
True |
KT.NO_EMPTY_CLASS_BODY
|
Formatting issues |
Empty class bodies |
3 |
True |
KT.NO_EMPTY_FIRST_LINE_IN_METHOD_BLOCK
|
Formatting issues |
Method that have an empty first line |
3 |
False |
KT.NO_LINE_BREAK_AFTER_ELSE
|
Formatting issues |
Line breaks after 'else' |
3 |
True |
KT.NO_LINE_BREAK_BEFORE_ASSIGNMENT
|
Formatting issues |
Line breaks before assignment |
3 |
True |
KT.NO_MULTIPLE_SPACES
|
Formatting issues |
Multiple space usages |
3 |
True |
KT.NO_NAME_SHADOWING
|
Naming of different parts of the codebase |
Shadowing variable declarations |
3 |
False |
KT.NO_SEMICOLONS
|
Formatting issues |
Semicolon usage |
3 |
True |
KT.NO_TABS
|
Style of the code |
Tabs are used in the source file |
3 |
False |
KT.NO_TRAILING_SPACES
|
Formatting issues |
Trailing spaces |
3 |
True |
KT.NO_UNIT_RETURN
|
Formatting issues |
Optional 'Unit' return types |
3 |
True |
KT.NO_UNUSED_IMPORTS
|
Formatting issues |
Unused imports |
3 |
True |
KT.NO_WILDCARD_IMPORTS
|
Formatting issues |
Wildcast import usages |
3 |
True |
KT.NULLABLE_BOOLEAN_CHECK
|
Style of the code |
Nullable boolean check |
3 |
False |
KT.NULLABLE_TO_STRING_CALL
|
Potential bugs |
Method 'toString' with a nullable receiver that may return the string 'null' |
3 |
False |
KT.NULL_CHECK_ON_MUTABLE_PROPERTY
|
Potential bugs |
null-checks on mutable property |
3 |
False |
KT.OBJECT_EXTENDS_THROWABLE
|
Code throws and handles Exceptions |
Object that extend any type of Throwable |
3 |
False |
KT.OBJECT_LITERAL_TO_LAMBDA
|
Style of the code |
Anonymous object with implementation of a single method |
3 |
True |
KT.OBJECT_PROPERTY_NAMING
|
Naming of different parts of the codebase |
Property names inside objects do not follow the specified naming convention |
3 |
True |
KT.OPTIONAL_ABSTRACT_KEYWORD
|
Style of the code |
Unnecessary abstract modifier |
3 |
True |
KT.OPTIONAL_UNIT
|
Style of the code |
Return type of 'Unit' |
3 |
False |
KT.OPTIONAL_WHEN_BRACES
|
Style of the code |
Unnecessary braces in 'when' expressions |
3 |
False |
KT.OUTDATED_DOCUMENTATION
|
Comments and documentation of the code |
Class, function or constructor with KDoc does not match the declaration signature |
3 |
False |
KT.PACKAGE_NAME
|
Formatting issues |
Package name is formatted correctly |
3 |
False |
KT.PACKAGE_NAMING
|
Naming of different parts of the codebase |
Package name does not follow the specified naming convention |
3 |
True |
KT.PARAMETER_LIST_WRAPPING
|
Formatting issues |
Mis-aligned parameter lists |
3 |
True |
KT.PREFER_TO_OVER_PAIR_SYNTAX
|
Style of the code |
Usage of the 'Pair()' constructor |
3 |
False |
KT.PRINT_STACK_TRACE
|
Code throws and handles Exceptions |
Print the stacktrace of an exception |
3 |
True |
KT.PROTECTED_MEMBER_IN_FINAL_CLASS
|
Style of the code |
Protected member in final class |
3 |
True |
KT.REDUNDANT_ELSE_IN_WHEN
|
Potential bugs |
Redundant 'else' case in 'when' expression |
3 |
True |
KT.REDUNDANT_EXPLICIT_TYPE
|
Style of the code |
Local properties type is explicitly provided |
3 |
False |
KT.REDUNDANT_HIGHER_ORDER_MAP_USAGE
|
Style of the code |
Redundant 'map' call |
3 |
True |
KT.REDUNDANT_SUSPEND_MODIFIER
|
Potential coroutines problems |
Usage of 'suspend' modifier |
3 |
True |
KT.REDUNDANT_VISIBILITY_MODIFIER_RULE
|
Style of the code |
Redundant visibility modifier |
3 |
False |
KT.REPLACE_SAFE_CALL_CHAIN_WITH_RUN
|
Complex code |
Chains of safe calls on non-nullable types |
3 |
False |
KT.RETHROW_CAUGHT_EXCEPTION
|
Code throws and handles Exceptions |
Exception that are caught and then later re-thrown without modification |
3 |
True |
KT.RETURN_COUNT
|
Style of the code |
Method exceed the number of 'return' statements |
3 |
True |
KT.RETURN_FROM_FINALLY
|
Code throws and handles Exceptions |
Return statement in finally blocks |
3 |
True |
KT.SAFE_CAST
|
Style of the code |
Casts should be replaced with safe casts |
3 |
True |
KT.SERIAL_VERSION_U_I_D_IN_SERIALIZABLE_CLASS
|
Style of the code |
Serializable class does not declare a correct serialVersionUID |
3 |
True |
KT.SLEEP_INSTEAD_OF_DELAY
|
Potential coroutines problems |
Usages of 'Thread.sleep' in suspending functions and coroutine blocks |
3 |
True |
KT.SPACING_AROUND_ANGLE_BRACKETS
|
Formatting issues |
Spaces around angle brackets |
3 |
False |
KT.SPACING_AROUND_COLON
|
Formatting issues |
Spaces around colons |
3 |
True |
KT.SPACING_AROUND_COMMA
|
Formatting issues |
Spaces around commas |
3 |
True |
KT.SPACING_AROUND_CURLY
|
Formatting issues |
Spaces around curly braces |
3 |
True |
KT.SPACING_AROUND_DOT
|
Formatting issues |
Spaces around member invocation operator (dot) |
3 |
True |
KT.SPACING_AROUND_DOUBLE_COLON
|
Formatting issues |
Spaces around double colons |
3 |
False |
KT.SPACING_AROUND_KEYWORD
|
Formatting issues |
Spaces around keywords |
3 |
True |
KT.SPACING_AROUND_OPERATORS
|
Formatting issues |
Spaces around operators |
3 |
True |
KT.SPACING_AROUND_PARENS
|
Formatting issues |
Spaces around parentheses |
3 |
True |
KT.SPACING_AROUND_RANGE_OPERATOR
|
Formatting issues |
Spaces around range operator |
3 |
True |
KT.SPACING_AROUND_UNARY_OPERATOR
|
Formatting issues |
Spaces around unary operator |
3 |
False |
KT.SPACING_BETWEEN_DECLARATIONS_WITH_ANNOTATIONS
|
Formatting issues |
Declarations and declarations with annotations should have an empty space between |
3 |
False |
KT.SPACING_BETWEEN_DECLARATIONS_WITH_COMMENTS
|
Formatting issues |
Declarations and declarations with comments should have an empty space between |
3 |
False |
KT.SPACING_BETWEEN_PACKAGE_AND_IMPORTS
|
Style of the code |
Spacing needed between package and import statements |
3 |
False |
KT.SPREAD_OPERATOR
|
Potential performance problems |
Usage of a spread operator |
3 |
True |
KT.STRING_LITERAL_DUPLICATION
|
Complex code |
Duplicate String literal |
3 |
False |
KT.STRING_TEMPLATE
|
Formatting issues |
Simplification in template strings |
3 |
True |
KT.SUSPEND_FUN_WITH_COROUTINE_SCOPE_RECEIVER
|
Potential coroutines problems |
Functions that use CoroutineScope as receive are marked as suspend |
3 |
False |
KT.SUSPEND_FUN_WITH_FLOW_RETURN_TYPE
|
Potential coroutines problems |
Functions that return Flow from 'kotlinx.coroutines.flow' are marked as suspend |
3 |
True |
KT.SWALLOWED_EXCEPTION
|
Code throws and handles Exceptions |
Exception is caught and not correctly passed into a newly thrown exception |
3 |
True |
KT.THROWING_EXCEPTIONS_WITHOUT_MESSAGE_OR_CAUSE
|
Code throws and handles Exceptions |
Exception without arguments or further description |
3 |
True |
KT.THROWING_EXCEPTION_FROM_FINALLY
|
Code throws and handles Exceptions |
Exception thrown from a finally block |
3 |
True |
KT.THROWING_EXCEPTION_IN_MAIN
|
Code throws and handles Exceptions |
Exception thrown in a main method |
3 |
False |
KT.THROWING_NEW_INSTANCE_OF_SAME_EXCEPTION
|
Code throws and handles Exceptions |
Exception wrapped inside the same exception type and then rethrown |
3 |
True |
KT.THROWS_COUNT
|
Style of the code |
Method exceed the number of 'throw' statements |
3 |
True |
KT.TOO_GENERIC_EXCEPTION_CAUGHT
|
Code throws and handles Exceptions |
Catch block for exceptions that have a type that is too generic |
3 |
True |
KT.TOO_GENERIC_EXCEPTION_THROWN
|
Code throws and handles Exceptions |
Thrown exception that have a type that is too generic |
3 |
True |
KT.TOO_MANY_FUNCTIONS
|
Complex code |
Too many functions |
3 |
True |
KT.TOP_LEVEL_PROPERTY_NAMING
|
Naming of different parts of the codebase |
Top level constant does not follow the specified naming convention |
3 |
True |
KT.TRAILING_COMMA
|
Formatting issues |
Removal or adding of trailing comma |
3 |
False |
KT.TRAILING_WHITESPACE
|
Style of the code |
Line with trailing whitespace |
3 |
False |
KT.TYPE_ARGUMENT_LIST_SPACING
|
Formatting issues |
Inconsistent spacing in type argument list |
3 |
False |
KT.UNCONDITIONAL_JUMP_STATEMENT_IN_LOOP
|
Potential bugs |
Loops contains jump statements that jump regardless of any conditions |
3 |
False |
KT.UNDERSCORES_IN_NUMERIC_LITERALS
|
Style of the code |
Long base 10 numbers not separated with underscores |
3 |
False |
KT.UNDOCUMENTED_PUBLIC_CLASS
|
Comments and documentation of the code |
Public classes, objects and interfaces do not have the required documentation |
3 |
False |
KT.UNDOCUMENTED_PUBLIC_FUNCTION
|
Comments and documentation of the code |
Public function does not have the required documentation |
3 |
False |
KT.UNDOCUMENTED_PUBLIC_PROPERTY
|
Comments and documentation of the code |
Public property does not have the required documentation |
3 |
False |
KT.UNNECESSARY_ABSTRACT_CLASS
|
Style of the code |
Unnecessary abstract class |
3 |
True |
KT.UNNECESSARY_ANNOTATION_USE_SITE_TARGET
|
Style of the code |
Unnecessary Annotation use-site Target |
3 |
False |
KT.UNNECESSARY_APPLY
|
Style of the code |
Unnecessary 'apply' expression |
3 |
True |
KT.UNNECESSARY_BACKTICKS
|
Style of the code |
Unnecessary backticks |
3 |
False |
KT.UNNECESSARY_FILTER
|
Style of the code |
Unnecessary 'filter()' call |
3 |
True |
KT.UNNECESSARY_INHERITANCE
|
Style of the code |
Unnecessary super type |
3 |
True |
KT.UNNECESSARY_INNER_CLASS
|
Style of the code |
Unnecessary inner class |
3 |
False |
KT.UNNECESSARY_LET
|
Style of the code |
Unnecessary 'let' expression |
3 |
False |
KT.UNNECESSARY_NOT_NULL_OPERATOR
|
Potential bugs |
Unnecessary not-null operator (!!) |
3 |
True |
KT.UNNECESSARY_PARENTHESES
|
Style of the code |
Unnecessary parentheses around expressions |
3 |
False |
KT.UNNECESSARY_PARENTHESES_BEFORE_TRAILING_LAMBDA
|
Formatting issues |
An empty parentheses block before a lambda |
3 |
False |
KT.UNNECESSARY_SAFE_CALL
|
Potential bugs |
Unnecessary safe call operator (?.) |
3 |
True |
KT.UNNECESSARY_TEMPORARY_INSTANTIATION
|
Potential performance problems |
Temporary objects when converting primitive types to String |
3 |
True |
KT.UNREACHABLE_CATCH_BLOCK
|
Potential bugs |
Unreachable 'catch' block |
3 |
True |
KT.UNREACHABLE_CODE
|
Potential bugs |
Unreachable code |
3 |
True |
KT.UNSAFE_CALL_ON_NULLABLE_TYPE
|
Potential bugs |
Unsafe call on nullable types |
3 |
True |
KT.UNSAFE_CAST
|
Potential bugs |
Cast that will never succeed |
3 |
True |
KT.UNTIL_INSTEAD_OF_RANGE_TO
|
Style of the code |
Call to '..' operator can be replaced with 'until' |
3 |
False |
KT.UNUSED_IMPORTS
|
Style of the code |
Unused import |
3 |
False |
KT.UNUSED_PRIVATE_CLASS
|
Style of the code |
Unused private class |
3 |
True |
KT.UNUSED_PRIVATE_MEMBER
|
Style of the code |
Unused private member |
3 |
True |
KT.UNUSED_UNARY_OPERATOR
|
Potential bugs |
Unused unary operator |
3 |
True |
KT.USELESS_CALL_ON_NOT_NULL
|
Style of the code |
Useless call on non-null reference |
3 |
True |
KT.USELESS_POSTFIX_EXPRESSION
|
Potential bugs |
Postfix expressions (++, --) are unused and thus unnecessary |
3 |
True |
KT.USE_ANY_OR_NONE_INSTEAD_OF_FIND
|
Style of the code |
Call for null check can be replaced with 'any' or 'none' call |
3 |
True |
KT.USE_ARRAY_LITERALS_IN_ANNOTATIONS
|
Style of the code |
Annotation uses the 'arrayOf(...)' syntax instead of the array literal '[...]' syntax |
3 |
True |
KT.USE_CHECK_NOT_NULL
|
Style of the code |
Call for not-null check can be replaced with a 'checkNotNull()' call |
3 |
True |
KT.USE_CHECK_OR_ERROR
|
Style of the code |
Invariant check throws an IllegalStateException |
3 |
True |
KT.USE_DATA_CLASS
|
Style of the code |
Use data class |
3 |
False |
KT.USE_EMPTY_COUNTERPART
|
Style of the code |
Use object's 'empty' initializer |
3 |
False |
KT.USE_IF_EMPTY_OR_IF_BLANK
|
Style of the code |
Use 'ifEmpty' or 'ifBlank' |
3 |
False |
KT.USE_IF_INSTEAD_OF_WHEN
|
Style of the code |
Use 'if' instead of 'when' |
3 |
False |
KT.USE_IS_NULL_OR_EMPTY
|
Style of the code |
Null or empty check can be replaced with 'isNullOrEmpty()' call |
3 |
True |
KT.USE_OR_EMPTY
|
Style of the code |
Call '?: emptyList()' can be replaced with 'orEmpty()' |
3 |
True |
KT.USE_REQUIRE
|
Style of the code |
Use 'require()' instead of manually throwing an IllegalArgumentException |
3 |
True |
KT.USE_REQUIRE_NOT_NULL
|
Style of the code |
Not-null check can be replaced with a 'requireNotNull()' call |
3 |
True |
KT.UTILITY_CLASS_WITH_PUBLIC_CONSTRUCTOR
|
Style of the code |
Utility class with public constructor or not final |
3 |
True |
KT.VARIABLE_MAX_LENGTH
|
Naming of different parts of the codebase |
Very long variable name |
3 |
False |
KT.VARIABLE_MIN_LENGTH
|
Naming of different parts of the codebase |
Very short variable name |
3 |
False |
KT.VARIABLE_NAMING
|
Naming of different parts of the codebase |
Variable name does not follow the specified naming convention |
3 |
True |
KT.VAR_COULD_BE_VAL
|
Style of the code |
Var declaration that could be val |
3 |
True |
KT.WILDCARD_IMPORT
|
Style of the code |
Wildcard import |
3 |
True |
KT.WRAPPING
|
Formatting issues |
Wrong indentation |
3 |
True |
KT.WRONG_EQUALS_TYPE_PARAMETER
|
Potential bugs |
MEthod 'equals()' takes in a wrongly typed parameter |
3 |
True |