Inspectopedia 2024.3 Help

New Inspections in This Release

Angular2

Name

Description

Incorrect usage of @let declaration

Reports problems with @let declaration usages.

Unsupported Angular expression syntax

Reports problems with Angular expression syntax, which is not supported in an older version of Angular.

Angular2html

Name

Description

Incorrect usage of Angular block

Reports problems with Angular blocks.

Non-iterable type in @for block

Reports that the type of variable to iterate over does not have [Symbol.iterator]() method, which returns an iterator.

Problems with @defer `on` triggers

Reports issues with triggers in `on` parameters in `@defer` block.

Aoptarget

Name

Description

Advice parameters (argNames, returning, throwing) consistency check

Reports if an @AspectJ argNames attribute value does not correspond to the actual method parameter name.

Around advice style inspection

When using @Around advice, remember two things: Calling org.aspectj.lang.ProceedingJoinPoint#proceed is necessary, otherwise the call won't reach the target.

Introductions (declare parents) errors

Reports @AspectJ Introduction inconsistency: it checks whether the defaultImpl is required and if yes, whether it implements the given interface.

Pointcut method style

Validates @Pointcut methods: the void return type, no throws clause, and an empty method body.

Warning: argNames not defined

Reports if an argNames attribute is not defined in an @AspectJ annotation.

Blade

Name

Description

Control directive missing

Reports the Blade control directives that are not closed with the corresponding @end..

C#

Name

Description

Check .NET source code coverage

Reports methods, classes and files whose coverage is below a certain threshold.

CSS

Name

Description

Color could be replaced with #-hex

Reports an rgb(), hsl(), or other color function.

Color could be replaced with rgb()

Reports an hsl() or hwb() color function or a hexadecimal color notation.

Deprecated value

Reports a deprecated CSS value.

Invalid @property declaration

Reports a missing required syntax, inherits, or initial-value property in a declaration of a custom property.

Invalid @property name

Reports an invalid custom property name.

Invalid function

Reports an unknown CSS function or an incorrect function parameter.

Invalid media feature

Reports an unknown CSS media feature or an incorrect media feature value.

Invalid nested selector

Reports a nested selector starting with an identifier or a functional notation.

Invalid property value

Reports an incorrect CSS property value.

Invalid pseudo-selector

Reports an incorrect CSS pseudo-class pseudo-element.

Invalid type selector

Reports a CSS type selector that matches an unknown HTML element.

Misplaced @import

Reports a misplaced @import statement.

Misplaced or incorrect @charset

Reports a misplaced @charset at-rule or an incorrect charset value.

Missing comma in selector list

Reports a multi-line selector.

Missing generic font family name

Verifies that the font-family property contains a generic font family name as a fallback alternative.

Missing semicolon

Reports a missing semicolon at the end of a declaration.

Negative property value

Reports a negative value of a CSS property that is not expected to be less than zero, for example, object width or height.

Non-integer length in pixels

Reports a non-integer length in pixels.

Overwritten property

Reports a duplicated CSS property within a ruleset.

Properties may be safely replaced with a shorthand

Reports a set of longhand properties.

Properties may probably be replaced with a shorthand

Reports a set of longhand CSS properties and suggests replacing an incomplete set of longhand CSS properties with a shorthand form, which is however not 100% equivalent in this case.

Property is incompatible with selected browsers

Reports a CSS property that is not supported by the specified browsers.

Redundant measure unit

Reports a measure unit of a zero value where units are not required by the specification.

Stylelint

Reports a discrepancy detected by the Stylelint linter.

Unknown at-rule

Reports an unknown CSS at-rule.

Unknown property

Reports an unknown CSS property or a property used in a wrong context.

Unknown unit

Reports an unknown unit.

Unresolved class in 'composes' rule

Reports a CSS class reference in the 'composes' rule that cannot be resolved to any valid target.

Unresolved custom property

Reports an unresolved reference to a custom property among the arguments of the var() function.

Unused selector

Reports a CSS class or an element IDs that appears in selectors but is not used in HTML.

W3C CSS validator

Reports a discrepancy detected by the W3C CSS Validator.

Cmake

Name

Description

Deprecated command used

Reports a usage of a deprecated command.

Mismatched command arguments

Reports mismatched arguments in opening- and closing commands.

Coffeescript

Name

Description

Missing import statement

Reports a module that is not referenced through an import statement.

Commandline

Name

Description

Incorrect CLI syntax

Reports the problems if the arguments of the command you type in the console are not in the proper order.

Cronexp

Name

Description

Validate Cron expression

Reports invalid cron expression.

Cython

Name

Description

Cython variable is used before its declaration

Reports Cython variables being referenced before declaration.

DTS

Name

Description

Duplicate element

Reports duplicated elements inside a node.

Invalid array element size

Reports invalid array element size.

Invalid entry location

Reports if an entry is not valid in its current location.

Invalid entry order

Reports if property and node entries are in the wrong order.

Invalid node name

Reports invalid node names.

Invalid property name

Reports invalid property names.

Invalid property type

Reports properties with invalid type.

Invalid property value (const)

Reports const properties with invalid values.

Invalid property value (enum)

Reports enum properties with invalid values.

Invalid unit name

Reports invalid unit names inside node names.

Preprocessor parser

Displays preprocessor parser errors.

Required properties

Reports missing required properties.

Undeclared property

Reports undeclared properties.

Djangotemplate

Name

Description

Broken line comment

Reports #} line comment ends in Django templates that do not have a matching line comment start.

Django endblock name doesn't match the block name

Reports incorrect names of the closing blocks.

Django {% url %} tag arguments are unresolved

Reports a missing url in the url tag.

Duplicated block names

Reports duplicated block names in Django templates.

Incompatible code in Django templates

Reports features that are not available in the current Django version.

Incorrect arguments in the ' {% url %}' tag

Reports missing parameters in the template file if the url() function has parameters in its URL path.

Incorrect comparison expression in Django templates

Reports missing whitespaces before and after comparison operators in Django templates.

Mismatched opening and closing tags

Reports cases when opening tags in Django templates are not correctly matched by closing tags.

Misplaced {% extends %} tag

Reports the {% extends %} tag that is not the first tag in a Django template.

Unresolved filter

Reports unresolved filters in Django templates.

Unresolved library inspection

Reports unresolved references in Django load tags.

Unresolved static reference

Reports unresolved references to static resources.

Unresolved tag

Reports unresolved tags in Django templates.

Unresolved template reference

Reports unresolved file references in string literals of extends> and include> Django tags.

Dockerfile

Name

Description

A single quoted string in JSON array format

Reports a single quoted string in JSON array format.

Invalid destination for ''ADD''/''COPY'' commands

Reports invalid destination directories in ADD and COPY commands.

Invalid spaces in ''key=value'' pair

Reports incorrect spacing for key-value pairs in ARG, ENV, and LABEL commands.

Missing continuation character for ''RUN'' command

Reports missing continuation characters in RUN command.

Wrong number of arguments

Reports invalid number of arguments for the Dockerfile commands.

EL

Name

Description

EL deferred expressions inspection

Reports dynamic expressions where deferred expressions are expected and vice versa.

EL method function parameters count

Reports different number of formal and actual parameters in EL function call.

EL method signature inspection

Reports method calls in EL that don't match method-signature constraints in TLD files.

EL validation

Reports possible EL problems, such as unresolved references and invalid EL locations.

JSP EL specification validation

Reports possible problems caused by non-standard EL extensions: JSF EL expressions outside attributes, non-standard EL expressions, and so on.

Unescaped EL Expressions

Reports non-safe data in unescaped EL expressions in JSP pages.

Ecmascript 6

Name

Description

Use of possibly unassigned property in a static initializer

Reports a class member initializer which references another non-hoisted class member while the latter may be not initialized yet.

Editorconfig

Name

Description

Deprecated property

Reports EditorConfig properties that are no longer supported.

Duplicate character class letter

Reports wildcard patterns in the EditorConfig section that contain a duplicate character in the character class, for example [aa].

Duplicate or redundant pattern

Reports file patterns that are redundant as there already are other patterns that define the same scope of files or even a broader one.

EditorConfig section is not unique

Reports sections that define the same file pattern as other sections.

Empty header

Reports sections with an empty header.

Empty section

Reports sections that do not contain any EditorConfig properties.

Extra top-level declaration

Reports multiple top-level declarations.

Invalid .editorconfig file

Verifies the whole file using the backing EditorConfig core library and reports any failures.

Invalid reference

Reports identifiers that are either unknown or have a wrong type.

No matching files

Reports sections with wildcard patterns that do not match any files under the directory in which the .editorconfig file is located.

Non-unique list value

Reports duplicates in lists of values.

Overlapping sections

Reports subsets of files specified in the current section that overlap with other subsets in other sections.

Overridden property

Reports properties that are already defined in other sections.

Overriding property

Reports properties that override the same properties defined earlier in the file.

Redundant property

Reports properties that are redundant when another applicable section already contains the same property and value.

Redundant wildcard

Reports wildcards that become redundant when the “** ” wildcard is used in the same section.

Required declarations are missing

Reports properties that miss the required declarations.

Space in file pattern

Reports space characters in wildcard patterns that affect pattern matching.

Too many wildcards

Reports sections that contain too many wildcards.

Unexpected comma

Reports commas that cannot be used in the current context.

Unexpected key-value pair

Reports key-value pairs that are not allowed in the current context.

Unexpected top-level declaration

Reports unexpected top-level declarations.

Unexpected value list

Reports lists of values that are used in properties in which lists are not supported.

Unnecessary braces

Reports pattern lists that are either empty {} or contain just one pattern, for example {foo} in contrast to a list containing multiple patterns, for example {foo,bar}.

Unnecessary character class

Reports character classes that consist of a single character.

Unused declaration

Reports unused declarations.

FTL

Name

Description

Built-in errors

Reports FreeMarker language errors.

Built-in is deprecated

Reports deprecated built-ins (for example, default, exists, if_exists, web_safe).

Directive is malformed

Reports malformed FreeMarker directives (for example, wrong nesting, missing closing tags, and so on).

Incorrect expression type

Reports incorrect FreeMarker expression types.

Invalid call directive

Reports FreeMarker calls that do not match the macro declaration (for example, missing parameters, wrong type, and so on).

Unresolved external call

Reports unresolved #macro and #function directives located in other files.

Flow js

Name

Description

Misplaced @flow flag

Reports a @flow flag comment that is not located at the top of a file.

Missing .flowconfig

Reports a JavaScript file with a @flow flag that doesn't have an associated .flowconfig file in the project.

Gherkin

Name

Description

Gherkin table is broken

Reports a table if there is at least one row with the number of cells different from the number of cells in the table header.

Misplaced background section

Reports Background sections that are located incorrectly.

Missing ':' after examples keyword

Reports Examples sections in Cucumber .feature files if they do not have ':' after the Examples keyword.

Missing examples section

Reports scenario outlines in Cucumber .feature files that do not have the Examples section.

Scenario with Examples section

Reports Gherkin scenarios that contain an Examples section.

Undefined step

Reports steps in Cucumber (or some other Gherkin) .feature files that do not have matching step definitions.

Unused or missing columns in Cucumber tables

Reports tables in Examples sections in Cucumber .feature files with unused or missing columns.

Githubexpressionlanguage

Name

Description

Standard library functions validation

Reports invalid GitHub Actions Expression language standard library function calls For more information on GitHub Actions Expression language, see the GitHub documentation.

Gotemplate

Name

Description

Duplicate variable

Reports duplicate Go Template variables that are declared in the same scope.

Unknown variable

Reports usages of unknown variables in Go Templates.

Unknown/undeclared Helm properties

Reports invalid value references in Helm template files.

Unknown/undefined Helm templates

Reports invalid user-defined template references in Helm template files.

Groovy

Name

Description

'continue' or 'break' from 'finally' block

Reports break and continue statements inside of finally blocks.

'notify()' or 'notifyAll()' while not synced

Reports calls to notify() and notifyAll() not within a corresponding synchronized statement or synchronized method.

'return' statement can be implicit

Reports return statements at the end of closures which can be made implicit.

'wait()' not in loop

Reports calls to wait() not made inside a loop.

'wait()' while not synced

Reports calls to wait() not made inside a corresponding synchronized statement or synchronized method.

@DelegatesTo

Reports unused @DelegatesTo.Target annotations and unresolved @DelegatedTo.target annotation attribute values.

@NamedVariant/@NamedParam/@NamedDelegate unresolved label

Reports unresolved argument labels in calls of methods annotated by @NamedVariant/@NamedParam/@NamedDelegate.

@POJO without @CompileStatic

Reports annotation @groovy.transform.stc.POJO applied without @groovy.transform.CompileStatic.

@Singleton constructors

Reports constructors of classes annotated by @Singleton unless it is declared non-strict.

@TupleConstructor and @MapConstructor

Reports unresolved identifiers in @TupleConstructor and @MapConstructor includes and excludes annotation attribute values.

Access to static field locked on instance data

Reports accesses to a non-constant static field which is locked on either this or an instance field of this.

Bintray publishing plugin may stop working on May 1st, 2021

Detects usages of Gradle plugin com.jfrog.bintray.

Builds will no longer be able to resolve artifacts from JCenter after February 1st, 2022

Detects usages of the JCenter repository to resolve dependencies.

Call to List.get can be keyed access

Reports calls to java.util.List.get() methods.

Call to List.set can be keyed access

Reports calls to java.util.List.set() methods.

Call to Map.get can be keyed access

Reports calls to java.util.Map.get() methods.

Call to Map.put can be keyed access

Reports calls to java.util.Map.put() methods.

Call to System.runFinalizersOnExit()

Reports calls to System.runFinalizersOnExit().

Call to Thread.stop(), Thread.suspend(), or Thread.resume()

Reports calls to Thread.stop(),Thread.suspend(), or Thread.resume().

Clashing getters

Reports boolean methods which can be accessed via the same property name.

Clashing trait methods

Reports classes which implement two or more traits that contain methods with same signatures.

Constant if statement

Reports if statements with boolean constant as a condition.

Deprecated library is used in Gradle

Reports deprecated dependencies in Gradle build scripts.

Duplicate switch case

Reports duplicated expressions in case labels for switch statements.

Empty 'synchronized' block

Reports synchronized statements with empty bodies.

Exhaustiveness check for switch expressions

Reports switch expressions that do not cover all possible outcomes of the matched expression.

Final variable access

Reports uninitialized final fields, invalid assignments to final variables, and parameters and fields.

GString map key

Reports statements which use a groovy.lang.GString object as a key to map.

If statement with identical branches

Reports if statements with identical "then" and else branches.

If statement with too many branches

Reports if statements with too many branches.

Implicit null argument

Reports calls with no arguments to method that has exactly one parameter.

Inaccessible element

Reports references which exceed access rights.

Incompatible 'in' argument types

Reports usages of membership operator in with items and containers of incompatible types.

Incompatible kotlinx.coroutines dependency is used with Kotlin 1.3+ in Gradle

Reports kotlinx.coroutines library dependencies in Gradle that should be updated to be compatible with Kotlin 1.3+.

Incompatible type assignments

Reports assignments with incompatible types.

Incorrect range arguments

Reports types used in ranges that do not have a next() or previous() method or do not implement the java.lang.Comparable interface.

Instance method naming convention

Reports instance methods whose names are too short, too long, or do not follow the specified regular expression pattern.

Instance variable naming convention

Reports instance variables whose names are too short, too long, or do not follow the specified regular expression pattern.

Java-style property access

Reports properties accessed via method calls.

Kotlin Gradle and IDE plugins versions are different

Reports that Gradle plugin version isn't properly supported in the current IDE plugin.

Kotlin library and Gradle plugin versions are different

Reports different Kotlin stdlib and compiler versions.

Labeled statement inspection

Reports labels already used in parent workflow.

Local variable is reassigned in closure or anonymous class

Reports local variables assigned to expression with different type inside of closure or anonymous class.

Method call can be replaced with operator invocation

Reports method calls that can be replaced with operator invocations.

Multiple repository urls

Reports the usage of multiple URLs per repository (maven or ivy) block.

Named arguments of constructor call

Reports named arguments of a default class constructor call which don't correspond to properties of this class.

Negated if condition expression

Reports if statements which contain else branches and whose conditions are negated.

Nested switch statement

Reports switch statements that are nested inside other switch statements.

New instance of class annotated with @groovy.lang.Singleton

Reports new instance creation of classes annotated with @groovy.lang.Singleton.

Non short-circuit boolean

Reports the non-short-circuit forms of boolean operators 'and' and 'or' ( & and | ).

Non-extending permitted subclasses

Reports permitted classes that do not extend the sealed base class.

Non-private field accessed in synchronized context

Reports non-final, non-private fields which are accessed in a synchronized context.

Operator invocation can be replaced with method call

Reports operator invocations that can be replaced with method calls.

Package mismatch

Reports files with a declared package that does not match the package expected.

Second unsafe call

Reports possible NullPointerException during chain methods or properties call.

Silly assignment

Reports assignments of a variable to itself.

Static method naming convention

Reports static methods whose names are too short, too long, or do not follow the specified regular expression pattern.

Static variable naming convention

Reports static variables whose names are too short, too long, or do not follow the specified regular expression pattern.

String style violation

Reports strings with quotation that doesn't match code style.

Switch statement with no default case

Reports switch statements that do not contain default labels.

Synchronization on non-final field

Reports synchronized statements where the lock expression is a non-final field.

Synchronization on variable initialized with literal

Reports synchronized blocks which lock on an object which is initialized with a literal.

Synchronized method

Reports the synchronized modifier on methods.

Ternary expression

Reports ternary expressions.

Ternary expression can be replaced with elvis expression

Reports ternary expressions which can be replaced by an elvis expression.

Ternary expression can be replaced with safe call

Reports ternary expressions which can be replaced by a safe call.

Ternary expression with identical branches

Reports ternary expressions with identical "then" and "else" branches.

Type customizer inspection

Reports files which can be custom type checkers and are not added to compiler resources yet.

Unchecked assignment from members of raw type

Reports unchecked assignments from members of raw type.

Unconditional 'wait' call

Reports wait() being called unconditionally within a synchronized context.

Unnecessary 'def'

Reports unnecessary def modifiers when used with explicit type declaration.

Unnecessary 'final'

Reports unnecessary final modifiers when used with the record definition.

Unnecessary 'non-sealed' modifier

Reports unnecessary non-sealed modifiers which used on methods, fields, or variables.

Unnecessary 'public'

Reports unnecessary public modifiers as Groovy classes and methods are public by default.

Unnecessary 'sealed' modifier

Reports unnecessary sealed modifiers which used on methods, fields, or variables.

Unnecessary import alias

Reports unnecessary import aliases.

Unnecessary qualified reference

Reports fully qualified references, which can be replaced with import.

Unresolved GroovyDoc reference

Reports unresolved references inside GroovyDoc comments.

Unresolved reference expression

Reports reference expressions which cannot be resolved.

Unsynchronized method overrides synchronized method

Reports non-synchronized methods overriding synchronized methods.

Untyped reference expression

Reports reference expressions whose type can't be determined.

Unused incrementing or decrementing

Reports unused incrementing and decrementing expressions.

Variable can be final

Reports parameters or local variables that may have a final modifier added.

Variable not assigned

Reports variables that might not have been initialized.

While loop spins on field

Reports while loops, which spin on the value of a non-volatile field, waiting for it to be changed by another thread.

HCL

Name

Description

Conflicting properties

Reports conflicting properties in an HCL block.

Deprecated blocks/properties

Reports deprecated blocks or properties.

Duplicated output

Reports duplicate outputs.

Duplicated property

Reports duplicate properties inside one block.

Duplicated provider

Reports duplicate providers.

Duplicated variable

Reports duplicate variables.

HIL expression can be converted to HCL2

Reports old style HCL expressions and suggests converting them to HCL2 expressions.

Illegal interpolation

Reports illegal interpolations.

Incorrect .tfvars content

Reports errors in vars files.

Incorrect variable type

Reports incorrect variable type.

Invalid block names

Reports invalid block labels or incorrect number of labels according to the schema.

Invalid string and number literal

Reports string and number invalid literals.

Missing required property

Reports blocks with missing required properties.

Suboptimal expression

Reports suboptimal HCL2 expressions and suggests simplifications.

Terraform isn't initialized

Reports if terraform was not initialized in the current working directory.

Unknown block type

Reports blocks with an unknown type (first literal).

Unknown encryption key provider

Detects non-existing encryption key providers references in OpenTofu encryption block configuration.

Unknown encryption method

Detects non-existing encryption methods references in OpenTofu encryption block configuration.

Unknown resource type

Detects resources/datasources that cannot be resolved against known providers.

Unresolved module

Reports unresolved modules and suggests running terraform get to update the modules.

Unused elements

Reports unused variables, locals, and data sources in a Terraform module and provides a quick-fix to remove them.

HIL

Name

Description

Operation argument type mismatch

Reports operations incorrect argument types.

Unavailable scope

Reports usage of unavailable scopes, e.g.

Unknown resource types referenced

Reports unknown (non-used in module) resource type usage.

Haml

Name

Description

Illegal nesting

Reports a Haml tag whose contents are neither on the same line nor nested.

Handlebars

Name

Description

Missing block helper argument

Reports an if, each, or with block helper without an argument.

Html

Name

Description

'package.html' may be converted to 'package-info.java'

Reports any package.html files which are used for documenting packages.

Element id occurs more than once

Detects duplicate element IDs.

Incorrect boolean attribute

Reports an HTML non-boolean attribute without a value.

Missed locally stored library for HTTP link

Reports a URL of an external JavaScript library that is not associated with any locally stored file.

Missing 'openapi-path' attribute

Detects missing openapi-path attribute either in the <api-endpoint> element directly or in the parent <api-doc> element.

Missing closing tag

Reports an HTML element without a closing tag.

Redundant closing tag

Reports redundant closing tags on empty elements, for example, img or br.

Title tag is ignored

Detects <title> tags that do not affect the topic title.

Unknown attribute

Reports an unknown HTML attribute.

Unknown tag

Reports an unknown HTML tag.

Htmlcompatible

Name

Description

Ambiguous component tag

Reports a component that is matched on an embedded template element <ng-template> or multiple components matched on any other element.

Content inside <ng-content> tag

Reports a text or tag occurrence inside a <ng-content> tag used for content projection.

Insecure binding to event

Reports a binding to an event property or attribute, for example, [onclick] or [attr.onclick] instead of (click).

Invalid animation trigger assignment

Reports an invalid assignment of an animation trigger.

Invalid binding type

Reports a mismatch between actual and expected directive binding type.

Invalid i18n attribute

Reports a problem with a i18n-* attribute.

Issues with ngSrc usage in img tags

Reports issues related to usage of ngSrc (NgOptimizedDirective) on img tags.

Missing event handler

Reports a missing event handler statement for an event binding.

Missing required directive input

Reports a missing binding for a required directive input.

Multiple structural directives on one element

Reports multiple structural directives (*ngIf, *ngFor, etc.) on one element.

Unbound or ambiguous template reference variable

Reports a template reference variable that is not assigned to a directive when using exportAs or is assigned to multiple directives.

Undefined binding

Reports an undefined property, event, or structural directive bindings on elements.

Undefined tag

Reports a tag defined by a component or directive out of the current scope.

Unresolved pipe

Reports an unresolved pipe.

Wrong attribute value

Reports an incorrect HTML attribute value.

Http request

Name

Description

'$placeholder' in HTTP Request

Reports a $placeholder inside a request.

GRPC request schema can be substituted or omitted

Reports unnecessary `grpc` or standard `http[s]` schemes usage in gRPC requests.

Inappropriate HTTP Protocol usage

Reports inappropriate usage of HTTP protocol keyword, e.g.

Incorrect HTTP header

Reports unknown HTTP headers that do not match any publicly known headers.

Possible request name

Highlights request name in run block which has no specified import file.

Redundant 'Content-Length'

Reports an explicitly set Content-Length header.

Unknown HTTP method

Reports possible custom HTTP methods.

Unresolved Auth identifier

Highlights references to non-existent Auth configurations.

Unresolved environment variable

Reports variables undeclared in the current environment HTTP Client.

Whitespace in URL in request

Highlights spaces inside URL path segments.

Ignorelang

Name

Description

Ignore file duplicates

Reports duplicate entries (patterns) in the ignore file (e.g.

Ini

Name

Description

Duplicate directive in section

Reports duplicate properties in the ini file section.

Duplicate section in file

Reports duplicate sections in the ini file.

JVM

Name

Description

ActionUpdateThread is missing

Reports actions, action groups and other ActionUpdateThreadAware classes that do not explicitly state their mode.

Component/Action not registered

Reports plugin components and actions that are not registered in a plugin.xml descriptor.

Extension class should be final and non-public

Reports extension classes that are non-final or public.

Extension registered as service/component

Reports extension implementation being additionally registered as a service/component.

Illegal dependency on internal package

Reports references in modules without module-info.java on packages which are not exported from named modules.

Inspection description checker

Reports inspections that are missing an HTML description file, i.e.

Intention description checker

Reports intentions that are missing an HTML description file, before.template file or after.template file.

JComponent must use UiDataProvider

Reports JComponent classes implementing incorrect data provider interface.

JUnit API usage from multiple versions in a single TestCase

Reports JUnit annotated methods when used in a test case from a different JUnit version.

Light service must be final

Reports classes annotated with the @com.intellij.openapi.components.Service annotation that are not final.

Listener implementation implements 'Disposable'

Reports listener implementations that implement com.intellij.openapi.Disposable.

Mismatch between light service level and its constructor

Reports mismatches between light service levels and its constructors.

Postfix template description checker

Reports postfix templates missing an HTML description file, before.template file or after.template file.

Jade

Name

Description

Tabs and spaces both used

Reports use of spaces and tabs for indentation in a Pug file.

Java

Name

Description

'*' import

Reports any import statements that cover entire packages ('* imports').

'<code>…</code>' can be replaced with '{@code …}'

Reports usages of <code> tags in Javadoc comments.

'@Serial' annotation can be used

Reports methods and fields in the Serializable and Externalizable classes that are suitable to be annotated with the java.io.Serial annotation.

'@Serial' annotation used on wrong member

Reports methods and fields in the Serializable and Externalizable classes that are not suitable to be annotated with the java.io.Serial annotation.

'AtomicFieldUpdater' field not declared 'static final'

Reports fields of types: java.util.concurrent.atomic.AtomicLongFieldUpdater java.util.concurrent.atomic.AtomicIntegerFieldUpdater java.util.concurrent.atomic.AtomicReferenceFieldUpdater that are not static final.

'BigDecimal' legacy method called

Reports calls to BigDecimal.divide() or BigDecimal.setScale() that use integer constants to specify the rounding mode.

'Channel' opened but not safely closed

Reports Channel resources that are not safely closed, including any instances created by calling getChannel() on a file or socket resource.

'ClassLoader' instantiation

Reports instantiations of the java.lang.ClassLoader class.

'Collection.toArray()' call style

Reports Collection.toArray() calls that are not in the preferred style, and suggests applying the preferred style.

'Collections.sort()' can be replaced with 'List.sort()'

Reports calls of Collections.sort(list, comparator) which can be replaced with list.sort(comparator).

'Comparable' implemented but 'equals()' not overridden

Reports classes that implement java.lang.Comparable but do not override equals().

'Comparator' class not declared 'Serializable'

Reports classes that implement java.lang.Comparator, but do not implement java.io.Serializable.

'Comparator' combinator can be used

Reports Comparator instances defined as lambda expressions that could be expressed using Comparator.comparing() calls.

'Enum.values()' is recommended to be replaced by 'Enum.getEntries()' since Kotlin 1.9

Reports calls from Java to values() method of Kotlin enum classes that can be replaced with getEntries().

'Error' not rethrown

Reports try statements that catch java.lang.Error or any of its subclasses and do not rethrow the error.

'Externalizable' class without 'public' no-arg constructor

Reports Externalizable classes without a public no-argument constructor.

'Files.readString()' or 'Files.writeString()' can be used

Reports method calls that read or write a String as bytes using java.nio.file.Files.

'InputStream' and 'OutputStream' can be constructed using 'Files' methods

Reports new FileInputStream() or new FileOutputStream() expressions that can be replaced with Files.newInputStream() or Files.newOutputStream() calls respectively.

'Iterator.hasNext()' which calls 'next()'

Reports implementations of Iterator.hasNext() or ListIterator.hasPrevious() that call Iterator.next() or ListIterator.previous() on the iterator instance.

'Iterator.next()' which can't throw 'NoSuchElementException'

Reports implementations of Iterator.next() that cannot throw java.util.NoSuchElementException.

'List.indexOf()' expression can be replaced with 'contains()'

Reports any List.indexOf() expressions that can be replaced with the List.contains() method.

'List.remove()' called in loop

Reports List.remove(index) called in a loop that can be replaced with List.subList().clear().

'Map' can be replaced with 'EnumMap'

Reports instantiations of java.util.Map objects whose key types are enumerated classes.

'Math.random()' cast to 'int'

Reports calls to Math.random() which are immediately cast to int.

'Objects.equals()' can be replaced with 'equals()'

Reports calls to Objects.equals(a, b) in which the first argument is statically known to be non-null.

'Optional' can be replaced with sequence of 'if' statements

Reports Optional call chains that can be replaced with a sequence of if statements.

'Optional' contains array or collection

Reports java.util.Optional or com.google.common.base.Optional types with an array or collection type parameter.

'Optional' used as field or parameter type

Reports any cases in which java.util.Optional<T>, java.util.OptionalDouble, java.util.OptionalInt, java.util.OptionalLong, or com.google.common.base.Optional are used as types for fields or parameters.

'RecordStore' opened but not safely closed

Reports Java ME javax.microedition.rms.RecordStore resources that are not opened in front of a try block and closed in the corresponding finally block.

'ScheduledThreadPoolExecutor' with zero core threads

Reports any java.util.concurrent.ScheduledThreadPoolExecutor instances in which corePoolSize is set to zero via the setCorePoolSize method or the object constructor.

'Serializable' object implicitly stores non-'Serializable' object

Reports any references to local non-Serializable variables outside Serializable lambdas, local and anonymous classes.

'Set' can be replaced with 'EnumSet'

Reports instantiations of java.util.Set objects whose content types are enumerated classes.

'SimpleDateFormat' without locale

Reports instantiations of java.util.SimpleDateFormat or java.time.format.DateTimeFormatter that do not specify a java.util.Locale.

'String.equals()' called with 'CharSequence' argument

Reports calls to String.equals() with a CharSequence as the argument.

'String.equals()' can be replaced with 'String.isEmpty()'

Reports equals() being called to compare a String with an empty string.

'String.indexOf()' expression can be replaced with 'contains()'

Reports comparisons with String.indexOf() calls that can be replaced with a call to the String.contains() method.

'StringBuffer' may be 'StringBuilder'

Reports variables declared as StringBuffer and suggests replacing them with StringBuilder.

'StringBuilder' can be replaced with 'String'

Reports usages of StringBuffer, StringBuilder, or StringJoiner which can be replaced with a single String concatenation.

'StringBuilder' field

Reports fields of type java.lang.StringBuffer or java.lang.StringBuilder.

'StringBuilder' without initial capacity

Reports attempts to instantiate a new StringBuffer or StringBuilder object without specifying its initial capacity.

'ThreadDeath' not rethrown

Reports try statements that catch java.lang.ThreadDeath and do not rethrow the exception.

'ThreadLocal' field not declared 'static final'

Reports fields of type java.lang.ThreadLocal that are not declared static final.

'ThreadLocal.set()' with null as an argument

Reports java.lang.ThreadLocal.set() with null as an argument.

'ThreadLocalRandom' instance might be shared

Reports java.util.concurrent.ThreadLocalRandom instances which might be shared between threads.

'Throwable' not thrown

Reports instantiations of Throwable or its subclasses, where the created Throwable is never actually thrown.

'Throwable' printed to 'System.out'

Reports calls to System.out.println() with an exception as an argument.

'assert' message is not a string

Reports assert messages that are not of the java.lang.String type.

'assert' statement

Reports assert statements.

'assert' statement with side effects

Reports assert statements that cause side effects.

'await()' not called in loop

Reports java.util.concurrent.locks.Condition.await() not being called inside a loop.

'await()' without corresponding 'signal()'

Reports calls to Condition.await(), for which no call to a corresponding Condition.signal() or Condition.signalAll() can be found.

'char' expression used in arithmetic context

Reports expressions of the char type used in addition or subtraction expressions.

'clone()' does not declare 'CloneNotSupportedException'

Reports clone() methods that do not declare throws CloneNotSupportedException.

'clone()' instantiates objects with constructor

Reports calls to object constructors inside clone() methods.

'clone()' method in non-Cloneable class

Reports classes that override the clone() method but don't implement the Cloneable interface.

'clone()' method not 'public'

Reports clone() methods that are protected and not public.

'clone()' should have return type equal to the class it contains

Reports clone() methods with return types different from the class they're located in.

'compare()' method can be used to compare numbers

Reports expressions that can be replaced by a call to the Integer.compare() method or a similar method from the Long, Short, Byte, Double or Float classes, instead of more verbose or less efficient constructs.

'equal()' instead of 'equals()'

Reports declarations of equal() with a single parameter.

'equals()' and 'hashCode()' not paired

Reports classes that override the equals() method but do not override the hashCode() method or vice versa, which can potentially lead to problems when the class is added to a Collection or a HashMap.

'equals()' between objects of inconvertible types

Reports calls to equals() where the target and argument are of incompatible types.

'equals()' call can be replaced with '=='

Reports calls to equals() that can be replaced by == or != expressions without a change in semantics.

'equals()' called on 'BigDecimal'

Reports equals() calls that compare two java.math.BigDecimal numbers.

'equals()' called on array

Reports equals() calls that compare two arrays.

'equals()' called on classes which don't override it

Reports equals() calls on StringBuilder, StringBuffer and instances of java.util.concurrent.atomic package.

'equals()' called on enum value

Reports equals() calls on enum constants.

'equals()' called on itself

Reports calls to equals(), compareTo() or similar, that compare an object for equality with itself.

'equals()' expression replaceable by 'Objects.equals()' expression

Reports expressions that can be replaced with a call to java.util.Objects#equals.

'equals()' method that does not check the class of its parameter

Reports equals() methods that do not check the type of their parameter.

'final' method in 'final' class

Reports final methods in final classes.

'finalize()' called explicitly

Reports calls to Object.finalize().

'finalize()' should be protected, not public

Reports any implementations of the Object.finalize() method that are declared public.

'finalize()' should not be overridden

Reports overriding the Object.finalize() method.

'finally' block which can not complete normally

Reports return, throw, break, continue, and yield statements that are used inside finally blocks.

'for' loop can be replaced with enhanced for loop

Reports for loops that iterate over collections or arrays, and can be automatically replaced with an enhanced for loop (foreach iteration syntax).

'for' loop with missing components

Reports for loops that lack initialization, condition, or update clauses.

'hashCode()' called on array

Reports incorrect hash code calculation for arrays.

'if' can be replaced with 'switch'

Reports if statements that can be replaced with switch statements.

'if' statement can be replaced with conditional or boolean expression

Reports if statements that can be replaced with conditions using the &&, ||, ==, !=, or ?: operator.

'if' statement with identical branches or common parts

Reports if statements in which common parts can be extracted from the branches.

'if' statement with negated condition

Reports if statements that contain else branches and whose conditions are negated.

'instanceof' check for 'this'

Reports usages of instanceof or getClass() == SomeClass.class in which a this expression is checked.

'instanceof' on 'catch' parameter

Reports cases in which an instanceof expression is used for testing the type of a parameter in a catch block.

'instanceof' with incompatible type

Reports instanceof expressions where the expression that is checked has a class/interface type that neither extends/implements the class/interface type on the right-side of the instanceof expression, nor has subclasses that do.

'long' literal ending with 'l' instead of 'L'

Reports long literals ending with lowercase 'l'.

'notify()' or 'notifyAll()' called on 'java.util.concurrent.locks.Condition' object

Reports calls to notify() or notifyAll() made on java.util.concurrent.locks.Condition object.

'notify()' or 'notifyAll()' without corresponding state change

Reports Object.notify() or Object.notifyAll() being called without any detectable state change occurring.

'notify()' without corresponding 'wait()'

Reports calls to Object.notify() or Object.notifyAll() for which no call to a corresponding Object.wait() can be found.

'null' assignment

Reports variables that are assigned to null outside a declaration.

'null' thrown

Reports null literals that are used as the argument of a throw statement.

'package-info.java' without 'package' statement

Reports package-info.java files without a package statement.

'private' method declared 'final'

Reports methods that are marked with both final and private keywords.

'protected' member in 'final' class

Reports protected members in finalclasses.

'public static' array field

Reports public static array fields.

'public static' collection field

Reports modifiable public static Collection fields.

'public' constructor can be replaced with factory method

Reports public constructors.

'public' constructor in non-public class

Reports public constructors in non-public classes.

'public' field

Reports public fields.

'public' method not exposed in interface

Reports public methods in classes which are not exposed in an interface.

'public' method with 'boolean' parameter

Reports public methods that accept a boolean parameter.

'public' method without logging

Reports any public methods that do not contain a logging statement.

'public' nested class

Reports public nested classes.

'readObject()' or 'writeObject()' not declared 'private'

Reports Serializable classes where the readObject or writeObject methods are not declared private.

'readResolve()' or 'writeReplace()' not declared 'protected'

Reports classes that implement java.io.Serializable where the readResolve() or writeReplace() methods are not declared protected.

'record' contains ignored members

Reports serialization methods or fields defined in a record class.

'return' separated from the result computation

Reports return statements that return a local variable where the value of the variable is computed somewhere else within the same method.

'serialPersistentFields' field not declared 'private static final ObjectStreamField[]'

Reports Serializable classes whose serialPersistentFields field is not declared as private static final ObjectStreamField[].

'serialVersionUID' field not declared 'private static final long'

Reports Serializable classes whose serialVersionUID field is not declared private static final long.

'signal()' without corresponding 'await()'

Reports calls to Condition.signal() or Condition.signalAll() for which no call to a corresponding Condition.await() can be found.

'size() == 0' can be replaced with 'isEmpty()'

Reports .size() or .length() comparisons with a 0 literal that can be replaced with a call to .isEmpty().

'static' method declared 'final'

Reports static methods that are marked as final.

'static', non-'final' field

Reports non-final static fields.

'switch' statement

Reports switch statements.

'switch' statement with too low of a branch density

Reports switch statements or expressions with a too low ratio of switch labels to executable statements.

'switch' statement without 'default' branch

Reports switch statements that do not contain default labels.

'synchronized' method

Reports the synchronized modifier on methods.

'this' reference escaped in object construction

Reports possible escapes of this during the object initialization.

'throw' caught by containing 'try' statement

Reports throw statements whose exceptions are always caught by containing try statements.

'throw' inside 'catch' block which ignores the caught exception

Reports exceptions that are thrown from inside catch blocks but do not "wrap" the caught exception.

'try finally' can be replaced with 'try' with resources

Reports try-finally statements that can use Java 7 Automatic Resource Management, which is less error-prone.

'try' statement with multiple resources can be split

Reports try statements with multiple resources that can be automatically split into multiple try-with-resources statements.

'wait()' called on 'java.util.concurrent.locks.Condition' object

Reports calls to wait() made on a java.util.concurrent.locks.Condition object.

'wait()' not called in loop

Reports calls to wait() that are not made inside a loop.

'wait()' or 'await()' without timeout

Reports calls to Object.wait() or Condition.await() without specifying a timeout.

'wait()' or 'notify()' is not in synchronized context

Reports calls to wait(), notify(), and notifyAll() that are not made inside a corresponding synchronized statement or synchronized method.

'wait()' while holding two locks

Reports calls to wait() methods that may occur while the current thread is holding two locks.

'wait()' without corresponding 'notify()'

Reports calls to Object.wait(), for which no call to the corresponding Object.notify() or Object.notifyAll() can be found.

'while' can be replaced with 'do while'

Reports while loops that could be more effectively written as do-while loops.

'while' loop can be replaced with enhanced 'for' loop

Reports while loops that iterate over collections and can be replaced with enhanced for loops (foreach iteration syntax).

'while' loop spins on field

Reports while loops that spin on the value of a non-volatile field, waiting for it to be changed by another thread.

@GET annotated method returns a void value

Reports methods annotated with @GET that do not return anything.

@NotNull field is not initialized

Reports fields annotated as not-null that are not initialized in the constructor.

@NotNull/@Nullable problems

Reports problems related to nullability annotations.

@Path class without resource methods

Reports classes annotated with @Path that have no resource methods.

@Qualifier not copyable by Lombok

Reports Spring @Qualifier annotations on class fields that are ignored by the corresponding Lombok @RequiredArgsConstructor and @AllArgsConstructor annotations.

@Required Spring bean property is not injected

Reports @Required setter bean properties that are not injected or autowired.

@Slf4j

Reports explicitly defined Slf4j Loggers.

@UtilityClass modifiers

Reports unneeded modifiers for classes annotated with @UtilityClass.

@Value modifiers

Reports unneeded modifiers for classes annotated with @Value.

Absolute alignment in AWT/Swing code

Reports usages of absolute alignment constants from AWT and Swing.

Abstract 'class' may be 'interface'

Reports abstract classes that can be converted to interfaces.

Abstract class extends concrete class

Reports abstract classes that extend concrete classes.

Abstract class which has no concrete subclass

Reports abstract classes that have no concrete subclasses.

Abstract class with a single direct inheritor

Reports abstract classes that have precisely one direct inheritor.

Abstract class without 'abstract' methods

Reports abstract classes that have no abstract methods.

Abstract method called during object construction

Reports calls to abstract methods of the current class during object construction.

Abstract method overrides abstract method

Reports abstract methods that override abstract methods.

Abstract method overrides concrete method

Reports abstract methods that override concrete super methods.

Abstract method with missing implementations

Reports abstract methods that are not implemented in every concrete subclass.

Access of system properties

Reports code that accesses system properties using one of the following methods: System.getProperties(), System.setProperty(), System.setProperties(), System.clearProperties() Integer.getInteger() Boolean.getBoolean() While accessing the system properties is not a security risk in itself, it is often found in malicious code.

Access static member via instance reference

Reports references to static methods and fields via a class instance rather than the class itself.

Access to 'static' field locked on instance data

Reports access to non-constant static fields that are locked on either this or an instance field of this.

Access to inherited field looks like access to element from surrounding code

Reports access to a superclass field from an anonymous, inner or local class, if a local variable, parameter, or field with the same name is available in the code surrounding the class.

Accessing a non-public field of another object

Reports accesses to private or protected fields of another object.

Annotation

Reports annotations.

Annotation interface

Reports annotation interfaces.

Anonymous class can be replaced with inner class

Reports anonymous classes.

Anonymous class may be a named 'static' inner class

Reports anonymous classes that may be safely replaced with static inner classes.

Anonymous class variable hides variable in containing method

Reports fields in an anonymous class that are named identically to local variables or parameters of the containing method or lambda expression.

Anonymous class with too many methods

Reports anonymous inner classes whose method count exceeds the specified maximum.

Anonymous type can be replaced with lambda

Reports anonymous classes which can be replaced with lambda expressions.

Anonymous type can be replaced with method reference

Reports anonymous classes which can be replaced with method references.

Anonymous type has shorter lambda alternative

Reports anonymous classes which could be transformed to a constructor or a factory method call with a lambda expression argument.

Array can be replaced with enum values

Reports arrays of enum constants that can be replaced with a call to EnumType.values().

Array comparison using '==', instead of 'Arrays.equals()'

Reports operators == and != used to test for array equality.

Array creation without 'new' expression

Reports array initializers without new array expressions and suggests adding them.

Array.length in loop condition

Reports accesses to the .length property of an array in the condition part of a loop statement.

Assertion can be replaced with 'if' statement

Reports assert statements and suggests replacing them with if statements that throw java.lang.AssertionError.

Assertion is suppressed by 'catch'

Reports assert statements and test framework assertions that are suppressed by a surrounding catch block.

Assignment can be joined with declaration

Reports variable assignments that can be joined with a variable declaration.

Assignment or return of field with mutable type

Reports return of, or assignment from a method parameter to an array or a mutable type like Collection, Date, Map, Calendar, etc.

Assignment to 'catch' block parameter

Reports assignments to, catch block parameters.

Assignment to lambda parameter

Reports assignment to, or modification of lambda parameters.

Assignment to method parameter

Reports assignment to, or modification of method parameters.

Assignment to static field from instance context

Reports assignment to, or modification of static fields from within an instance method.

Auto-boxing

Reports expressions that are affected by autoboxing conversion (automatic wrapping of primitive values as objects).

Auto-unboxing

Reports expressions that are affected by unboxing conversion (automatic unwrapping of objects into primitive values).

AutoCloseable used without 'try'-with-resources

Reports AutoCloseable instances which are not used in a try-with-resources statement, also known as Automatic Resource Management.

Blank line should be replaced with <p> to break lines

Reports blank lines in Javadoc comments.

Block marker comment

Reports comments which are used as code block markers.

Boolean constructor call

Reports creation of Boolean objects.

Boolean expression can be replaced with conditional expression

Reports any boolean expressions which can be formulated in a more compact and, arguably, clear way than by using a conditional expression.

Boolean method is always inverted

Reports methods with a boolean return type that are always negated when called.

Boolean method name must start with question word

Reports boolean methods whose names do not start with a question word.

Boolean variable is always inverted

Reports boolean variables or fields which are always negated when their value is used.

Boxing of already boxed value

Reports boxing of already boxed values.

Bulk 'Files.readAttributes()' call can be used

Reports multiple sequential java.io.File attribute checks, such as: isDirectory() isFile() lastModified() length() Such calls can be replaced with a bulk Files.readAttributes() call.

Bulk operation can be used instead of iteration

Reports single operations inside loops that could be replaced with a bulk method.

Busy wait

Reports calls to java.lang.Thread.sleep() that occur inside loops.

C-style array declaration

Reports array declarations written in C-style syntax, where the array brackets are placed after a variable name or after a method parameter list.

Call math rounding with 'int' argument

Reports calls to round(), ceil(), floor(), rint() methods for Math and StrictMath with int as the argument.

Call methods with unsupported 'java.time.temporal.ChronoUnit' and 'java.time.temporal.ChronoField'

Reports java.time method calls (get(), getLong(), with(), plus(), minus()) with unsupported java.time.temporal.ChronoField or java.time.temporal.ChronoUnit enum constants as arguments.

Call to 'Arrays.asList()' with too few arguments

Reports calls to Arrays.asList() with at most one argument.

Call to 'BigDecimal' method without a rounding mode argument

Reports calls to divide() or setScale() without a rounding mode argument.

Call to 'Connection.prepare*()' with non-constant string

Reports calls to java.sql.Connection.prepareStatement(), java.sql.Connection.prepareCall(), or any of their variants which take a dynamically-constructed string as the statement to prepare.

Call to 'Date.toString()'

Reports toString() calls on java.util.Date objects.

Call to 'Number.toString()'

Reports toString() calls on objects of a class extending Number.

Call to 'Runtime.exec()'

Reports calls to Runtime.exec() or any of its variants.

Call to 'Runtime.exec()' with non-constant string

Reports calls to java.lang.Runtime.exec() which take a dynamically-constructed string as the command to execute.

Call to 'Statement.execute()' with non-constant string

Reports calls to java.sql.Statement.execute() or any of its variants which take a dynamically-constructed string as the query to execute.

Call to 'String.concat()' can be replaced with '+'

Reports calls to java.lang.String.concat().

Call to 'String.toUpperCase()' or 'toLowerCase()' without locale

Reports toUpperCase() or toLowerCase() calls on String objects that do not specify a java.util.Locale.

Call to 'System.exit()' or related methods

Reports calls to System.exit(), Runtime.exit(), and Runtime.halt().

Call to 'System.gc()' or 'Runtime.gc()'

Reports System.gc() or Runtime.gc() calls.

Call to 'System.getenv()'

Reports calls to System.getenv().

Call to 'System.loadLibrary()' with non-constant string

Reports calls to java.lang.System.loadLibrary(), java.lang.System.load(), java.lang.Runtime.loadLibrary() and java.lang.Runtime.load() which take a dynamically-constructed string as the name of the library.

Call to 'System.runFinalizersOnExit()'

Reports calls to System.runFinalizersOnExit().

Call to 'System.setSecurityManager()'

Reports calls to System.setSecurityManager().

Call to 'Thread.dumpStack()'

Reports usages of Thread.dumpStack().

Call to 'Thread.setPriority()'

Reports calls to Thread.setPriority().

Call to 'Thread.sleep()' while synchronized

Reports calls to java.lang.Thread.sleep() methods that occur within a synchronized block or method.

Call to 'Thread.start()' during object construction

Reports calls to start() on java.lang.Thread or any of its subclasses during object construction.

Call to 'Thread.stop()', 'suspend()' or 'resume()'

Reports calls to Thread.stop(), Thread.suspend(), and Thread.resume().

Call to 'Thread.yield()'

Reports calls to Thread.yield().

Call to 'Time.toString()'

Reports toString() calls on java.sql.Time objects.

Call to 'list.containsAll(collection)' may have poor performance

Reports calls to containsAll() on java.util.List.

Call to 'notify()' instead of 'notifyAll()'

Reports calls to Object.notify().

Call to 'printStackTrace()'

Reports calls to Throwable.printStackTrace() without arguments.

Call to 'set.removeAll(list)' may work slowly

Reports calls to java.util.Set.removeAll() with a java.util.List argument.

Call to 'signal()' instead of 'signalAll()'

Reports calls to java.util.concurrent.locks.Condition.signal().

Call to 'toString()' on array

Reports arrays used in String concatenations or passed as parameters to java.io.PrintStream methods, such as System.out.println().

Call to a 'native' method while locked

Reports calls native methods within a synchronized block or method.

Call to default 'toString()'

Reports calls to toString() that use the default implementation from java.lang.Object.

Call to inherited method looks like call to local method

Reports calls to a superclass method from an anonymous, inner or local class, if a method with the same signature exists in the code surrounding the class.

Call to simple getter from within class

Reports calls to a simple property getter from within the property's class.

Call to simple setter from within class

Reports calls to a simple property setter from within the property's class.

Call to suspicious 'String' method

Reports calls of: equals() equalsIgnoreCase() compareTo() compareToIgnoreCase() and trim() on String objects.

Can use bounded wildcard

Reports generic method parameters that can make use of bounded wildcards.

Cast can be replaced with variable

Reports type cast operations that can be replaced with existing local or pattern variables with the same value.

Cast conflicts with 'instanceof'

Reports type cast expressions that are preceded by an instanceof check for a different type.

Cast to 'float' can be 'float' literal

Reports double literal expressions that are immediately cast to float.

Cast to 'long' can be 'long' literal

Reports int literal expressions that are immediately cast to long.

Cast to incompatible type

Reports type cast expressions where the casted expression has a class/interface type that neither extends/implements the cast class/interface type, nor has subclasses that do.

Catch block may ignore exception

Reports catch blocks that are empty or may ignore an exception.

Caught exception is immediately rethrown

Reports catch blocks that immediately rethrow the caught exception without performing any action on it.

Chain of 'instanceof' checks

Reports any chains of if-else statements all of whose conditions are instanceof expressions or class equality expressions (e.g.

Chained equality comparisons

Reports chained equality comparisons.

Chained method calls

Reports method calls whose target is another method call.

Character comparison

Reports ordinal comparisons of char values.

Checked exception class

Reports checked exception classes (that is, subclasses of java.lang.Exception that are not subclasses of java.lang.RuntimeException).

Class can be record class

Reports classes that can be converted record classes.

Class directly extends 'Thread'

Reports classes that directly extend java.lang.Thread.

Class directly extends 'Throwable'

Reports classes that directly extend java.lang.Throwable.

Class does not override 'toString()' method

Reports classes without a toString() method.

Class explicitly extends 'Object'

Reports any classes that are explicitly declared to extend java.lang.Object.

Class explicitly extends a 'Collection' class

Reports classes that extend concrete subclasses of the java.util.Collection or java.util.Map classes.

Class extends annotation interface

Reports classes declared as an implementation or extension of an annotation interface.

Class extends utility class

Reports classes that extend a utility class.

Class independent of its module

Reports classes that: do not depend on any other class in their module are not a dependency for any other class in their module Such classes are an indication of ad-hoc or incoherent modularisation strategies, and may often profitably be moved.

Class independent of its package

Reports classes that don't depend on any other class in their package and are not a dependency for any other class in their package.

Class initializer may be 'static'

Reports instance initializers which may be made static.

Class is closed to inheritance

Reports classes that are declared final.

Class is exposed outside of its visibility scope

Reports usages of classes in a field or method signature where the class has less visibility than the member that uses it.

Class may extend a commonly used base class

Reports classes or interfaces that can be replaced with an implementation or extension of a more specific commonly used class or interface.

Class may extend adapter instead of implementing listener

Reports classes implementing listeners instead of extending corresponding adapters.

Class name differs from file name

Reports top-level class names that don't match the name of a file containing them.

Class name prefixed with package name

Reports classes whose names are prefixed with their package names, ignoring differences in capitalization.

Class name same as ancestor name

Reports classes that have the same name as one of their superclasses, while their fully qualified names remain different.

Class only used from one other module

Reports classes that: do not depend on any other class in their module depend on classes from a different module are a dependency only for classes from this other module Such classes could be moved into the module on which they depend.

Class only used from one other package

Reports classes that don't depend on any other class in their package, depend on classes from another package, and are themselves a dependency only for classes from this other package.

Class references one of its subclasses

Reports classes which contain references to one of their subclasses.

Class too deep in inheritance tree

Reports classes that are too deep in the inheritance hierarchy.

Class with multiple loggers

Reports classes that have multiple loggers declared.

Class with only 'private' constructors should be declared 'final'

Reports classes with only private constructors.

Class with too many constructors

Reports classes whose number of constructors exceeds the specified maximum.

Class with too many dependencies

Reports classes that are directly dependent on too many other classes in the project.

Class with too many dependents

Reports a class on which too many other classes are directly dependent.

Class with too many fields

Reports classes whose number of fields exceeds the specified maximum.

Class with too many methods

Reports classes whose number of methods exceeds the specified maximum.

Class with too many transitive dependencies

Reports classes that are directly or indirectly dependent on too many other classes.

Class with too many transitive dependents

Reports a class on which too many other classes are directly or indirectly dependent.

Class without constructor

Reports classes without constructors.

Class without logger

Reports classes which do not have a declared logger.

Class without no-arg constructor

Reports classes without a constructor that takes no arguments (i.e.

Cleaner captures object reference

Reports Runnable passed to a Cleaner.register() capturing reference being registered.

Cloneable class in secure context

Reports classes which may be cloned.

Cloneable class without 'clone()' method

Reports classes implementing the Cloneable interface that don't override the clone() method.

Code block contains single statement

Reports control flow statements with a single statement in their code block and suggests removing the braces from the control flow statement body.

Collection added to itself

Reports cases where the argument of a method call on a java.util.Collection or java.util.Map is the collection or map itself.

Collection declared by class, not interface

Reports declarations of Collection variables made by using the collection class as a type, rather than an appropriate interface.

Collection without initial capacity

Reports attempts to instantiate a new Collection object without specifying an initial capacity.

Comment replaceable with Javadoc

Reports a regular comment that belongs to a field, method, or class that can be replaced with a Javadoc comment.

Commented out code

Reports comments that contain Java code.

Common subexpression can be extracted from 'switch'

Reports switch expressions and statements where every branch has a common subexpression, and the switch can be moved inside.

Comparator method can be simplified

Reports Comparator combinator constructs that can be simplified.

Comparison of 'short' and 'char' values

Reports equality comparisons between short and char values.

Comparison to 'Double.NaN' or 'Float.NaN'

Reports any comparisons to Double.NaN or Float.NaN.

Concatenation with empty string

Reports empty string operands in string concatenations.

Condition is covered by further condition

Reports conditions that become redundant as they are completely covered by a subsequent condition.

Conditional break inside loop

Reports conditional breaks at the beginning or at the end of a loop and suggests adding a loop condition instead to shorten the code.

Conditional can be pushed inside branch expression

Reports conditional expressions with then and else branches that are similar enough so that the expression can be moved inside.

Conditional can be replaced with Optional

Reports null-check conditions and suggests replacing them with Optional chains.

Conditional expression with negated condition

Reports conditional expressions whose conditions are negated.

Confusing 'main()' method

Reports methods that are named "main", but do not have the public static void main(String[]) signature in Java up to 21.

Confusing argument to varargs method

Reports calls to variable arity methods that have a single argument in the vararg parameter position, which is either a null or an array of a subtype of the vararg parameter.

Confusing floating-point literal

Reports any floating point numbers that don't have a decimal point, numbers before the decimal point, or numbers after the decimal point.

Confusing octal escape sequence

Reports string literals containing an octal escape sequence immediately followed by a digit.

Confusing primitive array argument to varargs method

Reports any calls to a variable arity method where the call has a primitive array in the variable arity parameter position (for example, System.out.printf("%s", new int[]{1, 2, 3})).

Connection opened but not safely closed

Reports Java ME javax.microedition.io.Connection resources that are not opened in front of a try block and closed in the corresponding finally block.

Constant assert argument

Reports constant arguments in assertTrue(), assertFalse(), assertNull(), and assertNotNull() calls.

Constant call to 'Math'

Reports calls to java.lang.Math or java.lang.StrictMath methods that can be replaced with simple compile-time constants.

Constant condition in 'assert' statement

Reports assert statement conditions that are constants.

Constant declared in 'abstract' class

Reports constants (public static final fields) declared in abstract classes.

Constant declared in interface

Reports constants (public static final fields) declared in interfaces.

Constant expression can be evaluated

Reports constant expressions, whose value can be evaluated statically, and suggests replacing them with their actual values.

Constant on wrong side of comparison

Reports comparison operations where the constant value is on the wrong side.

Constant values

Reports expressions and conditions that always produce the same result, like true, false, null, or zero.

Constructor assigns value to field defined in superclass

Reports assignment to, or modification of fields that are declared in a superclass from within a subclass constructor.

Constructor with too many parameters

Reports constructors whose number of parameters exceeds the specified maximum.

Contract issues

Reports issues in method @Contract annotations.

Control flow statement without braces

Reports any if, while, do, or for statements without braces.

Copy constructor misses field

Reports copy constructors that don't copy all the fields of the class.

Copy of existing static method body

Reports fragments of Java code which are identical to the existing static methods suggesting to reuse these static methods.

Covariant 'equals()'

Reports equals() methods taking an argument type other than java.lang.Object if the containing class does not have other overloads of equals() that take java.lang.Object as its argument type.

Custom 'ClassLoader' is declared

Reports user-defined subclasses of java.lang.ClassLoader.

Custom 'SecurityManager'

Reports user-defined subclasses of java.lang.SecurityManager.

Cyclic class dependency

Reports classes that are mutually or cyclically dependent on other classes.

Cyclic package dependency

Reports packages that are mutually or cyclically dependent on other packages.

Dangling Javadoc comment

Reports Javadoc comments that don't belong to any class, method or field.

Data provider problems

Reports references to data provider methods that do not exist or are not accessible.

Declaration access can be weaker

Reports fields, methods or classes that may have their access modifier narrowed down.

Declaration can have 'final' modifier

Reports fields, methods, or classes that may have the final modifier added to their declarations.

Declaration has problems in Javadoc references

Reports unresolved references inside Javadoc comments.

Default annotation parameter value

Reports annotation parameters that are assigned to their default value.

Dependencies on automatic modules

Reports usages of automatic modules in a requires directive.

Deprecated Lombok annotations

Reports deprecated Lombok annotations and suggests quick-fixes to replace them with the ones promoted to the main package.

Deprecated member is still used

Reports deprecated classes, methods, and fields that are used in your code nonetheless.

Design for extension

Reports methods which are not static, private, final or abstract, and whose bodies are not empty.

Diamond can be replaced with explicit type arguments

Reports instantiation of generic classes in which the <> symbol (diamond) is used instead of type parameters.

Double brace initialization

Reports Double Brace Initialization.

Double-checked locking

Reports double-checked locking.

Duplicate branches in 'switch'

Reports switch statements or expressions that contain the same code in different branches and suggests merging the duplicate branches.

Duplicate string literal

Reports string literals that are replicated unchanged throughout the project.

Duplicate throws

Reports duplicate exceptions in a method throws list.

Duplicated data provider names

Reports TestNG data providers with equal names if org.testng.TestNGException has occurred.

Duplicated delimiters in 'StringTokenizer'

Reports StringTokenizer() constructor calls or nextToken() method calls that contain duplicate characters in the delimiter argument.

Dynamic regular expression can be replaced by compiled 'Pattern'

Reports calls to the regular expression methods (such as matches() or split()) of java.lang.String using constant arguments.

Early loop exit in 'if' condition

Reports loops with an if statement that can end with break without changing the semantics.

Empty 'module-info.java' file

Reports an empty module-info.java file, indicating unresolved module dependencies.

Empty 'synchronized' statement

Reports synchronized statements with empty bodies.

Empty class

Reports empty classes and empty Java files.

Empty class initializer

Reports empty class initializer blocks.

Enhanced 'for' statement

Reports enhanced for statements.

Enhanced 'for' with a record pattern can be used

Reports local variable declarations and accessors to record components that can be replaced with pattern variables in enhanced `for` statements, which are usually more compact.

Enhanced 'switch'

Reports enhanced switch statements and expressions.

Enum 'switch' statement that misses case

Reports switch statements over enumerated types that are not exhaustive.

Enumerated class

Reports enum classes.

Enumeration can be iteration

Reports calls to Enumeration methods that are used on collections and may be replaced with equivalent Iterator constructs.

Exception class name does not end with 'Exception'

Reports exception classes whose names don't end with Exception.

Exception constructor called without arguments

Reports creation of a exception instance without any arguments specified.

Exception package

Reports packages that only contain classes that extend java.lang.Throwable, either directly or indirectly.

Excessive lambda usage

Reports if a trivial lambda expression is used in cases in which there's an alternative method that behaves in the same way, but accepts a concrete value instead of a lambda.

Excessive range check

Reports condition chains in which a value range is checked and these condition chains can be simplified to a single check.

Expected exception never thrown in test method body

Reports checked exceptions expected by a JUnit 4 test-method that are never thrown inside the method body.

Explicit argument can be lambda

Reports method calls that accept a non-trivial expression and can be replaced with an equivalent method call which accepts a lambda instead.

Explicit array filling

Reports loops that can be replaced with Arrays.setAll() or Arrays.fill() calls.

Explicit class declaration can be converted into implicitly declared class

Reports ordinary classes, which can be converted into implicitly declared classes Example: public class Sample { public static void main(String[] args) { System.out.println("Hello, world!"); } } After the quick-fix is applied: public static void main(String[] args) { System.out.println("Hello, world!"); }.

Explicit type can be replaced with '<>'

Reports new expressions with type arguments that can be replaced a with diamond type <>.

Expression can be factorized

Reports expressions that can be factorized, i.e.

Expression can be folded into Stream chain

Reports expressions with a repeating pattern that could be replaced with Stream API or a String.join() call.

Expression is compared to itself

Reports comparisons where left and right operand represent the identical expression.

Externalizable class with 'readObject()' or 'writeObject()'

Reports Externalizable classes that define readObject() or writeObject() methods.

Feature envy

Reports the Feature Envy code smell.

Field accessed in both 'synchronized' and unsynchronized contexts

Reports non-final fields that are accessed in both synchronized and non-synchronized contexts.

Field assignment can be moved to initializer

Suggests replacing initialization of fields using assignment with initialization in the field declaration.

Field can be local

Reports redundant class fields that can be replaced with local variables.

Field can be made 'static'

Reports instance variables that can safely be made static.

Field has setter but no getter

Reports fields that have setter methods but no getter methods.

Field may be 'final'

Reports fields that can be safely made final.

Field not used in 'toString()' method

Reports fields that are not used in the toString() method of a class.

Floating-point equality comparison

Reports floating-point values that are being compared using the == or != operator.

Forward compatibility

Reports Java code constructs that may fail to compile in future Java versions.

Functional expression can be folded

Reports method references or lambda expressions that point to a method of their own functional interface type and hence can be replaced with their qualifiers removing unnecessary object allocation.

Guava pseudo-functional call can be converted to Stream API call

Reports usages of Guava pseudo-functional code when Java Stream API is available.

Guava's functional primitives can be replaced with Java

Reports usages of Guava's functional primitives that can be migrated to standard Java API calls.

HTML problems in Javadoc (DocLint)

Reports the same HTML issues in the Javadoc comments that have been reported by DocLint since Java 8.

Hardcoded file separator

Reports the forward (/) or backward (\) slash in a string or character literal.

Hardcoded line separator

Reports linefeed (\n) and carriage return (\r) character escape sequences used in string literals, character literals or text blocks.

Hibernate Criteria API unrecognized property

Reports unrecognized properties in Hibernate Criteria API usages.

Hibernate resource opened but not safely closed

Reports calls to the openSession() method if the returned org.hibernate.Session resource is not safely closed.

I/O resource opened but not safely closed

Reports I/O resources that are not safely closed.

Idempotent loop body

Reports loops whose second and all subsequent iterations do not produce any additional side effects other than the one produced by the first iteration, which can indicate a programming error.

Identical 'catch' branches in 'try' statement

Reports identical catch sections in a single try statement.

Illegal method name passed to 'dependsOnMethods'

Reports illegal method names passed to the dependsOnMethods attribute in the @Test annotation.

Immutable collection creation can be replaced with collection factory call

Reports java.util.Collections unmodifiable collection calls that can be converted to newer collection factory methods.

Implicit call to 'super()'

Reports constructors that do not begin with a call to "super" constructor or another constructor of the same class.

Implicit numeric conversion

Reports implicit conversion between numeric types.

Implicit platform default charset

Reports method and constructor calls that implicitly use the platform default charset.

Implicitly declared class can be replaced with ordinary class

Reports implicitly declared classes and suggests replacing them with regular classes.

Inconsistent 'AtomicFieldUpdater' declaration

Reports issues with AtomicLongFieldUpdater, AtomicIntegerFieldUpdater, or AtomicReferenceFieldUpdater fields (the java.util.concurrent.atomic package).

Inconsistent whitespace indentation in text block

Reports text blocks that are indented using both spaces and tabs.

Incorrect 'DateTimeFormat' pattern

Reports incorrect date time format patterns.

Incorrect 'MessageFormat' pattern

Reports incorrect message format patterns or incorrect indexes of placeholders The following errors are reported: Unparsed or negative index Unclosed brace Unpaired quote.

Incorrect 'channel' attribute in an endpoint method annotation

Reports incorrect channel attributes in endpoint method annotations: @Gateway, @ServiceActivator, @Filter, and so on.

Incorrect 'min' and 'max' values in Bean Validation annotations

Reports incorrect values of max and min values in Bean Validation constraint annotations.

Incorrect @Async method signature

Reports incorrect return types of @Async methods.

Incorrect @Path URI template

Reports syntax errors and unused URI templates inside @Path annotations.

Incorrect @Scheduled method signature

Reports incorrect @Scheduled methods.

Incorrect Spring Integration endpoint method

Reports incorrect Spring Integration endpoint method declarations.

Incorrect Spring component autowiring or injection on a static class member

Reports autowired and injected static methods/fields of Spring components.

Incorrect configuration of Spring beans referenced in the Spring Security annotation

Reports unresolved Spring beans referenced in Spring Security annotations.

Incorrect injecting of SpEL in a static field

Reports attempts to inject Spring Expression Language (SpEL) into static fields ('null' value is injected).

Incorrect value of @DefaultValue parameter

Reports the value of @DefaultValue if it cannot be converted to the specified type of parameter.

Incorrectly configured 'caching' annotation

Reports incorrect 'caching' annotations: @Cacheable, @CacheEvict, @CachePut, @CacheConfig, and so on.

Incorrectly referenced bean in @DependsOn annotation

Reports incorrect bean references in the value parameter of the @DependsOn annotation.

Incorrectly referenced bean in @Lookup annotation of Spring component

Reports incorrect bean references in the value parameter of the @Lookup annotation.

Incorrectly referenced bean in @Scheduled annotation

Reports incorrect bean references in the scheduler parameter of the @Scheduled annotation.

Inefficient Stream API call chains ending with count()

Reports Stream API call chains ending with a count() operation, that are optimizable.

Inheritance of Kotlin sealed interface/class from Java

Reports attempts to inherit from Kotlin sealed interfaces or classes in Java code.

Injection annotation is not applicable

Reports when a @Language annotation is applied to an element with a type other than String or String[].

Inner class field hides outer class field

Reports inner class fields named identically to a field of a surrounding class.

Inner class may be 'static'

Reports inner classes that can be made static.

Inner class of interface

Reports inner classes in interface classes.

Inner class referenced via subclass

Reports accesses of inner and nested classes where the call is qualified by a subclass of the declaring class, rather than the declaring class itself.

Inner class too deeply nested

Reports classes whose number of nested inner classes exceeds the specified maximum.

Insecure random number generation

Reports any uses of java.lang.Random or java.lang.Math.random().

Instance field access not qualified with 'this'

Reports field access operations that are not qualified with this or some other qualifier.

Instance field may not be initialized

Reports instance variables that may be uninitialized upon object initialization.

Instance field may not be initialized by 'readObject()'

Reports fields that are not guaranteed to be initialized after the object is deserialized by the readObject() method.

Instance field used before initialization

Reports instance variables that are read before initialization.

Instance member guarded by static field

Reports @GuardedBy annotations on instance fields or methods in which the guard is a static field.

Instance method call not qualified with 'this'

Reports calls to non-static methods on the same instance that are not qualified with this.

Instantiating a 'Thread' with default 'run()' method

Reports instantiations of Thread or an inheritor without specifying a Runnable parameter or overriding the run() method.

Instantiating object to get 'Class' object

Reports code that instantiates a class to get its class object.

Instantiation of utility class

Reports instantiation of utility classes using the new keyword.

Integer division in floating-point context

Reports integer divisions where the result is used as a floating-point number.

Integer multiplication or shift implicitly cast to 'long'

Reports integer multiplications and left shifts that are implicitly cast to long.

Interface may be annotated as '@FunctionalInterface'

Reports interfaces that can be annotated with @FunctionalInterface.

Interface method clashes with method in 'Object'

Reports interface methods that clash with the protected methods clone() and finalize() from the java.lang.Object class.

Interface which has no concrete subclass

Reports interfaces that have no concrete subclasses.

Interface with a single direct inheritor

Reports interfaces that have precisely one direct inheritor.

Invalid @DirtiesContext 'mode' configuration

Reports incorrect 'mode' configuration in the @DirtiesContext annotation.

Invalid data provider return type

Reports methods marked with @DataProvider annotation that doesn't return Object[][] or Iterator<Object>.

Invalid method reference used for 'Comparator'

Reports method references mapped to the Comparator interface that don't fulfill its contract.

Invalid property key

Reports invalid arguments that are passed to methods with parameters annotated as @PropertyKey.

Invalid transactional lifecycle method declaration

Reports invalid transactional lifecycle method declarations annotated with @BeforeTransaction and @AfterTransaction in testing classes annotated as @Transactional.

Iterable is used as vararg

Reports suspicious usages of Collection or Iterable in vararg method calls.

Iteration over 'keySet()' can be optimized

Reports iterations over the keySet() of a java.util.Map instance, where the iterated keys are used to retrieve the values from the map.

JDBC resource opened but not safely closed

Reports JDBC resources that are not safely closed.

JNDI resource opened but not safely closed

Reports JNDI resources that are not safely closed.

JUnit Test can be converted to TestNG

Reports any JUnit-based test class that can be converted into TestNG based unit test.

Java annotator

Allows viewing the problems reported by the Java annotator: compilation problems, unresolved by IDEA references, and so on.

Java module name contradicts the convention

Reports cases when a module name contradicts Java Platform Module System recommendations.

Java sanity

Reports unresolved references in Java code.

Javac quirks

Reports known Javac issues, performance problems, and incompatibilities.

Javadoc comment can be Markdown documentation comment

Reports Javadoc comments that can be converted to Markdown documentation comments.

Javadoc declaration problems

Reports Javadoc comments and tags with the following problems: invalid tag names incomplete tag descriptions duplicated tags missing Javadoc descriptions Example: /** * Invalid tag name * @poram param description */ public void sample(int param){ } Example: /** * Pointing to itself {@link #sample(int)} */ public void sample(int param){ } Quick-fix adds the unknown Javadoc tag to the list of user defined additional tags.

Kotlin JVM annotation in Java

Reports useless Kotlin JVM annotations in Java code.

Kotlin non-const property used as Java constant

Reports Kotlin properties that are not const and used as Java annotation arguments.

Labeled switch rule can have code block

Reports rules of switch expressions or enhanced switch statements with an expression body.

Labeled switch rule has redundant code block

Reports labeled rules of switch statements or switch expressions that have a redundant code block.

Lambda body can be code block

Reports lambdas whose body is an expression and suggests converting expression bodies to code blocks.

Lambda can be replaced with anonymous class

Reports lambda expressions that can be replaced with anonymous classes.

Lambda can be replaced with method call

Reports lambda expressions which can be replaced with a call to a JDK method.

Lambda can be replaced with method reference

Reports lambdas that can be replaced with method references.

Lambda parameter hides field

Reports lambda parameters named identically to a field of a surrounding class.

Lambda parameter naming convention

Reports lambda parameters whose names are too short, too long, or do not follow the specified regular expression pattern.

Lambda parameter type can be specified

Reports lambda parameters that do not have their type specified and suggests adding the missing type declarations.

Lambda-unfriendly method overload

Reports overloaded methods that take functional interfaces with conflicting abstract method signatures.

Language mismatch

Reports when the language of a reference does not match the expected language of the usage context.

Large array allocation with no OutOfMemoryError check

Reports large array allocations which do not check for java.lang.OutOfMemoryError.

Law of Demeter

Reports Law of Demeter violations.

Link specified as plain text

Reports plain text links in Javadoc comments.

Local class

Reports local classes.

Local variable hides field

Reports local variables named identically to a field of a surrounding class.

Local variable or parameter can be 'final'

Reports parameters or local variables that may have the final modifier added to their declaration.

Local variable type can be omitted

Reports redundant local variable types.

Local variable used and declared in different 'switch' branches

Reports local variables declared in one branch of a switch statement and used in another branch.

Lock acquired but not safely unlocked

Reports java.util.concurrent.locks.Lock resources that are not acquired in front of a try block or not unlocked in the corresponding finally block.

Logger initialized with foreign class

Reports Logger instances that are initialized with a class literal from a different class than the Logger is contained in.

Lombok @Getter may be used

Reports standard getter method that can be replaced by the lombok @Getter annotation.

Lombok @Setter may be used

Reports standard setter method that can be replaced by the lombok @Setter annotation.

Lombok annotations

Offers general inspections for Lombok annotations.

Loop can be collapsed with Stream API

Reports loops which can be replaced with stream API calls using lambda expressions.

Loop can be replaced with 'Collection.removeIf()'

Reports loops which can be collapsed into a single Collection.removeIf() call.

Loop can be replaced with 'List.replaceAll()'

Reports loops which can be collapsed into a single List.replaceAll() call.

Loop executes zero or billions of times

Reports loops that cannot be completed without an index overflow or loops that don't loop at all.

Loop statement that does not loop

Reports any instance of for, while, and do statements whose bodies will be executed once at most.

Loop variable not updated inside loop

Reports any variables and parameters that are used in a loop condition and are not updated inside the loop.

Loop with implicit termination condition

Reports any while, do-while, and for loops that have the true constant as their only condition.

Magic character

Reports character literals that are used without constant declaration.

Magic constant

Reports expressions that can be replaced with "magic" constants.

Malformed format string

Reports format strings that don't comply with the standard Java syntax.

Manual array copy

Reports manual copying of array contents that can be replaced with a call to System.arraycopy().

Manual array to collection copy

Reports code that uses a loop to copy the contents of an array into a collection.

Manual min/max calculation

Reports cases where the minimum or the maximum of two numbers can be calculated using a Math.max() or Math.min() call, instead of doing it manually.

Map.forEach() can be used

Suggests replacing for(Entry<?,?> entry : map.entrySet()) {...} or map.entrySet().forEach(entry -> ...) with map.forEach((key, value) -> ...).

Mapping call before count()

Reports redundant Stream API calls like map(), or boxed() right before the count() call.

Marker interface

Reports marker interfaces without any methods or fields.

Maximum 'switch' branches

Reports switch statements or expressions with too many case labels.

Meaningless record annotation

Reports annotations used on record components that have no effect.

Message missing on assertion

Reports calls to assertXXX() or fail() without an error message string argument.

Method call in loop condition

Reports method calls in the condition part of a loop statement.

Method can be extracted

Suggests extracting fragments of code to a separate method to make code more clear.

Method can be made 'void'

Reports methods whose return values are never used when called.

Method can have varargs parameter

Reports methods that can be converted to variable arity methods.

Method can't be overridden

Reports methods that are declared final.

Method does not call super method

Reports methods that override a super method without calling it.

Method is identical to its super method

Reports methods that are identical to their super methods.

Method name same as class name

Reports methods that are named identically to their class.

Method name same as parent class name

Reports methods that have the same name as the superclass of the method's class, as such a method name may be confusing.

Method names differing only by case

Reports cases in which multiple methods of a class have the names that differ only by case.

Method overrides inaccessible method of superclass

Reports methods with the same signature as an inaccessible method of a superclass, for example, a private method, or a package-private method of a superclass in another package.

Method parameter naming convention

Reports method parameters whose names are too short, too long, or do not follow the specified regular expression pattern.

Method reference can be replaced with lambda

Reports method references, like MyClass::myMethod and myObject::myMethod, and suggests replacing them with an equivalent lambda expression.

Method returns per-class constant

Reports methods that only return a constant, which may differ for various inheritors.

Method tries to override 'static' method of superclass

Reports static methods with a signature identical to a static method of a superclass.

Method with more than three negations

Reports methods with three or more negations.

Method with multiple loops

Reports methods that contain more than one loop statement.

Method with multiple return points

Reports methods whose number of return points exceeds the specified maximum.

Method with single 'synchronized' block can be replaced with 'synchronized' method

Reports methods whose body contains a single synchronized statement.

Method with too many exceptions declared

Reports methods that have too many types of exceptions in its throws list.

Method with too many parameters

Reports methods whose number of parameters exceeds the specified maximum.

MethodHandle/VarHandle type mismatch

Reports MethodHandle and VarHandle factory method calls that don't match any method or field.

Minimum 'switch' branches

Reports switch statements and expressions with too few case labels, and suggests rewriting them as if and else if statements.

Mismatch between Javadoc and code

Reports parts of method specification written in English that contradict with the method declaration.

Mismatched case in 'String' operation

Reports String method calls that always return the same value (-1 or false) because a lowercase character is searched in an uppercase-only string or vice versa.

Mismatched query and update of 'StringBuilder'

Reports StringBuilder, StringBuffer or StringJoiner objects whose contents are read but not written to, or written to but not read.

Mismatched read and write of array

Reports arrays whose contents are read but not updated, or updated but not read.

Misordered 'assertEquals()' arguments

Reports calls to assertEquals() that have the expected argument and the actual argument in the wrong order.

Missing '@Deprecated' annotation

Reports module declarations, classes, fields, or methods that have the @deprecated Javadoc tag but do not have the @java.lang.Deprecated annotation.

Missing '@Override' annotation

Reports methods overriding superclass methods but are not annotated with @java.lang.Override.

Missing 'package-info.java'

Reports packages that contain classes but do not contain the package-info.java or package.html files and are, thus, missing the package documentation.

Missing Javadoc

Reports missing Javadoc comments and tags.

Missing aspectj-autoproxy

Reports @Aspect annotations in Spring versions earlier than 2.5 if there is no <aop:aspectj-autoproxy/> element in the XML configuration.

Missorted imports

Reports import statements which are not arranged according to the current code style (see Settings|Editor|Code Style).

Missorted modifiers

Reports declaration modifiers that are not in the canonical preferred order (as stated in the Java Language Specification).

Module exports/opens package to itself

Reports packages that are exported to, or opened in the same Java 9 module in which they are defined.

Module with too few classes

Reports modules that contain too few classes.

Module with too many classes

Reports modules that contain too many classes.

Multi-catch can be split into separate catch blocks

Reports multi-catch sections and suggests splitting them into separate catch blocks.

Multiple exceptions declared on test method

Reports JUnit test method throws clauses with more than one exception.

Multiple occurrences of the same expression

Reports multiple equivalent occurrences of the same expression within a method (or constructor, or class initializer) if the result of the expression can be reused.

Multiple operators with different precedence

Reports binary, conditional, or instanceof expressions that consist of different operators without parentheses.

Multiple top level classes in single file

Reports multiple top-level classes in a single Java file.

Multiple variables in one declaration

Reports multiple variables that are declared in a single declaration and suggest creating a separate declaration for each variable.

Multiplication or division by power of two

Reports multiplication of an integer value by a constant integer that can be represented as a power of two.

Native method

Reports methods declared native.

Negated equality expression

Reports equality expressions which are negated by a prefix expression.

Negative int hexadecimal constant in long context

Reports negative int hexadecimal constants in long context.

Negatively named boolean variable

Reports negatively named variables, for example: disabled, hidden, or isNotChanged.

Nested 'synchronized' statement

Reports nested synchronized statements.

Nested 'try' statement

Reports nested try statements.

Nested method call

Reports method calls used as parameters to another method call.

New object is compared using '=='

Reports code that applies == or != to a newly allocated object instead of calling equals().

No-op method in 'abstract' class

Reports no-op (for "no operation") methods in abstract classes.

Non functional style 'Optional.isPresent()' usage

Reports Optional expressions used as if or conditional expression conditions, that can be rewritten in a functional style.

Non recommended 'field' injections

Reports injected or autowired fields in Spring components.

Non-'static' initializer

Reports non-static initializers in classes.

Non-Basic Latin character

Reports non-Basic Latin characters in literals and suggests replacing them with unicode entities.

Non-annotated Method overrides @Pattern Method

Reports when a method without any @Pattern annotation overrides a @Pattern annotated method.

Non-atomic operation on 'volatile' field

Reports non-atomic operations on volatile fields.

Non-boolean method name must not start with question word

Reports non-boolean methods whose names start with a question word.

Non-constant 'String' can be replaced with 'StringBuilder'

Reports variables declared as java.lang.String that are repeatedly appended to.

Non-constant field with upper-case name

Reports non-static non-final fields whose names are all in upper case.

Non-constant logger

Reports logger fields that are not declared static and/or final.

Non-constant string concatenation as argument to logging call

Reports non-constant string concatenations that are used as arguments to SLF4J and Log4j 2 logging methods.

Non-exception class name ends with 'Exception'

Reports non-exception classes whose names end with Exception.

Non-final '@GuardedBy' field

Reports @GuardedBy annotations in which the guarding field is not final.

Non-final 'clone()' in secure context

Reports clone() methods without the final modifier.

Non-final field in '@Immutable' class

Reports any non-final field in a class with the @Immutable annotation.

Non-final field in 'enum'

Reports non-final fields in enumeration types.

Non-final field of 'Exception' class

Reports fields in subclasses of java.lang.Exception that are not declared final.

Non-final field referenced in 'compareTo()'

Reports access to a non-final field inside a compareTo() implementation.

Non-final field referenced in 'equals()'

Reports implementations of equals() that access non-final variables.

Non-final field referenced in 'hashCode()'

Reports implementations of hashCode() that access non-final variables.

Non-final static field is used during class initialization

Reports the use of non-final static variables during class initialization.

Non-normalized annotation

Reports annotations in a shorthand form and suggests rewriting them in a normal form with an attribute name.

Non-private field accessed in 'synchronized' context

Reports non-final, non-private fields that are accessed in a synchronized context.

Non-reproducible call to 'Math'

Reports calls to java.lang.Math methods, which results are not guaranteed to be reproduced precisely.

Non-serializable class with 'readObject()' or 'writeObject()'

Reports non-Serializable classes that define readObject() or writeObject() methods.

Non-serializable class with 'serialVersionUID'

Reports non-Serializable classes that define a serialVersionUID field.

Serializable non-static inner class without 'serialVersionUID'

Reports non-serializable fields in classes that implement java.io.Serializable.

Non-serializable object bound to 'HttpSession'

Reports objects of classes not implementing java.io.Serializable used as arguments to javax.servlet.http.HttpSession.setAttribute() or javax.servlet.http.HttpSession.putValue().

Non-serializable object passed to 'ObjectOutputStream'

Reports non-Serializable objects used as arguments to java.io.ObjectOutputStream.write().

Non-short-circuit boolean expression

Reports usages of the non-short-circuit forms of boolean 'and' and 'or' (&, |, &= and |=).

Non-short-circuit operation consumes infinite stream

Reports non-short-circuit operations consuming an infinite stream.

Non-strict inequality '>=' or '<=' can be replaced with '=='

Reports inequality conditions that, according to data flow analysis, can be satisfied only for a single operand value.

Non-terminal use of '\s' escape sequence

Reports \s escape sequences anywhere except at text-block line endings or within a series of several escaped spaces.

Non-thread-safe 'static' field access

Reports access to static fields that are of a non-thread-safe type.

Non-varargs method overrides varargs method

Reports methods that override a variable arity (a.k.a.

Non-void @InitBinder method

Reports Spring MVC Controller methods annotated with @InitBinder that are not declared as void.

Null check can be replaced with method call

Reports null checks that can be replaced with a call to a static method from Objects or Stream.

Null value for Optional type

Reports null assigned to an Optional variable or returned from a method returning Optional.

Null-check method is called with obviously non-null argument

Reports if a null-checking method (for example, Objects.requireNonNull or Assert.assertNotNull) is called on a value that is obviously non-null (for example, a newly created object).

Nullability and data flow problems

Reports code constructs that always violate nullability contracts, may throw exceptions, or are just redundant, based on data flow analysis.

Number comparison using '==', instead of 'equals()'

Reports code that uses == or != instead of equals() to test for Number equality.

Number constructor call with primitive argument

Reports instantiations of new Long, Integer, Short, or Byte objects that have a primitive long, integer, short, or byte argument.

Numeric cast that loses precision

Reports cast operations between primitive numeric types that may result in precision loss.

Numeric overflow

Reports expressions that overflow during computation.

Object allocation in loop

Reports object or array allocations inside loops.

Object comparison using '==', instead of 'equals()'

Reports code that uses == or != rather than equals() to test for object equality.

Object instantiation inside 'equals()' or 'hashCode()'

Reports construction of (temporary) new objects inside equals(), hashCode(), compareTo(), and Comparator.compare() methods.

Octal and decimal integers in same array

Reports mixed octal and decimal integer literals in a single array initializer.

Old TestNG annotation @Configuration is used

Reports TestNG org.testng.annotations.Configuration annotations.

Old style JUnit test method in JUnit 4 class

Reports JUnit 3 style test methods that are located inside a class that does not extend the JUnit 3 TestCase class and contains JUnit 4 or JUnit 5 @Test annotated methods.

Only one element is used

Reports lists, arrays, and strings where exactly one element is queried right upon the creation.

Optional call chain can be simplified

Reports Optional call chains that can be simplified.

Optional.get() is called without isPresent() check

Reports calls to get() on an Optional without checking that it has a value.

Overloaded methods with same number of parameters

Reports methods that are declared in the same class, have the same name, and the same number of parameters.

Overloaded varargs method

Reports varargs methods with the same name as other methods in the class or in a superclass.

Overly broad 'catch' block

Reports catch blocks with parameters that are more generic than the exception thrown by the corresponding try block.

Overly broad 'throws' clause

Reports throws clauses with exceptions that are more generic than the exceptions that the method actually throws.

Overly complex anonymous class

Reports anonymous inner classes whose total complexity exceeds the specified maximum.

Overly complex class

Reports classes whose total complexity exceeds the specified maximum.

Overly complex method

Reports methods that have too many branch points.

Overly coupled class

Reports classes that reference too many other classes.

Overly coupled method

Reports methods that reference too many other classes.

Overly large initializer for array of primitive type

Reports array initializer expressions for primitive arrays that contain too many elements.

Overly long lambda expression

Reports lambda expressions whose number of statements exceeds the specified maximum.

Overly long method

Reports methods whose number of statements exceeds the specified maximum.

Overly nested method

Reports methods whose body contain too deeply nested statements.

Overly strong type cast

Reports type casts that are overly strong.

Overridable method called during object construction

Reports calls to overridable methods of the current class during object construction.

Overridden method called during object construction

Reports any calls to overridden methods of the current class during object construction.

Overwritten Map, Set, or array element

Reports code that overwrites a Map key, a Set element, or an array element in a sequence of add/put calls or using a Java 9 factory method like Set.of (which will result in runtime exception).

Package naming convention

Reports packages whose names are either too short, too long, or do not follow the specified regular expression pattern.

Package with classes in multiple modules

Reports non-empty packages that are present in several modules.

Package with disjoint dependency graph

Reports packages whose classes can be separated into mutually independent subsets.

Package with too few classes

Reports packages that contain fewer classes than the specified minimum.

Package with too many classes

Reports packages that contain too many classes.

Package-visible field

Reports fields that are declared without any access modifier (also known as package-private).

Package-visible nested class

Reports nested classes that are declared without any access modifier (also known as package-private).

Parameter hides field

Reports method parameters named identically to a field of a surrounding class.

Parameter name differs from parameter in overridden or overloaded method

Reports parameters whose names differ from the corresponding parameters of the methods they override or overload.

Parameter type prevents overriding

Reports parameter types of a subclass method that have the same name as the parameter type of the corresponding super method but belong to a different package.

Parameterized test class without data provider method

Reports JUnit 4 parameterized test classes that are annotated with @RunWith(Parameterized.class) but either do not include a data provider method annotated with @Parameterized.Parameters or this method has an incorrect signature.

Pattern annotation is not applicable

Reports when a @Pattern annotation is applied to an element with a type other than String.

Pattern variable can be used

Reports local variable declarations that can be replaced with pattern variables, which are usually more compact.

Pattern variable hides field

Reports pattern variables named identically to a field of a surrounding class.

Pointless 'indexOf()' comparison

Reports unnecessary comparisons with .indexOf() expressions.

Pointless bitwise expression

Reports pointless bitwise expressions.

Pointless boolean expression

Reports unnecessary or overly complicated boolean expressions.

Possible heap pollution from parameterized vararg type

Reports methods with variable arity, which can be annotated as @SafeVarargs.

Possibly lossy implicit cast in compound assignment

Reports compound assignments if the type of the right-hand operand is not assignment compatible with the type of the variable.

Possibly unintended overload of method from superclass

Reports instance methods with the same name and the same number of parameters as a method in a superclass, but where at least one of the parameters is of a different incompatible type.

Preview Feature warning

Reports usages of Preview Feature APIs, i.e.

Private method only used from inner class

Reports private methods which are only called from an inner class of the class containing the method.

Prohibited 'Exception' caught

Reports catch clauses that catch an inappropriate exception.

Prohibited exception declared

Reports methods that declare an inappropriate exception in their throws clause.

Prohibited exception thrown

Reports throw statements that throw an inappropriate exception.

Property value set to itself

Reports calls of setter methods with the same object getter as a value.

Protected field

Reports protected fields.

Protected nested class

Reports protected nested classes.

Public constructor in abstract class

Reports public constructors of abstract classes.

Questionable name

Reports variables, methods, or classes with questionable, not really descriptive names.

Raw use of parameterized class

Reports generic classes with omitted type parameters.

Reassigned variable

Reports reassigned variables, which complicate reading and understanding the code.

Record can be converted to class

Reports record classes and suggests converting them to ordinary classes.

Record pattern can be used

Reports patterns that can be replaced with record patterns.

Redundant 'Collection' operation

Reports unnecessarily complex collection operations which have simpler alternatives.

Redundant 'Collection.addAll()' call

Reports Collection.addAll() and Map.putAll() calls immediately after an instantiation of a collection using a no-arg constructor.

Redundant 'File' instance creation

Reports redundant File creation in one of the following constructors when only String path can be used: FileInputStream, FileOutputStream, FileReader, FileWriter, PrintStream, PrintWriter, Formatter.

Redundant 'String' operation

Reports redundant calls to String constructors and methods like toString() or substring() that can be replaced with a simpler expression.

Redundant 'close()'

Reports unnecessary calls to close() at the end of a try-with-resources block and suggests removing them.

Redundant 'compare()' method call

Reports comparisons in which the compare method is superfluous.

Redundant 'else'

Reports redundant else keywords in if—else statements and statement chains.

Redundant 'isInstance()' or 'cast()' call

Reports redundant calls of java.lang.Class methods.

Redundant 'new' expression in constant array creation

Reports constant new array expressions that can be replaced with an array initializer.

Redundant 'requires' directive in module-info

Reports redundant requires directives in Java Platform Module System module-info.java files.

Redundant 'throws' clause

Reports exceptions that are declared in a method's signature but never thrown by the method itself or its implementations and overriding methods.

Redundant @ScheduledForRemoval annotation

Reports usages of @ApiStatus.ScheduledForRemoval annotation without inVersion attribute in code which targets Java 9 or newer version.

Redundant array creation

Reports arrays that are created specifically to be passed as a varargs parameter.

Redundant array length check

Reports unnecessary array length checks followed by array iteration.

Redundant call to 'String.format()'

Reports calls to methods like format() and printf() that can be safely removed or simplified.

Redundant embedded expression in string template

Reports redundant embedded expressions in STR templates, such as trivial literals or empty expressions.

Redundant escape in regex replacement string

Reports redundant escapes in the replacement string of regex methods.

Redundant field initialization

Reports fields explicitly initialized to their default values.

Redundant interface declaration

Reports interfaces in a class' implements list or an interface's extends list that are already implemented by a superclass or extended by a superinterface.

Redundant lambda parameter types

Reports lambda formal parameter types that are redundant because they can be inferred from the context.

Redundant no-arg constructor

Reports unnecessary constructors.

Redundant operation on 'java.time' object

Reports redundant operation on 'java.time' object redundant: creation of date/time objects from the JDK java.time package when simpler method calls can be used or creation can be avoided.

Redundant operation on empty container

Reports redundant operations on empty collections, maps or arrays.

Redundant record constructor

Reports redundant constructors declared inside Java records.

Redundant step in 'Stream' or 'Optional' call chain

Reports redundant Stream or Optional calls like map(x -> x), filter(x -> true) or redundant sorted() or distinct() calls.

Redundant type cast

Reports unnecessary cast expressions.

Redundant usage of unmodifiable collection wrappers

Reports redundant calls to unmodifiable collection wrappers from the Collections class.

Reference checked for 'null' is not used inside 'if'

Reports references to variables that are checked for nullability in the condition of an if statement or conditional expression but not used inside that if statement.

Reference to empty collection field can be replaced with method call

Reports usages of java.util.Collections fields: EMPTY_LIST, EMPTY_MAP or EMPTY_SET.

References to classes from the default package in JSP files

Reports any references to classes from the default package in JSP files.

Reflective access across modules issues

Reports Class.forName() and ClassLoader.loadClass() calls which try to access classes that aren't visible in the current scope due to Java 9 module accessibility rules.

Reflective access to a source-only annotation

Reports attempts to reflectively check for the presence of a non-runtime annotation.

Reflective access to non-existent or not visible class member

Reports reflective access to fields and methods that don't exist or aren't visible.

Reflective invocation arguments mismatch

Reports cases in which the arguments provided to Method.invoke() and Constructor.newInstance() do not match the signature specified in Class.getMethod() and Class.getConstructor().

Replacement operation has no effect

Reports calls to the String methods replace(), replaceAll() or replaceFirst() that have no effect.

Resource method with multiple HTTP method annotations

Reports resource methods with multiple HTTP method annotations (@GET, @POST, @PUT, and so on).

Result of '++' or '--' used

Reports increment or decrement expressions that are nested inside other expressions.

Result of method call ignored

Reports method calls whose result is ignored.

Return of 'null'

Reports return statements with null return values.

Return of 'this'

Reports methods returning this.

Return of instance of anonymous, local or inner class

Reports return statements that return an instance of an anonymous, local, or inner class.

Return value is outside of declared range

Reports numeric values returned from methods that don't conform to the declared method return range.

Same file subclasses are missing from permits clause of a sealed class

Reports sealed classes without an explicit permits list.

Scope of variable is too broad

Reports any variable declarations that can be moved to a smaller scope.

SequencedCollection method can be used

Reports collection API method calls that can be simplified using SequencedCollection methods.

Serializable non-static inner class without 'serialVersionUID'

Reports classes that may be serialized or deserialized.

Serializable class with unconstructable ancestor

Reports Serializable classes whose closest non-serializable ancestor doesn't have a no-argument constructor.

Serializable non-static inner class without 'serialVersionUID'

Reports Serializable classes that do not implement readObject() and writeObject() methods.

Serializable non-static inner class without 'serialVersionUID'

Reports non-static inner classes that implement Serializable and are declared inside a class that doesn't implement Serializable.

Serializable non-static inner class without 'serialVersionUID'

Reports non-static inner classes that implement java.io.Serializable, but do not define a serialVersionUID field.

Shift operation by inappropriate constant

Reports shift operations where the shift value is a constant outside the reasonable range.

Simplifiable 'Map' operations

Reports common usage patterns of java.util.Map and suggests replacing them with: getOrDefault(), computeIfAbsent(), putIfAbsent(), merge(), or replaceAll().

Simplifiable annotation

Reports annotations that can be simplified to their single-element or marker shorthand form.

Simplifiable assertion

Reports any assert calls that can be replaced with simpler and equivalent calls.

Simplifiable boolean expression

Reports boolean expressions that can be simplified.

Simplifiable collector

Reports collectors that can be simplified.

Simplifiable conditional expression

Reports conditional expressions and suggests simplifying them.

Simplifiable forEach() call

Reports forEach() calls that can be replaced with a more concise method or from which intermediate steps can be extracted.

Single character 'startsWith()' or 'endsWith()'

Reports calls to String.startsWith() and String.endsWith() where single character string literals are passed as an argument.

Single character string argument in 'String.indexOf()' call

Reports single character strings being used as an argument in String.indexOf() and String.lastIndexOf() calls.

Single character string concatenation

Reports concatenation with string literals that consist of one character.

Single class import

Reports import statements that import single classes (as opposed to entire packages).

Singleton

Reports singleton classes.

Socket opened but not safely closed

Reports socket resources that are not safely closed.

Sorted collection with non-comparable elements

Reports construction of sorted collections, for example TreeSet, that rely on natural ordering, whose element type doesn't implement the Comparable interface.

Standard 'Charset' object can be used

Reports methods and constructors in which constant charset String literal (for example, "UTF-8") can be replaced with the predefined StandardCharsets.UTF_8 code.

Standard 'hashCode()' method can be used

Reports bitwise operations that can be replaced with a call to the Long.hashCode() or Double.hashCode() methods.

Standard variable names

Reports variables with 'standard' names that do not correspond to their types.

Statement can be replaced with 'assert' or 'Objects.requireNonNull'

Reports if statements that throw only java.lang.Throwable from a then branch and do not have an else branch.

Statement can be replaced with enhanced 'switch'

Reports switch statements that can be automatically replaced with enhanced switch statements or expressions.

Statement lambda can be replaced with expression lambda

Reports lambda expressions with code block bodies when expression-style bodies can be used instead.

Static collection

Reports static fields of a Collection type.

Static field may not be initialized

Reports static variables that may be uninitialized upon class initialization.

Static field referenced via subclass

Reports accesses to static fields where the call is qualified by a subclass of the declaring class, rather than by the declaring class itself.

Static field used before initialization

Reports static variables that are read before initialization.

Static import

Reports import static statements.

Static inheritance

Reports interfaces that are implemented only to provide access to constants.

Static initializer references subclass

Reports classes that refer to their subclasses in static initializers or static fields.

Static member guarded by instance field or this

Reports @GuardedBy annotations on static fields or methods in which the guard is either a non-static field or this.

Static member only used from one other class

Reports static methods and fields that are only used from a class other than the containing class.

Static method referenced via subclass

Reports static method calls where the call is qualified by a subclass of the declaring class, rather than by the declaring class itself.

Stream API call chain can be replaced with loop

Reports Stream API chains, Iterable.forEach(), and Map.forEach() calls that can be automatically converted into classical loops.

Stream API call chain can be simplified

Reports stream API call chains that can be simplified.

String comparison using '==', instead of 'equals()'

Reports code that uses of == or != to compare strings.

String concatenation

Reports String concatenations.

String concatenation as argument to 'MessageFormat.format()' call

Reports non-constant string concatenations used as an argument to a call to MessageFormat.format().

String concatenation as argument to 'StringBuilder.append()' call

Reports String concatenation used as the argument to StringBuffer.append(), StringBuilder.append() or Appendable.append().

String concatenation as argument to 'format()' call

Reports non-constant string concatenations used as a format string argument.

String concatenation in loop

Reports String concatenation in loops.

String literal may be 'equals()' qualifier

Reports String.equals() or String.equalsIgnoreCase() calls with a string literal argument.

String template can be concatenated string

Reports string template expressions using the STR processor and offers a quick-fix to migrate back to a plain string concatenation.

String template can be used

Reports String concatenations that can be simplified by replacing them with a string template.

String.repeat() can be used

Reports loops that can be replaced with a single String.repeat() method (available since Java 11).

StringBuilder constructor call with 'char' argument

Reports calls to StringBuffer and StringBuilder constructors with char as the argument.

Subclass field hides superclass field

Reports fields in a derived class that are named identically a field of a superclass.

Subsequent steps can be fused into Stream API chain

Detects transformations outside a Stream API chain that could be incorporated into it.

Subtraction in 'compareTo()'

Reports subtraction in compareTo() methods and methods implementing java.util.Comparator.compare().

Suspicious 'Arrays' method call

Reports calls to non-generic-array manipulation methods like Arrays.fill() with mismatched argument types.

Suspicious 'Class.getClass()' call

Reports getClass() methods that are called on a java.lang.Class instance.

Suspicious 'Collection.toArray()' call

Reports suspicious calls to Collection.toArray().

Suspicious 'Comparator.compare()' implementation

Reports problems in Comparator.compare() and Comparable.compareTo() implementations.

Suspicious 'InvocationHandler' implementation

Reports implementations of InvocationHandler that do not proxy standard Object methods like hashCode(), equals(), and toString().

Suspicious 'List.remove()' in loop

Reports list.remove(index) calls inside an ascending counted loop.

Suspicious 'System.arraycopy()' call

Reports suspicious calls to System.arraycopy().

Suspicious array cast

Reports suspicious array casts.

Suspicious byte value returned from 'InputStream.read()'

Reports expressions of byte type returned from a method implementing the InputStream.read() method.

Suspicious collection method call

Reports method calls on parameterized collections, where the actual argument type does not correspond to the collection's elements type.

Suspicious date format pattern

Reports date format patterns that are likely used by mistake.

Suspicious getter/setter

Reports getter or setter methods that access a field that is not expected by its name.

Suspicious indentation after control statement without braces

Reports suspicious indentation of statements after a control statement without braces.

Suspicious integer division assignment

Reports assignments whose right side is a division that shouldn't be truncated to integer.

Suspicious oddness check

Reports odd-even checks of the following form: x % 2 == 1.

Suspicious regex expression argument

Reports calls to String.replaceAll() or String.split() where the first argument is a single regex meta character argument.

Suspicious ternary operator in varargs method call

Reports vararg method calls that use a ternary operator with mixed array and non-array branches.

Suspicious underscore in number literal

Reports decimal number literals that use the underscore numeric separator with groups where the number of digits is not three.

Suspicious usage of compare method

Reports comparisons of the result of Comparator.compare() or Comparable.compareTo() calls with non-zero constants.

Synchronization on 'getClass()'

Reports synchronization on a call to getClass().

Synchronization on 'static' field

Reports synchronization on static fields.

Synchronization on 'this'

Reports synchronization on this or class expressions.

Synchronization on a 'Lock' object

Reports synchronized blocks that lock on an instance of java.util.concurrent.locks.Lock.

Synchronization on a non-final field

Reports synchronized statement lock expressions that consist of a non-final field reference.

Synchronization on an object initialized with a literal

Reports synchronized blocks that lock on an object initialized with a literal.

Synchronization on local variable or method parameter

Reports synchronization on a local variable or parameter.

Synthetic accessor call

Reports references from a nested class to non-constant private members of an outer class.

Test annotation without '@Retention(RUNTIME)' annotation

Reports annotations with a SOURCE or CLASS retention policy that are supposed to be used by JUnit 5.

TestNG Javadoc can be converted to annotations

Asserts your TestNG tests with Javadoc annotations and converts them to JDK annotations.

Text block can be replaced with regular string literal

Reports text blocks that can be replaced with regular string literals.

Text block can be used

Reports String concatenations that can be simplified by replacing them with text blocks.

Throwable supplier never returns a value

Reports Supplier lambdas in Optional.orElseThrow() calls that throw an exception, instead of returning it.

Too weak variable type leads to unnecessary cast

Reports type casts that can be removed if the variable type is narrowed to the cast type.

Trailing whitespace in text block

Reports text blocks with trailing whitespace characters.

Transient field in non-serializable class

Reports transient fields in classes that do not implement java.io.Serializable.

Transient field is not initialized on deserialization

Reports transient fields that are initialized during normal object construction, but whose class does not have a readObject method.

Trivial usage of functional expression

Reports functional interface methods calls that are directly invoked on the definition of the lambda, method reference, or anonymous class.

Type may be weakened

Reports variable and method return types that can be changed to a more abstract (weaker) type.

Type parameter explicitly extends 'Object'

Reports type parameters and wildcard type arguments that are explicitly declared to extend java.lang.Object.

Type parameter extends 'final' class

Reports type parameters declared to extend a final class.

Type parameter hides visible type

Reports type parameters that have the same names as the visible types in the current scope.

Unary plus

Reports usages of the + unary operator.

Unchecked 'Exception' class

Reports subclasses of java.lang.RuntimeException.

Unchecked exception declared in 'throws' clause

Reports declaration of an unchecked exception (java.lang.RuntimeException or one of its subclasses) in the throws clause of a method.

Unchecked warning

Reports code on which an unchecked warning will be issued by the javac compiler.

Unconditional 'wait()' call

Reports wait() being called unconditionally within a synchronized context.

Undeclared test

Reports test classes that are not registered in testing.xml.

Undefined group name

Reports undefined group names passed to the dependsOnGroups or groups attributes in the @Test annotation.

Underscores in numeric literal

Reports numeric literals with underscores and suggests removing them with a quick-fix.

Unguarded field access or method call

Reports accesses of fields declared as @GuardedBy that are not guarded by an appropriate synchronization structure.

Unknown '@GuardedBy' field

Reports @GuardedBy annotations in which the specified guarding field is unknown.

Unknown Language ID

Reports when the ID of the language used in a @Language annotation is unknown.

Unnecessarily escaped character

Reports unnecessarily escaped characters in String and optionally char literals.

Unnecessarily qualified inner class access

Reports any references to inner classes that are unnecessarily qualified with the name of the enclosing class.

Unnecessarily qualified static access

Reports usages of static members unnecessarily qualified with the class name.

Unnecessarily qualified statically imported element

Reports usage of statically imported members qualified with their containing class name.

Unnecessary 'break' statement

Reports any unnecessary break statements.

Unnecessary 'default' for enum 'switch' statement

Reports enum switch statements or expression with default branches which can never be taken, because all possible values are covered by a case branch.

Unnecessary 'final' on local variable or parameter

Reports local variables or parameters unnecessarily declared final.

Unnecessary 'null' check before 'equals()' call

Reports comparisons to null that are followed by a call to equals() with a constant argument.

Unnecessary 'null' check before method call

Reports null checks followed by a method call that will definitely return false when null is passed (e.g.

Unnecessary 'super' qualifier

Reports unnecessary super qualifiers in method calls and field references.

Unnecessary 'this' qualifier

Reports unnecessary this qualifier.

Unnecessary '{@inheritDoc}' Javadoc comment

Reports Javadoc comments that contain only an {@inheritDoc} tag.

Unnecessary Javadoc link

Reports Javadoc @see, {@link}, and {@linkplain} tags that refer to the method owning the comment, the super method of the method owning the comment, or the class containing the comment.

Unnecessary boxing

Reports explicit boxing, that is wrapping of primitive values in objects.

Unnecessary call to 'Throwable.initCause()'

Reports calls to Throwable.initCause() where an exception constructor also takes a Throwable cause argument.

Unnecessary call to 'super()'

Reports calls to no-arg superclass constructors during object construction.

Unnecessary call to 'toString()'

Reports calls to toString() that are used in the following cases: In string concatenations In the java.lang.StringBuilder#append() or java.lang.StringBuffer#append() methods In the methods of java.io.PrintWriter or java.io.PrintStream in the methods org.slf4j.Logger In these cases, conversion to string will be handled by the underlying library methods, and the explicit call to toString() is not needed.

Unnecessary code block

Reports code blocks that are redundant to the semantics of the program and can be replaced with their contents.

Unnecessary conversion to 'String'

Reports unnecessary calls to static methods that convert their parameters to a string, e.g.

Unnecessary explicit numeric cast

Reports primitive numeric casts that would be inserted implicitly by the compiler.

Unnecessary final before 'val'

Reports unneeded final modifiers before val.

Unnecessary import from the 'java.lang' package

Reports import statements that refer to the java.lang package.

Unnecessary import from the same package

Reports import statements that refer to the same package as the containing file.

Unnecessary modifier

Reports redundant modifiers and suggests to remove them.

Unnecessary qualifier for 'this' or 'super'

Reports unnecessary qualification of this or super.

Unnecessary temporary object in conversion from 'String'

Reports unnecessary creation of temporary objects when converting from String to primitive types.

Unnecessary temporary object in conversion to 'String'

Reports unnecessary creation of temporary objects when converting from a primitive type to String.

Unnecessary unary minus

Reports unnecessary unary minuses.

Unnecessary unboxing

Reports unboxing, that is explicit unwrapping of wrapped primitive values.

Unnecessary unicode escape sequence

Reports unnecessary unicode escape sequences.

Unnecessary zero length array usage

Reports allocations of arrays with known lengths of zero when there is a constant for that in the class of the array's element type.

Unpredictable 'BigDecimal' constructor call

Reports calls to BigDecimal constructors that accept a double value.

Unqualified inner class access

Reports references to inner classes that are not qualified with the name of the enclosing class.

Unqualified static access

Reports usage of static members that is not qualified with the class name.

Unreadable numeric literal

Reports long numeric literals without underscores and suggests adding them.

Unsafe call to 'Class.newInstance()'

Reports calls to java.lang.Class.newInstance().

Unsafe lazy initialization of 'static' field

Reports static variables that are lazily initialized in a non-thread-safe manner.

Unsynchronized method overrides 'synchronized' method

Reports non-synchronized methods overriding synchronized methods.

Unused label

Reports labels that are not targets of any break or continue statements.

Usage of Kotlin internal declarations from Java

Reports usages of Kotlin internal declarations in Java code that is located in a different module.

Usage of obsolete 'junit.framework.Assert' method

Reports any calls to methods from the junit.framework.Assert class.

Usage of service not declared in 'module-info'

Reports situations in which a service is loaded with java.util.ServiceLoader but it isn't declared with the uses clause in the module-info.java file and suggests inserting it.

Use of '$' in identifier

Reports variables, methods, and classes with dollar signs ($) in their names.

Use of 'DriverManager' to get JDBC connection

Reports any uses of java.sql.DriverManager to acquire a JDBC connection.

Use of 'Properties' object as a 'Hashtable'

Reports calls to the following methods on java.util.Properties objects: put() putIfAbsent() putAll() get() For historical reasons, java.util.Properties inherits from java.util.Hashtable, but using these methods is discouraged to prevent pollution of properties with values of types other than String.

Use of 'StringTokenizer'

Reports usages of the StringTokenizer class.

Use of 'System.out' or 'System.err'

Reports usages of System.out or System.err.

Use of 'clone()' or 'Cloneable'

Reports implementations of, and calls to, the clone() method and uses of the java.lang.Cloneable interface.

Use of 'java.lang.ProcessBuilder' class

Reports uses of java.lang.ProcessBuilder, which might be unportable between operating systems because paths to executables, environment variables, command-line arguments and their escaping might vary depending on the OS.

Use of 'sun.*' classes

Reports uses of classes from the sun.* hierarchy.

Use of AWT peer class

Reports uses of AWT peer classes.

Use of Optional.ofNullable with null or not-null argument

Reports uses of Optional.ofNullable() where always null or always not-null argument is passed.

Use of concrete JDBC driver class

Reports uses of specific JDBC driver classes.

Use of concrete class

Reports usages of concrete classes, rather than interfaces.

Use of index 0 in JDBC ResultSet

Reports attempts to access column 0 of java.sql.ResultSet or java.sql.PreparedStatement.

Use of obsolete collection type

Reports usages of java.util.Vector, java.util.Hashtable and java.util.Stack.

Use of obsolete date-time API

Reports usages of java.util.Date, java.util.Calendar, java.util.GregorianCalendar, java.util.TimeZone, and java.util.SimpleTimeZone.

Use of shallow or 'Objects' methods with arrays

Reports expressions that seem to use an inappropriate method for determining array equality or calculating their hashcode.

Use of variable whose value is known to be constant

Reports any usages of variables which are known to be constant.

Using 'Random.nextDouble()' to get random integer

Reports calls to java.util.Random.nextDouble() that are used to create a positive integer number by multiplying the call by a factor and casting to an integer.

Using 'instanceof' with patterns

Reports instanceof with patterns and suggests converting them to ordinary instanceof with casts.

Using PsiElement string representation to generate new expression is incorrect

Reports direct usage of PsiElement and PsiType in strings.

Using static import for Lombok-generated methods

Reports usages of static imports for Lombok's generated methods.

Utility class

Reports utility classes.

Utility class can be 'enum'

Reports utility classes that can be converted to enums.

Utility class is not 'final'

Reports utility classes that aren't final or abstract.

Utility class with 'public' constructor

Reports utility classes with public constructors.

Utility class without 'private' constructor

Reports utility classes without private constructors.

Validate annotated patterns

Reports expressions passed as arguments for @Pattern parameters and returned from @Pattern-annotated methods that do not match the specified pattern.

Value passed as parameter never read

Reports redundant method parameters that can be replaced with local variables.

Value-based warnings

Reports attempts to synchronize on an instance of a value-based class that produce compile-time warnings and raise run-time exceptions starting from Java 16.

Varargs method

Reports methods that accept an arbitrary number of parameters (also known as varargs methods).

Variable type can be explicit

Reports local variables of the var type that can be replaced with an explicit type.

Volatile array field

Reports array fields that are declared volatile.

Whitespace may be missing in string concatenation

Reports string concatenations with missing whitespaces, that is where the left-hand side ends with a Unicode letter or digit and the right-hand side starts with a Unicode letter or digit.

Wrapper type may be primitive

Reports local variables of wrapper type that are mostly used as primitive types.

Write-only object

Reports objects that are modified but never queried.

Wrong package statement

Detects package statements that do not correspond to the project directory structure.

Zero-length array allocation

Reports allocations of arrays with known lengths of zero.

JavaScript

Name

Description

'await' in non-async function

Reports a usage of await in a function that was possibly intended to be async but is actually missing the async modifier.

'break' statement

Reports a break statements.

'break' statement with label

Reports a labeled break statement.

'continue' or 'break' inside 'finally' block

Reports a break or continue statement inside a finally block.

'continue' statement

Reports a continue statement.

'continue' statement with label

Reports a labeled continue statement.

'debugger' statement

Reports a debugger statement used for interaction with the Javascript debuggers.

'default' not last case in 'switch'

Reports a switch statement where the default case comes before another case instead of being the very last case, which may cause confusion.

'for' loop may be replaced by 'while' loop

Reports a for loop that contains neither initialization nor an update component.

'for' loop where update or condition does not use loop variable

Reports a for loop where the condition or update does not use the for loop variable.

'for..in' is used instead of 'for..of'

Reports a usage of a for..in loop on an array.

'if' statement with identical branches

Reports an if statement with identical then and else branches.

'if' statement with too many branches

Reports an if statement with too many branches.

'let' is used instead of 'const'

Reports a let declaration that can be made const.

'module.exports' is used instead of 'export'

Reports a module.export statement.

'require()' is used instead of 'import'

Reports a require() statement.

'return' inside 'finally' block

Reports a return statement inside a finally block.

'switch' statement has missing branches

Reports a switch statement on a variable of the type enum or union when the statement doesn't cover some value options from the type.

'switch' statement has no 'default' branch

Reports a switch statement without a default clause when some possible values are not enumerated.

'switch' statement is redundant and can be replaced

Reports a switch statement with an empty body, or with only one case branch, or with a default branch only.

'switch' statement with no 'default' branch

Reports a switch statement without default branches in CoffeeScript content.

'this' expression which references the global object

Reports a this expression outside an object literal or a constructor body.

'throw' inside 'finally' block

Reports s throw statement inside a finally block.

'typeof' comparison with non-standard value

Reports a comparison of a typeof expression with a literal string which is not one of the standard types: undefined, object, boolean, number, string, function, or symbol.

'var' declared not at the beginning of a function

Checks that declarations of local variables declared with var are at the top of a function scope.

'var' is used instead of 'let' or 'const'

Reports a var declaration that is used instead of let or const.

'void' expression

Reports a void expression.

'with' statement

Reports a with statements.

Anonymous function

Reports an anonymous function.

Assignment could be replaced with operator assignment

Reports an assignment operation that can be replaced by an operator assignment to make your code shorter and probably clearer.

Assignment to 'for' loop parameter

Reports an assignment to a variable declared as a for loop parameter.

Assignment to function parameter

Reports an assignment to a function parameter, including increment and decrement operations.

Assignment used as condition

Reports an assignment that is used as the condition of an if, while, for, or do statement.

Attempt to assign to const or readonly variable

Reports reassigning a value to a constant or a readonly variable.

Bitwise expression can be simplified

Reports an expression that includes and with zero, or by zero, or shifting by zero.

Bitwise operator usage

Reports a suspicious usage of a bitwise AND ("&") or OR ("|") operator.

Call to 'document.write()'

Reports a method call to document.write() or document.writeln().

Chained equality

Reports a chained equality comparison (i.e.

Chained function call

Reports a function call whose target is another function call, for example, foo().bar().

Check JavaScript and TypeScript source code coverage

Reports methods, classes and files whose coverage is below a certain threshold.

Class naming convention

Reports a class or a function that is annotated with a JSDoc @constructor or @class tag whose names are too short, too long, or do not follow the specified regular expression pattern.

Comma expression

Reports a comma expression.

Comparison of expressions having incompatible types

Reports a comparison with operands of incompatible types or an operand with a type without possible common values.

Comparison with NaN

Reports a comparison with NaN.

Conditional expression

Reports a ternary conditional expression.

Conditional expression with identical branches

Reports a ternary conditional expression with identical then and else branches.

Confusing floating point literal

Reports any floating point number that does not have a decimal point, or any numbers before the decimal point, or and numbers after the decimal point.

Confusing sequence of '+' or '-'

Reports a suspicious combination of + or - characters in JavaScript code (for example, a+++b.

Consecutive commas in array literal

Reports a consecutive comma in an array literal.

Constant conditional expression

Reports a conditional expression in the format true? result1: result2 or false? result1: result2.

Constant on left side of comparison

Reports a comparison operation with a constant value in the left-hand side.

Constant on right side of comparison

Reports a comparison operation with a constant in the right-hand side.

Deprecated symbol used

Reports a usage of a deprecated function variable.

Destructuring properties with the same key

Reports multiple destructuring properties with identical keys.

Division by zero

Reports division by zero or a remainder by zero.

Duplicate 'case' label

Reports a duplicated case label on a switch statement, which normally indicates an error.

Duplicate condition in 'if' statement

Reports duplicate conditions in different branches of an if statement.

Duplicate declaration

Reports multiple declarations in a scope.

ECMAScript specification is not followed

Reports basic syntax issues and inconsistencies with language specification, such as invalid usages of keywords, usages of incompatible numeric format, or multiple parameters to getters/setters.

ESLint

Reports a discrepancy detected by the ESLint linter.

Empty 'catch' block

Reports an empty catch block.

Empty 'finally' block

Reports an empty finally block, which usually indicates an error.

Empty 'try' block

Reports an empty try block, which usually indicates an error.

Exception used for local control-flow

Reports a throw statement whose exceptions are always caught by the containing try statement.

Execution of dynamically generated code

Reports a call of the eval(), setTimeout(), or setInterval() function or an allocation of a Function object.

Expression statement which is not assignment or call

Reports an expression statement that is neither an assignment nor a call.

Fallthrough in 'switch' statement

Reports a switch statement where control can proceed from a branch to the next one.

Function expression is used instead of arrow function

Reports a function expression.

Function naming convention

Reports a function whose name is too short, too long, or does not follow the specified regular expression pattern.

Function parameter naming convention

Reports a function parameter whose name is too short, too long, or doesn't follow the specified regular expression pattern.

Function signature mismatch

Checks an argument in a CoffeeScript call expression that doesn't match the signature of the referenced function, including types, the number, and the order of arguments.

Function with inconsistent returns

Reports a function that returns a value in some cases while in other cases no value is returned.

Function with more than three negations

Reports a function with three or more negation operations (! or !=).

Function with multiple loops

Reports a function with multiple loop statements.

Function with multiple return points

Reports a function with multiple return points.

Function with too many parameters

Reports a function with too many parameters.

Highlight failure line in test code

Reports a failed method call or an assertion in a test.

Identifiers with non-ASCII symbols

Reports a non-ASCII symbol in a name.

Implicitly declared global JavaScript variable

Reports an implicit declaration of a global variable.

Import can be shortened

Reports an ES6 import whose from part can be shortened.

Inaccessible @private and @protected members referenced

Reports a reference to a JavaScript member that is marked with a @private or @protected tag but does not comply with visibility rules that these tags imply.

Inaccurate platform detection

Reports a common JavaScript pattern for detecting the browser or operating system in which the script is run.

Incompatible XHTML usages

Reports common JavaScript DOM patterns which may present problems with XHTML documents.

Incompatible bitwise mask operation

Reports a bitwise mask expression which for sure evaluates to true or false.

Incorrect usage of JSDoc tags

Reports warnings implied by Google Closure Compiler annotations including correct use of @abstract, @interface, and @implements tags.

Indexed 'for' is used instead of 'for..of'

Reports an indexed for loop used on an array.

Infinite loop statement

Reports a for, while, or do statement which can only exit by throwing an exception.

Infinite recursion

Reports a function which must either recurse infinitely or throw an exception.

Invalid DOM element nesting

Detects HTML elements in JSX files which are not nested properly according to the DOM specification.

Invalid Karma configuration file

Reports a potential error in a file path ('basePath', 'files') for a Karma configuration file, for example, karma.conf.js.

JQuery selector can be optimized

Reports a duplicated jQuery selector that can be cached or a usage of an attribute or a pseudo-selector (optional).

JSHint

Reports a problem detected by the JSHint linter.

JSX syntax used

Reports a usage of a JSX tag in JavaScript code.

Labeled statement

Reports a labeled statement.

Local variable naming convention

Reports a local variable whose name is too short, too long, or doesn't follow the specified regular expression pattern.

Loop statement that doesn't loop

Reports a for, while, or do statement whose bodies are guaranteed to execute at most once.

Magic number

Reports a "magic number" that is a numeric literal used without being named by a constant declaration.

Method can be made 'static'

Reports a class method that can be safely made static.

Mismatched JSDoc and function signature

Reports mismatch between the names and the number of parameters within a JSDoc comment and the actual parameters of a function.

Mismatched query and update of collection

Reports a collection of fields or variables whose contents are either queried and not updated or updated and not queried.

Missing JSX namespace

Reports a usage of a JSX construction without importing namespace.

Missing await for an async function call

Reports an async function call without an expected await prefix inside an async function.

Missing module dependency

Reports a module from a require() call or an import statement that is not installed or is not listed in package.json dependencies.

Module is not installed in importmap

Reports a not installed module and suggests running the importmap:require or importmap:install command.

Negated 'if' statement

Reports if statements which have an else branch and a negated condition.

Negated conditional expression

Reports a conditional expression whose condition is negated.

Nested 'switch' statement

Reports a switch statement that is nested in another switch statement.

Nested assignment

Reports an assignment expression nested inside another expression, for example, a = b = 1.

Nested conditional expression

Reports a ternary conditional expression within another ternary condition.

Nested function

Reports a function nested inside another function.

Nested function call

Reports a function call that is used as an argument in another function call, for example, foo(bar()).

Non-strict mode used

Reports a JavaScript file that is not in the strict mode.

Object is 'null' or 'undefined'

Reports an error caused by invoking a method, accessing a property, or calling a function on an object that is undefined or null.

Object literal call

Reports an object literal expression that is invoked as if it were a function.

Octal integer

Reports a deprecated octal integer literal prefixed with 0 instead of 0o.

Overly complex arithmetic expression

Reports an arithmetic expression with too many terms.

Overly complex boolean expression

Reports a boolean expression with too many terms.

Overly complex function

Reports a function with too many branching points in a function (too high cyclomatic complexity).

Overly long function

Reports an overly long function.

Overly nested function

Reports a function whose body contains statements that are too deeply nested within other statements.

Pointless arithmetic expression

Reports an arithmetic expression that include adding or subtracting zero, multiplying by zero or one, division by one, and shift by zero.

Pointless statement or boolean expression

Reports a pointless or pointlessly complicated boolean expression or statement.

Possibly incorrect target of indexed property access

Reports a potentially invalid indexed property access, for example, Array[1].

Potentially invalid constructor usage

Reports a usage of a potentially invalid constructor function, for example: a function that is not a constructor after new, using a constructor's prototype or calling a constructor without new.

Potentially invalid reference to 'this' from closure

Reports a this in closure that is used for referencing properties of outer context.

Potentially invalid reference to 'this' of a class from closure

Reports an attempt to reference a member of an ECMAScript class via the this.

Primitive type object wrapper used

Reports an improper usage of a wrapper for primitive types or a property of a primitive type being modified, as in the latter case the assigned value will be lost.

Property can be replaced with shorthand

Reports an object property that can be converted to ES6 shorthand style and provides a quick-fix to do it.

Redundant 'await' expression

Reports a redundant usage of await, such as await await, or awaiting a non-promise result.

Redundant 'if' statement

Reports an if statement that can be simplified to a single assignment or a return statement.

Redundant braces around arrow function body

Reports an arrow function whose body only consists of braces and exactly one statement.

Redundant conditional expression

Reports a conditional expression of the form condition ? true : false condition ? false : true These expressions may be safely converted to condition !condition.

Redundant local variable

Reports an unnecessary local variable that does not make a function more comprehensible: a local variable that is immediately returned a local variable that is immediately assigned to another variable and is not used anymore a local variable that always has the same value as another local variable or parameter.

Redundant nesting in template literal

Reports nested instances of a string or a template literal.

Referenced UMD global variable

Reports a usage of a Universal Module Definition (UMD) global variable if the current file is a module (ECMAScript or CommonJS).

Referencing mutable variable from closure

Reports access to outer mutable variables from functions.

Reserved word used as name

Reports a JavaScript reserved word used as a name.

Result of assignment used

Reports an assignment expression where the result of the assignment is used in the containing expression.

Result of increment or decrement used

Reports an increment (++) or decrement (--) expression where the result of the assignment is used in a containing expression.

Result of method call returning a promise is ignored

Reports a function call that returns a Promise that is not used later.

Result of object allocation ignored

Reports object allocation where the result of the allocated object is ignored, for example, new Error(); as a statement, without any assignment.

Reuse of local variable

Reports reusing a local variable and overwriting its value with a new value that is not related to the original variable usage.

Shift operation by possibly wrong constant

Reports a shift operation where the second operand is a constant outside the reasonable range, for example, an integer shift operation outside the range 0..31, shifting by negative or overly large values.

Signature mismatch

Reports a JavaScript call expression where the arguments do not match the signature of the referenced function, including the types of arguments and their number.

Standard code style

Reports a discrepancy detected by the JavaScript Standard Style linter.

Statement body without braces

Reports a if, while, for, or with statements whose body is not a block statement.

Statement with empty body

Reports an if, while, for, or with statement with an empty body.

String concatenation is used instead of template literal

Reports a string concatenation.

String literal which breaks HTML parsing

Reports a string literal that contains a </ sequence.

Suspicious '=+' assignment

Reports an assignment in the form a =+ b.

Suspicious usage of 'bind' with arrow function

Reports bind used together with an arrow function.

Suspicious variable/parameter name combination

Reports an assignment or a function call where the name of the target variable or the function parameter does not match the name of the value assigned to it.

Syntax errors and unresolved references in JSDoc

Reports a syntax discrepancy in a documentation comment.

Tail recursion

Reports a tail recursion, that is, when a function calls itself as its last action before returning.

Text label in 'switch' statement

Reports a labeled statement inside a switch statement, which often results from a typo.

Top-level 'await' expression

Reports a usage of a top-level await expression.

URL import is used

Checks used URL imports in the JavaScript language.

Undefined channel

Reports usages of undefined Action Cable channels.

Undefined property assignment

Reports an assignment to a property that is not defined in the type of a variable.

Unfiltered for..in loop

Reports unfiltered for-in loops.

Unnecessary 'continue' statement

Reports an unnecessary continue statement at the end of a loop.

Unnecessary 'return' statement

Reports an unnecessary return statement, that is, a return statement that returns no value and occurs just before the function would have "fallen through" the bottom.

Unnecessary block statement

Reports a block statement that is not used as the body of if, for, while, do, with, or try statements, or as the body of a function declaration.

Unnecessary label

Reports an unused label.

Unnecessary label on 'break' statement

Reports a labeled break statement whose labels may be removed without changing the flow of control.

Unnecessary label on 'continue' statement

Reports a labeled continue statement whose labels may be removed without changing the flow of control.

Unnecessary parentheses

Reports redundant parentheses.

Unnecessary semicolon

Reports an unneeded semicolon.

Unneeded last comma in array literal

Reports a usage of a trailing comma in an array literal.

Unneeded last comma in object literal

Reports usages of a trailing comma in object literals.

Unreachable 'case' branch of a 'switch' statement

Reports an unreachable case branch of a switch statement.

Unreachable code

Reports code that can never be executed, which almost certainly indicates an error.

Unresolved Ext JS xtype

Reports an Ext JS xtype reference that doesn't have a corresponding class.

Unresolved JSX component

Reports an unresolved reference to a JSX component.

Unresolved Node.js APIs

Suggests configuring coding assistance for Node.js, for example, require and/or core modules ('path', 'http', 'fs', etc.).

Unresolved file reference

Reports an unresolved file reference in a JavaScript file, including CommonJS and AMD modules references.

Unresolved reference

Reports an unresolved reference in JavaScript code.

Unsound type guard check

Reports a typeof or instanceof unsound type guard check.

Unterminated statement

Reports a statement without a semicolon or a newline at the end.

Unused 'catch' parameter

Reports a catch parameter that is not used in the corresponding block.

Unused assignment

Reports a variable whose value is never used after assignment.

Unused global symbol

Reports an unused globally accessible public function, variable, class, or property.

Unused import

Reports a redundant import statement.

Unused local symbol

Reports an unused locally accessible parameter, local variable, function, class, or private member declaration.

Use of 'caller' property

Reports a usage of the caller property in a JavaScript function.

Use of 'innerHTML' property

Reports a JavaScript access to DOM nodes as text using the innerHTML property.

Variable assigned to itself

Reports any assignment of the form x = x in CoffeeScript content.

Variable declaration can be merged with the first assignment to the variable

Reports a variable that is declared without an initializer and is used much further in the code or in a single nested scope.

Variable is assigned to itself

Reports an assignment in the form x = x.

Variable is declared and being used in different 'case' clauses

Reports a variable that is declared in one case clause of a switch statement but is used in another case clause of the same statement.

Void function return value used

Reports a return value of a function that doesn't return anything.

Vulnerable API usage

Reports usages of Vulnerable APIs of imported dependencies.

Webpack config compliance with JSON Schema

Validates options in webpack config files (which name should start with `webpack`, e.g.

Jpaql

Name

Description

Query language checks

Reports the following errors inside Persistence QL queries: Mismatching expression types Incorrect parameters Empty or constant conditions Unresolved symbols Example queries: SELECT OBJECT(e) FROM JavaEntity e WHERE TRUE // Warning: constant condition SELECT OBJECT(e) FROM JavaEntity e WHERE e.id BETWEEN 0 AND '2' // Error: expected a numeric value but got a string SELECT e from JavaEntity e where e.id=?1 and e.name=?3 // Error: there are only 2 actual query parameters.

Json

Name

Description

Angular CLI add dependency

Suggests using the ng add command to install the dependency.

Auth configuration validation

Reports Auth configuration the following problems in HTTP Client environment files: Missing properties in Auth configuration Auth/Security configuration placed in private environment file.

Compliance with JSON schema

Reports inconsistence between a JSON file and the JSON schema that is assigned to it.

Compliance with JSON standard

Reports the following discrepancies of a JSON file with the language specification: A line or block comment (configurable).

Deprecated JSON property

Reports a deprecated property in a JSON file.

Duplicate keys in object literals

Reports a duplicate key in an object literal.

Duplicate package entries in composer.json

Reports duplicate package entries in the require and require-dev sections of composer.json.

Inconsistent tsconfig.json properties

Reports inconsistency of a paths, checkJs, or extends property in a tsconfig.json file.

Invalid additional-spring-configuration-metadata.json

Reports missing and deprecated properties, unresolved references, and invalid values in the additional-spring-configuration-metadata.json configuration file.

Mismatched dependencies in package.json

Reports a dependency from package.json that is not installed or doesn't match the specified version range.

Missing request separator in JSON body

Reports possible requests in injected JSON body where request separator ### is missing.

Non-installed Composer packages

Reports the Composer packages that are required in composer.json but are not installed.

Quality tool inspection is disabled

Highlights the quality tools' entries in composer.json in case the corresponding code inspections are disabled.

Unknown inspection id in meta information

Reports unknown inspection ids in metaInformation.json files.

Unreal Engine json inspection

RIDER-83134.

Unresolved '$ref' and '$schema' references

Reports an unresolved $ref or $schema path in a JSON schema.

Update package.json dependencies to latest versions

Suggests to upgrade your package.json dependencies to the latest versions, ignoring specified versions.

Validate IDE settings

.

Variable should be double-quoted

Reports variables which should be double-quoted in json body.

Json5

Name

Description

Compliance with JSON5 standard

Reports inconsistency with the language specification in a JSON5 file.

Jsonpath

Name

Description

Unknown JSONPath function

Reports an unknown name in a JSONPath function call instead of known standard function names: concat, keys, length, min, max, avg, stddev, sum.

Unknown JSONPath operator

Reports an unknown operator on a JSONPath expression instead of one of the standard ones: in, nin, subsetof, anyof, noneof, size, empty, contains.

Unknown property key used for JSONPath evaluate expression

Reports a key in a JSONPath expression that is missing in the source JSON document to evaluate.

Jupyter

Name

Description

The 'jupyter' package is not installed

Reports cases when the jupyter package is not installed for the selected Python interpreter.

Kotlin

Name

Description

'@Deferred' result is unused

Reports function calls with the Deferred result type if the return value is not used.

'@JvmOverloads' annotation cannot be used on constructors of annotation classes since 1.4

Reports @JvmOverloads on constructors of annotation classes because it's meaningless.

'Enum.values()' is recommended to be replaced by 'Enum.entries' since 1.9

Reports calls from Kotlin to values() method in enum classes that can be replaced with entries property read.

'HashMap' can be replaced with 'EnumMap'

Reports hashMapOf function or HashMap constructor calls that can be replaced with an EnumMap constructor call.

'String.format' call can be replaced with string templates

Reports String.format calls that can be replaced with string templates.

'StringBuilder.append(CharArray, offset, len)' call on the JVM

Reports a StringBuilder.append(CharArray, offset, len) function call on the JVM platform that should be replaced with a StringBuilder.appendRange(CharArray, startIndex, endIndex) function call.

'arrayOf' call can be replaced with array literal [...]

Reports arrayOf calls that can be replaced with array literals [...].

'assert' call can be replaced with '!!' or '?:'

Reports assert calls that check a not null value of the declared variable.

'associate' can be replaced with 'associateBy' or 'associateWith'

Reports calls to associate() and associateTo() that can be replaced with associateBy() or associateWith().

'catch' block may ignore exception

Reports catch blocks that are empty or may ignore an exception.

'copy' method of data class is called without named arguments

Reports calls to a data class' copy() method without named arguments.

'filterIsInstance' call with a class literal argument

Reports calls of the Kotlin standard library function filterIsInstance with a class literal argument.

'if' condition can be replaced with lambda call

Reports isEmpty, isBlank, isNotEmpty, or isNotBlank calls in an if statement to assign a default value.

'inline fun' extension receiver can be explicitly nullable until Kotlin 1.2

Reports inline functions with non-nullable extension receivers which don't use the fact that extension receiver is not nullable.

'inline fun' with nullable receiver until Kotlin 1.2

Reports potentially unsafe calls of inline functions with flexible nullable (platform type with unknown nullability) extension receivers.

'kotlin.browser' and 'kotlin.dom' packages are deprecated since 1.4

Reports usages of kotlin.dom and kotlin.browser packages.

'lateinit var' property overrides 'lateinit var' property

Reports lateinit var properties that override other lateinit var properties.

'map.get()' with not-null assertion operator (!!)

Reports map.get()!! that can be replaced with map.getValue(), map.getOrElse(), and so on.

'map.put()' can be converted to assignment

Reports map.put function calls that can be replaced with indexing operator ([]).

'protected' visibility is effectively 'private' in a final class

Reports protected visibility used inside of a final class.

'rangeTo' or the '..' call should be replaced with '..<'

Reports calls to rangeTo or the .

'rangeTo' or the '..' call should be replaced with 'until'

Reports calls to rangeTo or the .

'readLine' can be replaced with 'readln' or 'readlnOrNull'

Reports calls to readLine() that can be replaced with readln() or readlnOrNull().

'substring' call should be replaced with 'dropLast' call

Reports calls like s.substring(0, s.length - x) that can be replaced with s.dropLast(x).

'substring' call should be replaced with 'substringAfter'

Reports calls like s.substring(s.indexOf(x)) that can be replaced with s.substringAfter(x).

'substring' call should be replaced with 'substringBefore'

Reports calls like s.substring(0, s.indexOf(x)) that can be replaced with s.substringBefore(x).

'substring' call should be replaced with 'take' call

Reports calls like s.substring(0, x) that can be replaced with s.take(x).

'substring' call should be replaced with indexing operator

Reports calls like "abc".substring(0, 1) that can be replaced with "abc"[0].

'to' call should be replaced with infix form

Reports to function calls that can be replaced with the infix form.

'when' has only 'else' branch and can be simplified

Reports when expressions with only an else branch that can be simplified.

'when' that can be simplified by introducing an argument

Reports a when expression that can be simplified by introducing a subject argument.

@Deprecated annotation without 'replaceWith' argument

Reports deprecated functions and properties that do not have the kotlin.ReplaceWith argument in its kotlin.deprecated annotation and suggests to add one based on their body.

Accessor call that can be replaced with property access syntax

Reports Java get and set method calls that can be replaced with the Kotlin synthetic properties.

Ambiguous coroutineContext due to CoroutineScope receiver of suspend function

Reports calls and accesses of CoroutineScope extensions or members inside suspend functions with CoroutineScope receiver.

Ambiguous logical expressions in 'when' branches since 1.7

Reports ambiguous logical expressions in when branches which cause compilation errors in Kotlin 1.8 and later.

Ambiguous non-local 'break' or 'continue'

Reports break or continue usages inside of lambdas of loop-like functions.

Ambiguous unary operator use with number constant

Reports an unary operator followed by a dot qualifier such as -1.inc().

Argument could be converted to 'Set' to improve performance

Detects the function calls that could work faster with an argument converted to Set.

Array property in data class

Reports properties with an Array type in a data class without overridden equals() or hashCode().

Arrays comparison via '==' and '!='

Reports usages of == or != operator for arrays that should be replaced with contentEquals().

Assert boolean could be replaced with assert equality

Reports calls to assertTrue() and assertFalse() that can be replaced with assert equality functions.

Augmented assignment creates a new collection under the hood

Reports augmented assignment (+=) expressions on a read-only Collection.

Boolean literal argument without parameter name

Reports call arguments with Boolean type without explicit parameter names specified.

Boxed properties should be replaced with unboxed

Reports boxed Range.start and Range.endInclusive properties.

Call chain on collection could be converted into 'Sequence' to improve performance

Reports call chain on a Collection that should be converted into Sequence.

Call chain on collection type can be simplified

Reports two-call chains replaceable by a single call.

Call of 'toString' could be replaced with string template

Reports toString function calls that can be replaced with a string template.

Call of Java mutator method on immutable Kotlin collection

Reports Java mutator methods calls (like fill, reverse, shuffle, sort) on an immutable Kotlin collection.

Call to 'print()' or 'println()'

Reports usages of print or println.

Can be replaced with binary operator

Reports function calls that can be replaced with binary operators, in particular comparison-related ones.

Can be replaced with function reference

Reports function literal expressions that can be replaced with function references.

Can be replaced with lambda

Reports a function reference expression that can be replaced with a function literal (lambda).

Cascade 'if' can be replaced with 'when'

Reports if statements with three or more branches that can be replaced with the when expression.

Class member can have 'private' visibility

Reports declarations that can be made private to follow the encapsulation principle.

Collection count can be converted to size

Reports calls to Collection<T>.count().

Companion object in extensions

Reports incorrect companion objects' usage in extensions.

Condition of 'if' expression is constant

Reports if expressions that have true or false constant literal condition and can be simplified.

Const property naming convention

Reports const property names that do not follow the recommended naming conventions.

Constant conditions

Reports non-trivial conditions and values that are statically known to be always true, false, null or zero.

Constructor can never be complete

Reports constructors with a non-null self-reference parameter.

Constructor parameter is never used as a property

Reports primary constructor parameters that can have val or var removed.

Control flow with empty body

Reports if, while, do or for statements with empty bodies.

Convert 'object' to 'data object'

Reports object that can be converted to data object.

Convert Pair constructor to 'to' function

Reports a Pair constructor invocation that can be replaced with a to() infix function call.

Convert equality check with 'NaN' to 'isNaN' call

Reports an equality check with Float.NaN or Double.NaN that should be replaced with an isNaN() check.

Convert to primary constructor

Reports a secondary constructor that can be replaced with a more concise primary constructor.

Convert try / finally to use() call

Reports a try-finally block with resource.close() in finally which can be converted to a resource.use() call.

Delegating to 'var' property

Reports interface delegation to a var property.

Deprecated 'Enum.declaringClass' property

Reports 'declaringClass' property calls on Enum that will lead to compilation error since 1.9.

Diagnostic name should be replaced

Reports suppressions with old diagnostic names, for example @Suppress("HEADER_WITHOUT_IMPLEMENTATION").

Do not propagate method deprecation through overrides since 1.9

Reports a declarations that are propagated by @Deprecated annotation that will lead to compilation error since 1.9.

Enum entry naming convention

Reports enum entry names that do not follow the recommended naming conventions.

Equality check can be used instead of elvis for nullable boolean check

Reports cases when an equality check should be used instead of the elvis operator.

Existing backing field without assignment

Reports property setters that don't update the backing field.

Experimental coroutines usages are deprecated since 1.3

Reports code that uses experimental coroutines.

Explicit 'get' or 'set' call

Reports explicit calls to get or set functions which can be replaced by an indexing operator [].

Explicit conversion from `Int` needed since 1.9

Reports expressions that will be of type Int, thus causing compilation errors in Kotlin 1.9 and later.

Expression body syntax is preferable here

Reports return expressions (one-liners or when) that can be replaced with expression body syntax.

Extension property conflicting with synthetic one

Reports extension properties that conflict with synthetic ones that have been automatically produced from Java get or set methods.

External interface contains non-nullable boolean property

Reports non-nullable boolean properties in external interface.

External interface contains val property

Reports not var properties in external interface.

Floating-point literal exceeds the available precision

Reports floating-point literals that cannot be represented with the required precision using IEEE 754 Float and Double types.

Forbidden constructor call

Reports a constructor calls on functional supertypes that will lead to compilation error since 1.9.

Forbidden in suspend context method usage

Reports inappropriate usages of methods in Kotlin coroutines, which uses threading context (annotated with @RequiresBlockingContext).

Fully qualified name can be replaced with existing import alias

Reports fully qualified names that can be replaced with an existing import alias.

Function or property has platform type

Reports functions and properties that have a platform type.

Function should have 'operator' modifier

Reports a function that matches one of the operator conventions but lacks the operator keyword.

Function with '= { ... }' and inferred return type

Reports functions with = { ..

Generate implementation

Reports absent of implementation for the entity.

Guard clause can be replaced with Kotlin's function call

Reports guard clauses that can be replaced with a function call.

If-Null return/break/... foldable to '?:'

Reports an if expression that checks variable being null or not right after initializing it that can be converted into an elvis operator in the initializer.

If-Then foldable to '?.'

Reports if-then expressions that can be folded into safe-access (?.) expressions.

If-Then foldable to '?:'

Reports if-then expressions that can be folded into elvis (?:) expressions.

Implicit 'Nothing?' type

Reports variables and functions with the implicit Nothing? type.

Implicit 'this'

Reports usages of implicit this.

Implicit (unsafe) cast from dynamic type

Reports expressions with a dynamic type in the specified inspection scope that are implicitly cast to another type.

Incomplete destructuring declaration

Reports incomplete destructuring declaration.

Inconsistent comment for Java parameter

Reports inconsistent parameter names for Java method calls specified in a comment block.

Infix call may be dot call

Reports for infix function calls that can be replaced with dot-qualified function calls.

Inline classes are deprecated since 1.5

Reports inline classes that are deprecated and cause compilation warnings in Kotlin 1.5 and later.

Iterated elements are not used in forEach

Reports forEach loops that do not use iterable values.

Java Collections static method call can be replaced with Kotlin stdlib

Reports a Java Collections static method call that can be replaced with Kotlin stdlib.

Java Map.forEach method call should be replaced with Kotlin's forEach

Reports a Java Map.forEach method call that can be replaced with Kotlin's forEach.

Java methods should be replaced with Kotlin analog

Reports a Java method call that can be replaced with a Kotlin function, for example, System.out.println().

Join declaration and assignment

Reports property declarations that can be joined with the following assignment.

Kotlin object registered as extension

Reports Kotlin objects that are registered as plugin extensions.

Kotlin sanity

Reports unresolved references in Kotlin code.

Lambda argument inside parentheses

Reports lambda expressions in parentheses which can be moved outside.

Leaking 'this' in constructor

Reports unsafe operations with this during object construction including: Accessing a non-final property during class initialization: from a constructor or property initialization Calling a non-final function during class initialization Using this as a function argument in a constructor of a non-final class If other classes inherit from the given class, they may not be fully initialized at the moment when an unsafe operation is carried out.

Library function call could be simplified

Reports library function calls which could be replaced by simplified one.

Local 'var' is never modified and can be declared as 'val'

Reports local variables declared with the var keyword that are never modified.

Local variable with type parameters

Reports local variables with type parameters.

Loop can be replaced with stdlib operations

Reports for loops that can be replaced with a sequence of stdlib operations (like map, filter, and so on).

MIN_VALUE step in fromClosedRange() since 1.3

Reports IntProgression.fromClosedRange() and LongProgression.fromClosedRange() with MIN_VALUE step.

Main function should return 'Unit'

Reports when a main function does not have a return type of Unit.

Main parameter is not necessary

Reports main function with an unused single parameter.

Manually incremented index variable can be replaced with use of 'withIndex()'

Reports for loops with a manually incremented index variable.

Meaningless annotations targets on superclass

Reports meaningless annotation targets on superclasses since Kotlin 1.4.

Might be 'const'

Reports top-level val properties in objects that might be declared as const for better performance and Java interoperability.

Missing KDoc comments for public declarations

Reports public declarations that do not have KDoc comments.

Negated boolean expression can be simplified

Reports negated boolean expressions that can be simplified.

Negated call can be simplified

Reports negation isEmpty() and isNotEmpty() for collections and String, or isBlank() and isNotBlank() for String.

Nested lambda has shadowed implicit parameter

Reports nested lambdas with shadowed implicit parameters.

Non-canonical modifier order

Reports modifiers that do not follow the order recommended by the style guide.

Non-exhaustive 'when' statements will be prohibited since 1.7

Reports a non-exhaustive when statements that will lead to compilation error since 1.7.

Non-external classifier extending State or Props

Reports non-external classifier extending State or Props.

Non-idiomatic 'is' type check for an object

Reports non-idiomatic is type checks for an object.

Not-null assertion can be replaced with 'return'

Reports not-null assertion (!!) calls that can be replaced with the elvis operator and return (?: return).

Null-checks can be replaced with safe-calls

Reports chained null-checks that can be replaced with safe-calls.

Object literal can be converted to lambda

Reports anonymous object literals implementing a Java interface with a single abstract method that can be converted into a call with a lambda expression.

Object private property naming convention

Reports properties that do not follow the naming conventions.

Object property naming convention

Reports properties that do not follow the naming conventions.

Obsolete version of entity implementation

Reports existence of the obsolete implementation for the entity.

Obvious explicit type

Reports local variables' explicitly given types which are obvious and thus redundant, like val f: Foo = Foo().

OpenAPI documentation for current module is missing

Reports that there is no OpenAPI documentation for the current Ktor module.

Optionally expected annotation has no actual annotation

Reports optionally expected annotations without actual annotation in some platform modules.

Package name does not match containing directory

Reports package directives that do not match the location of the file.

Private data class constructor is exposed via the 'copy' method

Reports the private primary constructor in data classes.

Private property naming convention

Reports private property names that do not follow the recommended naming conventions.

Progression resolution change since 1.9

Reports overloaded function calls where an argument requires an explicit cast to resolve to a proper declaration.

Property is explicitly assigned to constructor parameter

Reports properties that are explicitly assigned to primary constructor parameters.

Property naming convention

Reports property names that do not follow the recommended naming conventions.

Public API declaration with implicit return type

Reports public and protected functions and properties that have an implicit return type.

Range can be converted to indices or iteration

Reports until and rangeTo operators that can be replaced with Collection.indices or iteration over collection inside for loop.

Range with start greater than endInclusive is empty

Reports ranges that are empty because the start value is greater than the endInclusive value.

Recursive equals call

Reports recursive equals(==) calls.

Recursive property accessor

Reports recursive property accessor calls which can end up with a StackOverflowError.

Redundant '?: return null'

Reports redundant ?: return null.

Redundant 'Companion' reference

Reports redundant Companion reference.

Redundant 'Unit'

Reports redundant Unit expressions.

Redundant 'Unit' return type

Reports a redundant Unit return type which can be omitted.

Redundant 'asSequence' call

Reports redundant asSequence() call that can never have a positive performance effect.

Redundant 'constructor' keyword

Reports a redundant 'constructor' keyword on primary constructors.

Redundant 'else' in 'if'

Reports redundant else in if with return.

Redundant 'inner' modifier

Reports the inner modifier on a class as redundant if it doesn't reference members of its outer class.

Redundant 'requireNotNull' or 'checkNotNull' call

Reports redundant requireNotNull or checkNotNull call on non-nullable expressions.

Redundant 'return' label

Reports redundant return labels outside of lambda expressions.

Redundant 'runCatching' call

Reports runCatching calls that are immediately followed by getOrThrow.

Redundant 'suspend' modifier

Reports suspend modifier as redundant if no other suspending functions are called inside.

Redundant 'with' call

Reports redundant with function calls that don't access anything from the receiver.

Redundant SAM constructor

Reports SAM (Single Abstract Method) constructor usages which can be replaced with lambdas.

Redundant argument-based 'let' call

Reports a redundant argument-based let call.

Redundant backticks

Reports redundant backticks in references.

Redundant call of conversion method

Reports redundant calls to conversion methods (for example, toString() on a String or toDouble() on a Double).

Redundant call to 'toString()' in string template

Reports calls to toString() in string templates that can be safely removed.

Redundant constructor body

Reports empty bodies of secondary constructors.

Redundant creation of lambda or anonymous function

Reports lambdas or anonymous functions that are created and used immediately.

Redundant curly braces in string template

Reports usages of curly braces in string templates around simple identifiers.

Redundant diagnostic suppression

Reports usages of @Suppress annotations that can be safely removed because the compiler diagnostic they affect is no longer applicable in this context.

Redundant double negation

Reports redundant double negations.

Redundant empty initializer block

Reports redundant empty initializer blocks.

Redundant empty primary constructor

Reports empty primary constructors when they are implicitly available anyway.

Redundant enum constructor invocation

Reports redundant constructor invocation on an enum entry.

Redundant explicit 'this'

Reports an explicit this when it can be omitted.

Redundant label

Reports redundant labels which cause compilation errors since Kotlin 1.4.

Redundant labeled return on the last expression in a lambda

Reports labeled returns used on the last expressions in lambdas.

Redundant lambda arrow

Reports redundant lambda arrows in lambdas without parameters.

Redundant modality modifier

Reports the modality modifiers that match the default modality of an element (final for most elements, open for members with an override).

Redundant nullable return type

Reports functions and variables with nullable return type which never return or become null.

Redundant overriding method

Reports redundant overriding declarations.

Redundant property getter

Reports redundant property getters.

Redundant property setter

Reports redundant property setters.

Redundant qualifier name

Reports redundant qualifiers (or their parts) on class names, functions, and properties.

Redundant receiver-based 'let' call

Reports redundant receiver-based let calls.

Redundant setter parameter type

Reports explicitly specified parameter types in property setters.

Redundant spread operator

Reports the use of a redundant spread operator for a family of arrayOf function calls.

Redundant string template

Reports single-expression string templates that can be safely removed.

Redundant value argument

Reports arguments that are equal to the default values of the corresponding parameters.

Redundant visibility modifier

Reports visibility modifiers that match the default visibility of an element (public for most elements, protected for members that override a protected member).

Remove unnecessary parentheses

Reports redundant empty parentheses in annotation entries.

Repeated annotation which is not marked as '@Repeatable'

Reports the repeated use of a non-@Repeatable annotation on property accessors.

Replace 'mapIndexed' with List generator

Reports a mapIndexed call that can be replaced by List generator.

Replace 'until' with '..<' operator

Reports until that can be replaced with ..< operator.

Replace empty class body

Reports declarations of classes and objects with an empty body.

Return or assignment can be lifted out

Reports if, when, and try statements that can be converted to expressions by lifting the return statement or an assignment out.

RunBlocking in coroutine

Reports runBlocking builders that can be reached from coroutines.

Safe cast with 'return' should be replaced with 'if' type check

Reports safe cast with return that can be replaced with if type check.

Scope function can be converted to another one

Reports scope functions (let, run, apply, also) that can be converted between each other.

Scope function with nested forEach can be simplified

Reports forEach functions in the scope functions such as also or apply that can be simplified.

Sealed subclass without state and overridden equals

Reports direct inheritors of sealed classes that have no state and overridden equals() method.

Serializable object must implement 'readResolve'

Reports objects (data object including) that implement java.io.Serializable but don't implement readResolve.

Should be replaced with 'equals(..., ignoreCase = true)'

Reports case-insensitive comparisons that can be replaced with equals(..., ignoreCase = true).

Simplifiable 'when'

Reports when expressions with the constant true or false branches.

Size check can be replaced with 'isNotEmpty()'

Reports size checks of Collections/Array/String that should be replaced with isNotEmpty().

Size zero check can be replaced with 'isEmpty()'

Reports size == 0 checks on Collections/Array/String that should be replaced with isEmpty().

String concatenation that can be converted to string template

Reports string concatenation that can be converted to a string template.

Suspicious 'asDynamic' member invocation

Reports usages of asDynamic function on a receiver of dynamic type.

Suspicious 'var' property: its setter does not influence its getter result

Reports var properties with default setter and getter that do not reference backing field.

Suspicious callable reference used as lambda result

Reports lambda expressions with one callable reference.

Suspicious combination of == and ===

Reports == and === comparisons that are both used on the same variable within a single expression.

Target label does not denote a function since 1.4

Reports labels that don't points to a functions.

Test function naming convention

Reports test function names that do not follow the recommended naming conventions.

Throwable not thrown

Reports instantiations of Throwable or its subclasses, when the created Throwable is never actually thrown.

Trailing comma recommendations

Reports trailing commas that do not follow the recommended style guide.

Two comparisons should be converted to a range check

Reports two consecutive comparisons that can be converted to a range check.

Type parameter can have 'in' or 'out' variance

Reports type parameters that can have in or out variance.

Unlabeled return inside lambda

Reports unlabeled return expressions inside inline lambda.

Unnecessary '@OptIn' annotation

Reports unnecessary opt-in annotations that can be safely removed.

Unnecessary parentheses in function call with lambda

Reports redundant empty parentheses of function calls where the only parameter is a lambda that's outside the parentheses.

Unnecessary supertype qualification

Reports super member calls with redundant supertype qualification.

Unnecessary type argument

Reports function calls with type arguments that can be automatically inferred.

Unresolved reference in KDoc

Reports unresolved references in KDoc comments.

Unsupported 'var' field in entity

Detects unsupported var fields in the inheritors of WorkspaceEntity interface Interface implementing WorkspaceEntity have to have only val fields because it's immutable.

Unused 'args' on 'main' since 1.4

Reports main function with an unused single parameter.

Unused equals expression

Reports unused equals(==) expressions.

Unused import directive

Reports redundant import statements.

Unused loop index

Reports for loops iterating over a collection using the withIndex() function and not using the index variable.

Unused receiver parameter

Reports receiver parameter of extension functions and properties that is not used.

Unused result of data class copy

Reports calls to data class copy function without using its result.

Unused return value of a function with lambda expression body

Reports calls with an unused return value when the called function returns a lambda from an expression body.

Unused symbol

Reports symbols that are not used or not reachable from entry points.

Unused unary operator

Reports unary operators for number types on unused expressions.

Usage of redundant or deprecated syntax or deprecated symbols

Reports obsolete language features and unnecessarily verbose code constructs during the code cleanup operation (Code | Code Cleanup).

Use 'com.intellij.util.io.ProcessKt.awaitExit()'

Reports usages of Process.waitFor() and Process.onExit() in coroutine context.

Use destructuring declaration

Reports declarations that can be destructured.

Useless call on collection type

Reports filter… calls from the standard library on already filtered collections.

Useless call on not-null type

Reports calls on not-null receiver that make sense only for nullable receiver.

Variable declaration could be moved inside 'when'

Reports variable declarations that can be moved inside a when expression.

Variable in destructuring declaration uses name of a wrong data class property

Reports entries of destructuring declarations that match the name of a different property of the destructured data class.

Verbose nullability and emptiness check

Reports combination of null and emptiness checks that can be simplified into a single check.

Less

Name

Description

Missing import

Reports a reference to a variable or mixin that is declared in another file, which is not explicitly imported in the current file.

Unresolved mixin

Reports a reference to a Less mixin that is not resolved.

Unresolved variable

Reports a reference to a Less variable that is not resolved.

Makefile

Name

Description

Unresolved prerequisite

Reports unresolved target prerequisites.

Manifest

Name

Description

Missing final new line

Reports if manifest files do not end with a final newline as required by the JAR file specification.

Unknown or misspelled header name

Reports any unknown and probably misspelled header names and provides possible variants.

Markdown

Name

Description

Element id occurs more than once in Markdown file

Detects duplicate element identifiers in Markdown Writerside topics.

Incorrect table formatting

Checks if table is correctly formatted.

Incorrectly numbered list item

Ordered list items are expected to have straight numeration starting from 1.

Links should not contain spaces

To ensure consistency between different tools, file links should not contain spaces.

Outdated table of contents section

Checks if a particular table of contents section corresponds to the actual structure of the document.

Table doesn't have side borders

Checks if table has correct side borders.

Top-level header is implicitly converted to a chapter

Detects top-level headers in Writerside Markdown topics that will be converted to chapter headers in the generated documentation.

Unresolved anchor reference

Reports unresolved references in Markdown links.

Unresolved file references

Reports unresolved file references in Markdown files.

Unresolved header reference

Reports unresolved header references in Markdown files.

Unresolved link label

Reports unresolved link labels in Markdown files.

Micronautel

Name

Description

Incorrect Micronaut Expression Language (MicronautEl) syntax

Reports syntax errors in the Micronaut Expression Language (MicronautEL) code, such as unresolved references.

Mongojs

Name

Description

Statement with side effects

Reports statements that can cause side effects while the data source is in read-only mode.

Mongojsext

Name

Description

Deprecated element

Reports usages of deprecated methods in MongoDB and JavaScript code.

Resolution problems

Reports unresolved references in MongoDB and JavaScript code.

Msbuild

Name

Description

TargetFramework tag checks

RIDER-83136.

Multiple

Name

Description

Annotator

Reports issues essential to this file (e.g., syntax errors) in the result of a batch code inspection run.

Argument selection defect

Reports mismatches between the argument identifier name and the formal parameter name.

Array Index Out Of Bounds

Reports array or pointer variable access expressions where index may be out of bounds of an array or allocated buffer.

Check dependency licenses

Check dependencies licenses for possible problems: missing or prohibited licenses, or other compliance issues.

Check module licenses

Check module licenses for possible problems: missing licenses or other compliance issues.

Check third party software list

Check project for possible problems: user's third party software list does not match the collected project metadata.

Clang-Tidy

Reports various issues related to The C++ Core Guidelines, Modernize, Readability and Performance.

Clangd errors and warnings

Reports C/C++ errors and warnings from clangd.

Clazy

Reports the Qt-related compiler warnings, ranging from unneeded memory allocations to the misused API.

Code metrics

Calculates cyclomatic complexity.

Constant Function Result

Reports the functions where the return value is always the same constant.

Constant Parameter

Reports function parameters that always have the same value.

Context-sensitive analysis

Reports the issues found by the context-sensitive data flow analyser.

Custom RegExp inspection

Custom Regex Inspection.

Dangling Pointer

Reports the usages of the pointers that refer to the memory already deleted by the delete operator or the free(void* ptr) function.

Duplicated code fragment

Reports duplicated blocks of code from the selected scope: the same file or the entire project.

Empty declaration or statement

Reports empty declarations and statements that can be removed safely.

Empty directory

Reports empty directories.

Endless Loop

Reports the for, while, do while, and goto statements that exit only by throwing an exception.

File encoding doesn't match EditorConfig charset

Checks that current file encoding matches the encoding defined in "charset" property of .editorconfig file.

File watcher problems

Reports an error detected by the output filters from a File Watcher.

Grammar

Reports grammar mistakes in your text.

Hardcoded passwords

Detects potential security tokens or passwords in comments using entropy analysis and regular expressions.

Hiding non-virtual function

Reports the functions that hide non-virtual functions with the same signature declared in the base class.

Inaccessible component member or directive input

Reports access to invisible (private or protected) component member or directive input from an Angular template.

Inconsistent Naming

Reports the names that don't match the naming convention for that kind of symbol.

Inconsistent language level settings

Reports modules which depend on other modules with a higher language level.

Inconsistent line separators

Reports files with line separators different from the ones that are specified in the project's settings.

Incorrect formatting

Reports formatting issues that appear if your code doesn't follow your project's code style settings.

Infinite Recursion

Reports methods and functions with infinite recursion.

Injected references

Reports unresolved references injected by Language Injections.

Line is longer than allowed by code style

Reports lines that are longer than the Hard wrap at parameter specified in Settings | Editor | Code Style | General.

Link with unencrypted protocol

Reports the links that use unencrypted protocols (such as HTTP), which can expose your data to man-in-the-middle attacks.

Local Value Escapes Scope

Reports the references to local values that escape the function Example: int *escapeLocalScope() { int lv = 100; return &lv; }.

Loop condition isn't updated inside the loop

Reports the loop conditions that are not updated inside the loop.

Lossy encoding

Reports characters that cannot be displayed because of the current document encoding.

MISRA

Reports various issues defined by the MISRA C 2012, MISRA C++ 2008 and MISRA C++ 2023 guidelines.

Malicious dependency

Reports malicious NPM and PyPI dependencies declared in your project.

Memory Leak

Reports the allocations of memory (either new operator or malloc() function) that were not released before they become non-accessible.

Missing Rbenv gemset

Reports gemsets in '.rbenv-gemsets' that can't be found in the project SDK, and local gemsets that can't be found in the project root.

Missing features

Detects Cargo packages with missing cargo features in some of their dependency packages.

Missing or invalid selector

Reports an invalid selector property of a component or directive.

Natural language detection

Detects natural languages and suggests enabling corresponding grammar and spelling checks.

Non-ASCII characters

Reports code elements that use non-ASCII symbols in an unusual context.

Not Implemented Functions

Reports the functions that were declared in a class but have no implementations.

Not Initialized Field

Reports the fields that may have not been initialized before their usage.

Null Dereference

Reports dereferences of the pointers that may contain nullptr.

PHP_CodeSniffer validation

Reports coding style problems detected by PHP_CodeSniffer.

Possible template file

Detects Terraform Template files without the standard extension (*.tftpl) that do not have an associated data language and suggests choosing one from the list of possible candidates.

Preprocessor directive comment

Reports the mismatches between the preprocessor #endif comments and macro names.

Problematic whitespace

Reports the following problems: Tabs used for indentation when the code style is configured to use only spaces.

Project is not installed for development

Reports cases when no python setup.py develop command was executed for the Pyramid project.

Reassigned to plain text

Reports files that were explicitly re-assigned to Plain Text File Type.

Redundant suppression

Reports usages of the following elements that can be safely removed because the inspection they affect is no longer applicable in this context: @SuppressWarning annotation, or // noinspection line comment, or /** noinspection */ JavaDoc comment Example: public class C { // symbol is already private, // but annotation is still around @SuppressWarnings({"WeakerAccess"}) private boolean CONST = true; void f() { CONST = false; } }.

Simplifiable statement

Reports the statements that can be simplified, such as constant conditions, identical if branches, redundant boolean expressions, and others.

Structural search inspection

Allows configuring Structural Search/Structural Replace templates that you can apply to the file you are editing.

TODO comment

Reports TODO comments in your code.

Typo

Reports typos and misspellings in your code, comments, and literals and fixes them with one click.

Unconstrained variable type

Reports cases where an expression constrained by a concept is assigned to a variable declared as auto and suggests adding a type constraint.

Unhandled Exception in JSP

Reports exceptions that are thrown by top-level JSP scriptlets.

Unnecessary module dependency

Reports dependencies on modules that are not used.

Unreachable Calls Of Function

Reports the functions which calls are never used.

Unreachable Code

Reports the code pieces that are never executed in any control flow and can be removed safely.

Unsatisfied package requirements

Reports packages mentioned in requirements files (for example, requirements.txt or Pipfile) but not installed, or imported but not mentioned in requirements files.

Unused Class

Reports Objective-C classes and protocols that are never used.

Unused Concept

Reports the concepts that are never used and can be removed safely.

Unused Global Declaration

Reports the global function and variable declarations that are never used and can be removed safely.

Unused Include Directive

Reports the include directives that are not used or not required and can be removed safely.

Unused Instance Variable

Reports the instance variables that are never accessed or written.

Unused Local Variable

Reports the local variables that are declared but never accessed for reading.

Unused Macro

Reports the macro definitions that are never used and can be removed safely.

Unused Method

Reports the methods that are never called, for example, in send message expressions, @selector expressions, and other places like XIB files.

Unused Parameter

Reports the parameters that are declared but never accessed for reading and can be removed safely.

Unused Property

Reports the properties that are never accessed or written, neither in qualified expressions nor in accessor method calls.

Unused Struct

Reports the classes and structures that are never used and can be removed safely.

Unused Template Parameter

Reports the template parameters that are never used and can be removed safely.

Unused Type Alias

Reports the statements that are never used and can be removed safely.

Unused Value

Reports the variable values that are never used after being assigned.

Unused define

Reports an unused named pattern (define) in a RELAX-NG file (XML or Compact Syntax).

Unused library

Reports libraries attached to the specified inspection scope that are not used directly in code.

Virtual call from constructor or destructor

Reports virtual member function calls from constructors or destructors.

Vulnerable declared dependency

Reports vulnerabilities in Gradle, Maven, NPM and PyPI dependencies declared in your project.

Vulnerable imported dependency

Reports vulnerabilities in Gradle and Maven dependencies imported into your project.

Mysql

Name

Description

Whitespace between the function name and the open parenthesis

Reports any whitespace in a function call between the function name and the open parenthesis, which is not supported by default.

Mysql based

Name

Description

LOAD statement path

Reports paths that start with the tilde character in LOAD statements.

Unsupported syntax in pre-8.0 versions

Reports invalid usages of UNION in queries.

Objectivec

Name

Description

Interprocedural analysis

Interprocedural summary-based static code analysis.

Oracle

Name

Description

Forward declaration without definition

Reports declarations of procedures and functions that are missing their implementation in code.

Missing body for package/object type specification

Reports package and object type specifications that are missing body declarations.

Overloading errors

Reports invalid cases of subprogram overloading in Oracle.

PHP

Name

Description

'#[ArrayShape]' attribute can be added

Reports the methods and functions that are returning arrays with known non-trivial keys.

'#[Pure]' attribute can be added

Reports the functions that are non-trivially pure.

'Closure::fromCallable()' can be converted to the first-class callable syntax

Reports the callable creation expressions that use Closure::fromCallable but can be replaced with first-class callable syntax f(...) available since PHP 8.1.

'__toString' may throw an exception

Reports the usages of __toString that may throw an exception, which is not allowed for PHP language level lower than 7.4.

'array_all()' call can be converted to a loop

Reports the array_all() calls that can be replaced with foreach loops in PHP 8.4 and later.

'array_any()' call can be converted to a loop

Reports the array_any() calls that can be replaced with foreach loops in PHP 8.4 and later.

'array_fill' can be converted to loop

Reports the array_fill() calls that can be replaced with foreach loops.

'array_filter()' call can be converted to loop

Reports the array_filter() calls that can be replaced with foreach loops.

'array_find()' call can be converted to a loop

Reports the array_find() calls that can be replaced with foreach loops in PHP 8.4 and later.

'array_find_key()' call can be converted to a loop

Reports the array_find_key() calls that can be replaced with foreach loops in PHP 8.4 and later.

'array_map()' call can be converted to loop

Reports the array_map() calls that can be replaced with foreach loops.

'array_push()' with single element

Reports the array_push() calls that are used to add a single element to an array.

'array_search()' can be replaced with 'in_array()' call

Reports the array_search() calls that are only used for checking whether an element exists in array, that is, the expressions like if (array_search($a, $b) === false) {}.

'assertTrue()' with incompatible argument type

Reports the PHPUnit assertTrue() calls whose arguments are of incompatible types.

'continue' is targeting 'switch' statement

Reports the continue statements that are targeting switch statements.

'final' modifier is redundant, property with private 'set' visibility is implicitly final

Reports a redundant final modifier used for the private(set) property.

'foreach' variable overwrites already defined variable

Reports the keys and values in foreach loops that are assigned a non-primitive value before the foreach loop and are accessed after it.

'func_get_arg()' call can be replaced with parameter access

Reports the func_get_arg() calls that can be replaced with direct parameter access.

'get_class()' call can be replaced with '::class'

Reports the get_class() calls and suggests replacing them with ::class when PHP Language level is set to 8.0 or later.

'if' can be merged with subsequent condition

Reports the if statements that are followed by elseif or other if statements having the same bodies.

'if' can be replaced with 'match' expression

Reports the if statements inside if-elseif-else constructs that use strict comparisons (===) and could be replaced with match expressions.

'if' with common parts

Reports the if statements with duplicated common parts.

'in_array' can be replaced with comparison

Reports the in_array() calls that are provided with a single-element array as the $haystack argument.

'instanceof' checks in 'catch' block can be replaced with specific catches

Reports the instanceof checks in single catch blocks that could be replaced with multiple catch blocks specific for each exception instance.

'isset' can be replaced with coalesce

Reports the conditions using isset that can be safely replaced with expressions using the ?? null coalesce operator.

'isset' can check nested array access and sub properties directly

Reports constructions like isset($a['a']) && isset($a['a']['b']) && isset($b) && isset($b->b) that can be replaced with isset($a['a']['b']) && isset($b->b).

'json_decode()' and 'json_last_error()' can be converted to 'json_validate()'

In PHP 8.3 and later, suggests converting `json_decode()` and `json_last_error() === JSON_ERROR_NONE` to `json_validate()`.

'match' can be replaced with 'switch' statement

Reports the match expressions that can be replaced with switch statements.

'match' expression can be replace with ternary expression

Reports the match expressions containing a default arm and a single non-default arm.

'match' expression has only default arm and should be simplified

Reports the match expressions only containing a default arm.

'mixed' return type can be narrowed

Reports 'mixed' return types that can be narrowed down to more concrete types.

'mixed' type can be replaced with 'array'

Reports the mixed[] usages in PHPDoc blocks that can be safely replaced with array.

'n' modifier can be replaced with non-capturing groups

Reports the n PCRE modifier that can be replaced with non-capturing groups in RegExp patterns.

'never'-typed function returns a value

Reports the functions with the never return type hint that may return some value.

'null' is not compatible with parameter's declared type

Reports the variables that are initialised via passing them by reference to a parameter incompatible with null.

'pow()' call can be replaced with '**' operator

Reports the pow() calls that can be replaced with the ** operator, which adds no overhead of calling a function.

'preg_match' can be replaced with 'str_contains'

Reports the preg_match() calls with pattern arguments that don't use any regexp facilities.

'preg_match()' can be replaced with comparison

Reports the preg_match() calls that are provided with a string argument starting with ^ (Start of String anchor) and ending with $ (End of String anchor).

'preg_replace()' can be replaced with '(l|r)trim' call

Reports the preg_replace() calls with empty replacement.

'preg_split' can be replaced with 'explode'

Reports preg_split() calls that can be replaced with explode().

'readonly' modifier is redundant

Reports readonly modifiers applied to properties in read-only classes.

'set' visibility can be removed

Reports a set visibility that equals property visibility and can therefore be omitted.

'str*()' calls can be replaced with PHP 8 'str_*()' calls

Reports the strpos and substr functions calls that can be replaced with the str_* functions calls (introduced in PHP 8.0).

'switch' can be replaced with 'match' expression

Reports 'switch' statements that could be replaced with 'match' expression.

'switch' with common parts

Reports the 'switch' statements with duplicated common parts.

'switch' with single 'case'

Reports the switch statements that only contain a single case statement.

'var_export' or 'print_r' call is used without 'return' argument

Reports var_export() and print_r() calls without the return argument when their results are explicitly used.

Accessing static trait members

Reports the static member access expressions used on traits.

Argument of 'instanceof' should be only objects or strings

Reports arguments of 'instanceof' that are not objects or strings.

Argument with name identifier

Reports arguments with name identifiers.

Argument without name identifier

Reports arguments without name identifiers.

Arithmetic operation with unsupported operands

Reports arithmetic and bitwise expressions with unsupported operands.

Array access can be replaced with 'foreach' value

Reports the array access expressions inside foreach loops that can be replaced with a foreach value.

Array index is immediately rewritten

Reports the write expressions on array indexes which are immediately overwritten before being accessed.

Array internal pointer reset is unnecessary

Reports the reset($array) calls on arrays whose internal pointer is already set on the first element.

Array is always empty at the point of access

Reports the iterated/accessed arrays that are known to be empty at the point of access.

Array key does not match array shape

Reports the array keys that do not match the keys specified via the #[ArrayShape] attribute.

Array offset access on illegal type

Reports the array offset access expressions that are used on illegal types.

Array to string conversion

Reports array to string conversions, that is, the arrays that are provided in the contexts where a string is expected.

Array used only with write access

Reports local arrays that are only updated, but never queried.

Array write access is not used

Reports the array write access expressions that are not used in code afterwards.

Assertion can be replaced with 'assertEmpty/assertNotEmpty'

Reports the assertTrue/assertFalse usages that can be replaced with assertEmpty/assertNotEmpty in PHPUnit tests.

Assertion can be replaced with 'assertTrue/assertFalse'

Reports the assertEquals() calls with the true/false arguments in PHPUnit tests.

Assertion can be replaced with 'fail'

Reports the assertTrue()/assertFalse() calls with the false/true arguments in PHPUnit tests.

Assertion can be simplified

Reports assertion call to be replaced with more specific analogue.

Assignment can be replaced with increment or decrement

Reports the assignments that can be replaced with incrementing (++) or decrementing (--) operations.

Assignment can be replaced with operator assignment

Reports the assignments that can be replaced with combined operator assignments (for example, +=).

Assignment in condition

Reports the assignments that are used in conditional expressions.

Attribute can be added to overriding member

Reports the methods' and parameters' attributes that can be propagated to overriding methods/parameters.

Automatic conversion of 'false' to array is deprecated

Reports automatic conversions of false values to arrays.

Backed property with a 'set' hook cannot be accessed by reference

Reports an attempted indirect modification of a hooked property.

Behat doc step can be converted to attribute version

Reports Behat doc tags that can be replaced with attribute version.

Cannot infer DQL model class to enable completion

Reports $entityManager->createQueryBuilder()->from($model, $expr) when PhpStorm cannot resolve $model to a class.

Cannot modify property outside of 'set' visibility scope

Reports a write access attempt to private(set) or protected(set) properties that are made outside of their set visibility scope.

Cannot write to a virtual property without a setter defined

Reports partial or missing property hook components, i.e., insufficiently defined virtual properties.

Case mismatch in method call or class usage

Reports the usages of functions, methods, classes, and namespaces that do not match the case used in their declarations.

Case with specified value not found in enum

Reports the arguments of enum's from method calls that are not found in target enum classes.

Check the PHP source code coverage

Reports methods, classes and files whose coverage is below a certain threshold.

Class can be 'readonly'

Reports the classes which contain only readonly properties and can have the readonly modifier added to them.

Class can't implement Traversable directly

Reports the classes that are implementing the Traversable interface alone, not as part of Iterator or IteratorAggregate interfaces.

Class cannot be used as attribute

Reports the attributes that are resolved to a class not annotated with #[Attribute].

Class constant can be 'final'

Reports the non-final class constants that are not redefined in child classes.

Class constant referenced via child class

Reports reference to a class constant via child class which gets this constant from the parent class by inheritance and does not override it within its own scope.

Class constant type is missing

In PHP 8.3 and later, reports a class constant that is missing a type declaration.

Class has too many declared members

Reports the classes that have too many properties or methods.

Class hierarchy checks

Checks the class hierarchy: abstract methods implementation, compatibility of implementing/overriding methods with their declarations in parent classes, and property types redeclarations.

Class name is not following coding convention

Reports the classes' names that are either too short, too long, or do not follow the specified regular expression pattern.

Class path doesn't match project structure

Reports the classes with the filepath not following the PSR-0/PSR-4 project structure.

Class static member accessed via instance

Reports references to static methods and fields via a class instance rather than the class itself.

Closure can be converted to arrow function

Reports the anonymous functions and property hooks that can be transformed to short arrow functions.

Comment can be replaced with named argument

Reports the inline comments before arguments in function calls that only contain the name of the parameter and thus serve as hints.

Comment is parsed as attribute in PHP 8.0

Reports line comments starting with #[.

Complex class should be refactored

Reports the classes that are too complex.

Complex function should be refactored

Reports the functions or methods that are too complex.

Compound namespace depth is more than 2

Reports the usages of compound namespaces whose depth exceeds two levels.

Concatenation to empty string can be merged with assignment

Reports the .= concatenation assignments performed right after assignment to an empty string literal.

Concatenation with arithmetic usage

Reports the string concatenation expressions that are used together with +, -, <<, and >> operators.

Condition always evaluates to 'true/false'

Reports the conditions that are already covered by earlier conditions and thus have no effect as well as the variables that are always true (or always false) when reached.

Condition can be replaced with 'min()'/'max()' call

Reports the conditions that perform manual min/max calculation instead of calling min/max functions.

Condition inside logical expression checked by subsequent condition

Reports the conditions inside logical binary expressions that are covered by subsequent conditions and are therefore redundant.

Constant name defined with a leading slash

Reports the define constructs in which the constant's FQN starts with a leading slash.

Constant name is not following coding convention

Reports the constants' names that are either too short, too long, or do not follow the specified regular expression pattern.

Constant reassignment

Reports reassignments of constants.

Control statement body without braces

Reports the control structures (such as loops or conditionals) whose bodies are not enclosed in braces.

Covered function reference is provided without ‘::’

Reports the references to functions/methods in the @covers PHPDoc tags that are not prepended with the scope resolution operator (::).

Curly brace access syntax usage

Reports the usages of curly brace syntax for accessing array elements and string offsets.

Dangerous array initialization

Reports dangerous array initializations (such as $arr[] = value).

Declaration of overridden method should be compatible with parent class

Reports the overridden methods declarations that are not compatible with the parent class.

Define constant name can be replaced with 'const' syntax

Reports the define() calls that can be replaced with const syntax.

Deprecated

Reports the usages of deprecated entities.

Deprecated '${' string interpolation

Reports ${var} and ${expr} interpolations in strings.

Deprecated 'Serializable' interface usage

Reports the usages of deprecated Serializable interface.

Deprecated '__autoload()' function declaration

Reports the __autoload() function declarations.

Deprecated 'assert()' function declaration

Reports the assert() function declarations.

Deprecated 'assertContains/assertNotContains' usage

Reports the deprecated assertContains() and assertNotContains() calls with the string $needle and $ignoreCase arguments.

Deprecated 'assertEquals/assertNotEquals' usage

Reports deprecated usages of the assertEquals and assertNotEquals functions with $delta, $maxDepth, $canonicalize, and $ignoreCase parameters.

Deprecated 'assertFileEquals/assertStringEqualsFile' usage

Reports the deprecated usages of the assertFileEquals, assertFileNotEquals, assertStringEqualsFile, and assertStringNotEqualsFile functions with the $canonicalize and $ignoreCase parameters.

Deprecated 'implode/join' usage

Reports deprecated usage of the implode and join functions.

Deprecated @covers/@uses by access modifier annotation

Reports the @covers and @uses PHPUnit doc tags that are using ClassName::<*>.

Deprecated Standard Library call

Reports the calls to Standard PHP Library functions that are deprecated starting from PHP 8.1.

Deprecated cast

Reports deprecated cast expressions: (unset) cast expressions, which are deprecated in PHP 7.2 and later.

Deprecated exception handling via doc tags

Reports the usages of the following deprecated PHPUnit doc tags: @expectedException @expectedExceptionMessage @expectedExceptionCode @expectedExceptionMessageRegExp.

Deprecated expectException usage

Reports deprecated usages of expectException().

Deprecated partially supported callables

Reports deprecated usage of callables that are supported by call_user_func($callable), but not by $callable().

Deprecated usage of data provider since PHPUnit 10

Reports the references to functions/methods in the @dataProvider PHPDoc tag that are resolved to non-static or non-public methods.

Disabled extension stubs

Reports the usages of classes, functions, and constants, for which the stubs for the corresponding PHP interpreter extensions are disabled.

Doctrine annotation can be replaced with attribute

Suggests replacing Doctrine annotations with attributes.

Duplicate arm in 'match' expression

Reports duplicate bodies in match arms.

Duplicate array keys

Reports duplicate keys in array declarations.

Duplicate branch in 'catch' statement

Reports catch statements with duplicated bodies.

Duplicate branch in switch statement

Reports the switch statements containing the same code in different branches.

Duplicate case in switch statement

Reports duplicate case expressions in switch statements.

Duplicate character in function call

Reports duplicate characters provided in the characters argument of functions like ltrim or str_words_counts.

Duplicate condition

Reports duplicate conditions in match expressions.

Duplicate operand in comparison

Reports duplicate operands in binary expressions (+, -, *, /, &&, ||, and .) that are in turn used inside comparison expressions.

Dynamic method called as static

Reports static calls to dynamic class methods.

Dynamic property declaration

Reports the references to dynamic class properties declarations.

Element is not available in configured PHP version

Reports the usages of entities which were introduced in PHP version later than configured one.

Else if

Reports the usages of the else if constructs specified in two words.

Empty index operator not supported for strings

Reports the usages of empty index operator ([]) on strings.

Enforce PHPDoc comment

Reports the elements without a PHPDoc comment or with a PHPDoc comment only containing the @noinspection tag.

Exception is immediately rethrown

Reports the catch statements that only rethrow a caught exception, which is located in a class hierarchy different from the subsequent exception types.

Expected values should be used

Reports the values in assignment and comparison expressions that should be replaced with one of the expected values (that is, the values specified via the #[ExpectedValues] attribute).

Expression is always 'null'

Reports the variables in return statements that are always null.

Expression result unused

Reports the expressions that are calculated, but the calculation result is not used anywhere.

Expression without clarifying parentheses

Reports potentially ambiguous expressions and proposes enclosing them in clarifying parentheses.

Extension is missing in composer.json

Reports the usages of classes, functions, and constants from the PHP extensions not specified in composer.json.

Field reference does not match object shape

Reports reference to a property whose name does not match the name specified via an #[ObjectShape] attribute or in the PHPDoc comment.

Foreach array is used as value

Reports the variables that are used in a foreach loop as both an array expression and an array's key or value (for example, foreach ($items as $items) {}).

Foreach over array literal with single element

Reports the foreach statements that iterate over an array literal containing a single element.

Format function call with single argument

Reports the sprintf() and vsprintf() calls with a single argument.

Format function parameters mismatch

Reports the arguments of a format function (such as printf or sprintf) that are not mapped to any parameters or specification conversions.

Fully qualified name usage

Reports the fully qualified class names that can be shortened by adding the use statement.

Function call is not compatible with 'callable' declaration

Reports the parameters in function calls whose types are not compatible with the ones defined via Closure.

Function has too high cyclomatic complexity

Reports the methods that have high cyclomatic complexity and can probably be simplified.

Function name is not following coding convention

Reports the functions' names that are either too short, too long, or do not follow the specified regular expression pattern.

Getter and setter can be replaced with get and set property hooks

Reports a private property with getter and/or setter access methods that can be replaced with a public property with get and/or set property hooks.

Goto into loop statement

Reports the goto labels that are located inside loops or switch statements.

Halstead metric

Reports the methods with high Halstead Complexity metric.

Hooked property cannot be unset

Reports an attempt to call the unset() function on a hooked property.

Idempotent operation in binary expression

Reports the binary expression operands that do not change the expression result (such as + 0 or .

Ignored class alias declaration

Reports the class alias declarations that are ignored by the IDE because the actual class declaration with the same FQN exists.

Illegal array key type

Reports the array keys that are of illegal type, such as objects or arrays.

Illegal string offset

Reports the usages of non-integer offsets in string access expressions such as $str[42].

Immutable property written in invalid scope

Highlights write access references to properties, for which the write access scope declared via #[Immutable] is stricter than the reference scope.

Implicit octal literal can be replaced with explicit one

Reports the implicit octal literals such as 071 that could be replaced with explicit ones such as 0o71.

Implicitly marking parameter as nullable is deprecated

Reports deprecated usage of an implicitly nullable parameter type.

Inappropriate @inheritDoc usage

Reports inappropriate @inheritDoc usages: On non-class members On class members without any super members having a doc comment.

Incompatible return type

Reports the return statements whose return value type is not compatible with the one declared for a function/method.

Inconsistent return points

Reports inconsistencies in function/method exit points.

Incorrect magic method signature

Reports incompatible magic methods signatures.

Invalid Mockery mocking target

Reports the methods and classes that are incorrectly mocked in Mockery tests.

Invalid PHPUnit mocking target

Reports the methods and classes that are incorrectly mocked in PHPUnit tests.

Invalid argument supplied for 'foreach()'

Reports the foreach constructs used on variables of the string, float, int, or boolean type.

Invalid delimiter

Reports invalid delimiters in regular expressions in two cases: 1.

Invalid function result used

Reports the usages of a void or never function's return value.

Invalid magic method modifiers

Reports the magic methods that are not declared as public or are declared as static.

Invalid string offset usage

Reports invalid string offset usages that will result in a runtime error.

Invalid type of unpacked argument

Reports unpacked function arguments and array elements whose type is neither array nor Traversable.

LCOM metric

Reports the classes that have high Lack of Cohesion metric value, which represents the degree of cohesiveness of a class.

Language level

Reports the language features used in source code that are not supported for the selected language level.

Laravel Pint validation

Reports the coding style problems detected by Laravel Pint.

Local object is used only for writing properties

Reports the variable assignments to new objects that are used only for writing the object's properties without observable side effects.

Logical expression has same operands

Reports the expressions that use the same operands, but should rather use different operands (for example, $var == $var).

Loop can be converted to 'array_fill()' call

Reports the for loops that can be replaced with array_fill() calls.

Loop can be converted to 'array_filter()' call

Reports the foreach loops that can be replaced with array_filter() calls.

Loop can be converted to 'array_map()' call

Reports the foreach loops that can be replaced with array_map() calls.

Loop can be converted to an 'array_all()' call

Reports the foreach loops that can be replaced with array_all() calls in PHP 8.4 and later.

Loop can be converted to an 'array_any()' call

Reports the foreach loops that can be replaced with array_any() calls in PHP 8.4 and later.

Loop can be converted to an 'array_find()' call

Reports the foreach loops that can be replaced with array_find() calls in PHP 8.4 and later.

Loop can be converted to an 'array_find_key()' call

Reports the foreach loops that can be replaced with array_find_key() calls in PHP 8.4 and later.

Loop can be replaced with 'implode()'

Reports the foreach loops that can be safely replaced with implode() calls.

Loop can be replaced with 'in_array()' or 'array_key_exists()' call

Reports the foreach loops that can be safely replaced with in_array() or array_key_exists() calls.

Loop can be replaced with 'str_repeat'

Reports the for loops that can be safely replaced with str_repeat() calls.

Loop does not iterate

Reports the loop statements whose bodies will execute at most once.

Mark overridden method with #[Override]

Suggests adding the #[Override] attribute to the methods that override same name methods in the parent class or any of the implemented interfaces.

Member can be pulled up

Reports the class methods and properties that should be pulled up to the parent class or interface.

Member reference chain is too long to analyze

Reports method reference chains that are too long for IDE to analyze.

Method '__toString' implementation

Reports the attempts to convert the objects having no __toString method implementation to string.

Method '__toString' return type

Reports the __toString methods that do not return string.

Method 'assertArrayHasKey/assertArrayNotHasKey' can be used instead

Reports the assertTrue() and assertNotTrue() methods calls that are provided with an array_key_exists() call as an argument.

Method declaration in parent class is incompatible with implemented interface

Reports the methods declarations in parent classes that are incompatible with implemented interfaces.

Method does not override the method from its superclass

Reports usage of the #[Override] attribute with a method that doesn't have a parent method to override.

Method has Feature Envy on another class

Reports the "Feature Envy" code smell.

Method is deprecated in PHPUnit 10

Reports the calls to the PHPUnit assertion methods that are removed in PHPUnit 10.

Method is deprecated in PHPUnit 11

Reports calls to the PHPUnit test case methods that are removed in PHPUnit 11.

Method name is not following coding convention

Reports the methods' names that are either too short, too long, or do not follow the specified regular expression pattern.

Method visibility should not be overridden

Checks that the methods don't override visibility.

Method's return value is never used

Reports the private methods returning the values that are not used.

Misordered 'rand' function arguments

Reports the rand($min, $max) family function calls in which the max argument is less than min.

Misordered PHPUnit equality assertion method arguments

Reports the calls to PHPUnit equality assertion methods (such as assertEquals(), assertNotEquals(), assertSame(), and so on) that have a non-literal as the expected result argument and a literal as the actual result argument.

Missing 'break' statement

Reports the case clauses in switch statements that do not end with a break or a return statement.

Missing @copyright/@license tags

Reports the file header DocBlocks that do not contain the @copyright and @license tags required by the Joomla! DocBlocks standard.

Missing @since tag

Reports the class, class property, and class method DocBlocks that do not contain the @since tag required by the Joomla! DocBlocks standard.

Missing @throws tag(s)

Reports missing PHPDoc @throws tags for exceptions thrown by functions or methods.

Missing PHPDoc comment

Reports non-fully typed elements without a PHPDoc comment or with a PHPDoc comment only containing the @noinspection tag.

Missing parameter list

Reports missing parameter lists in a classes' instantiations.

Missing parameter's type declaration

Reports the parameters that have no type declaration specified.

Missing parent call for constructor

Reports the constructors that do not call their parent constructor.

Missing parent call for magic methods

Reports the magic methods that do not call their parent magic method.

Missing parent call for method

Reports the methods that do not call their parent method.

Missing property's type declaration

Reports the properties that have no type declaration.

Missing return type declaration

Reports the functions that have no return type declaration specified.

Missing strict types declaration

Detects the missing declare(strict_types=1) directive in the file.

Missing target element for PHPUnit test

Reports the test classes and methods, for which no corresponding production classes or methods were found.

Missing visibility

Reports the properties, constants, and methods that are declared without visibility definition.

Modification of the array returned from function by value won't have any effect

Reports call to a function that returns array by value, which makes the assignment operation non-working.

Modulo operation with '1' as operand

Reports the modulo expressions % that always evaluate to 0 or 1.

Multiple 'isset' calls can be replaced with one

Reports multiple isset() checks that can be replaced with a single one.

Multiple class declarations

Reports the references to classes that have multiple declarations in project files.

Multiple classes declarations in one file

Reports multiple class declarations in a single file, which violates the PSR-0/PSR-4 standards.

Multiple expectations can be chained together

Reports multiple expectations that can be converted to chainable calls.

Named argument may be unresolved

Reports the named arguments in method calls that might be unresolved depending on a specific class instance within the hierarchy.

Named arguments order does not match parameters order

Reports named argument with order that does not match parameter order.

Nested 'dirname()' call can be replaced with 'levels' parameter usage

Reports the nested dirname() calls that can be omitted by using the levels parameter instead.

Nested 'min/max' call

Reports nested min/max calls.

Nested ternary operator usage

Reports nested ternary expressions, which are deprecated starting from PHP 7.4.

Nested vs outer 'foreach' variables conflict

Reports the variables that are used as a key or value both by the inner and outer foreach loops.

NoReturn attribute can be added

Reports function without #[NoReturn] that are always halting their execution by calling other exitPoint functions attribute.

Non-applicable attribute target declaration

Reports the attributes that do not have the appropriate Attribute::TARGET_* flag in their arguments declaration.

Non-canonical order of elements

Reports the PHPDoc tags that have elements listed in non-canonical order.

Non-repeatable attribute

Reports repeated attributes without the Attribute::IS_REPEATABLE flag in their arguments declaration.

Non-strict object equality

Reports the usages of the comparison operator (==) for comparing object variables.

Nullsafe operator '?->' can be used

Reports the null-checking conditional expressions that can be safely replaced with the ?-> nullsafe operator.

Number ranges mismatch

Reports the assignments and return statements whose arguments do not match the expected ranges specified via int<min, max> PHPDoc syntax.

ObjectShape can be added

Reports public properties of an object with specified types.

Old style constructor

Reports old-style constructor declarations (ClassName()) and suggests replacing them with new-style constructors (__construct()).

One-per-line trait uses

Reports the cases of several traits being imported via a single use statement.

Open 'echo' tag usage

Reports the <?php echo usages that can be replaced with a short tag <?=.

Optional before required parameter

Reports the optional parameters that appear before the required parameters in a function/method declaration.

Order of modifiers

Reports visibility modifiers that are specified in the incorrect order.

Overriding method/extending class marked as '@final'

Reports override of method or extending of class with @final in the PHPDoc.

PHP CS Fixer validation

Reports coding style problems detected by PHP CS Fixer.

PHP Mess Detector validation

Reports coding style problems detected by PHP Mess Detector.

PHPDoc comment matches function/method signature

Reports the parameters' names and types in a PHPDoc comment that do not match the ones in the function/method declaration.

PHPDoc comment signature is not complete

Reports the PHPDoc comments that contain at least one @param or @return tag but are missing some of the @param or @return tags for parameters or return types specified in the function/method declaration.

PHPStan validation

Runs PHPStan to find code problems.

PHPUnit annotation is deprecated in PHPUnit 11 and can be replaced with attribute

Suggests replacing PHPUnit annotations with attributes.

Parameter type

Reports the parameters passed to a function call, whose types do not match the ones specified in the function definition via type declaration or the PHPDoc @param tag.

Parameter's name changed during inheritance

Reports the methods' parameters whose names differ from the same parameters defined in parent methods.

Parameter's value is always the same

Reports the parameters in private methods that have the same value across all method calls.

Parameters number mismatch declaration

Reports the function/method calls that take more parameters than specified in their declaration.

Parentheses around the 'new' call can be omitted

Reports parentheses around the new expression in statements with class member access on instantiation, e.g.

Parse error due to unpaired parentheses in string literals

Reports the unpaired parentheses in string literals that produce blade parser errors.

Pass parameter by reference

Reports the arguments in a function/method call that cannot be passed by reference.

Passing 'E_USER_ERROR' to 'trigger_error()' is deprecated since PHP 8.4

Reports passing a non-empty string as the $enclosure parameter of the CSV-related methods and functions: SplFileObject::setCsvControl() SplFileObject::fputcsv() SplFileObject::fgetcsv() fputcsv() fgetcsv() str_getcsv().

Passing 'null' or 'false' to 'dba_key_split()' is deprecated since PHP 8.4

Reports passing null or false to dba_key_split(), which is deprecated since PHP 8.4.

Passing an option of an incorrect type is deprecated since PHP 8.4

Reports passing incorrect data types for options to Hash extension functions, which is deprecated since PHP 8.4.

Pointless boolean expression inside 'if' condition

Reports the boolean expressions inside if conditions that contain $expr == true or $expr == false.

Possible polymorphic call

Reports polymorphic code usages.

Private method may be inaccessible during late static binding call

Reports the late static binding method calls (that is, performed via static::) that may be resolved to inaccessible private methods from child classes.

Private property can be local

Reports the private properties that are used only in a single method.

Promoted property usage

Reports properties declared through promoted constructor parameters.

Property can be 'readonly'

Reports the private promoted properties that are never written to.

Property can be promoted

Reports the properties that can be replaced with promoted versions.

Property is immediately rewritten

Reports the write expressions on properties which are immediately overwritten before being accessed.

Property name is not following coding convention

Reports the properties' names that are either too short, too long, or do not follow the specified regular expression pattern.

Property usages have same access

Reports the private properties that are: written but never read read but never written.

Psalm validation

Runs Psalm to find code problems.

Pure function may produce side effects

Reports the #[Pure] annotations used on functions that may produce side effects.

Raising zero to the power of negative number is deprecated since PHP 8.4

Reports raising zero to the power of a negative number, which is deprecated since PHP 8.4.

Redeclaration of standard library function

Reports the redeclaration of standard library functions.

Redundant 'array_values' call on a value iterated in 'foreach'

Reports the array_values() calls inside foreach loops in which the iterated value is used without a key.

Redundant 'continue/break' argument

Reports the redundant 1 argument of continue and break statements.

Redundant 'static' in final class

Reports static usages inside final class.

Redundant @throws tag(s)

Reports @throws tags for exceptions that are not thrown by the function or method.

Redundant @var tag

Reports the @var tags for variables whose type is already inferred from source code.

Redundant PHPDoc comment

Reports PHPDoc comments or their parts that contain the information already provided in declarations.

Redundant assignment

Reports the assignment statements, in which both sides are equal.

Redundant assignment to promoted property

Reports redundant assignments to class properties that duplicate automatic assignments performed through promoted constructor parameters.

Redundant cast to boolean

Reports the (bool)/(boolean) casts and boolval() calls that are redundant since casting to bool is performed implicitly.

Redundant cast to string

Reports the (string) casts and strval() calls that are redundant since casting to string is performed implicitly.

Redundant catch clause

Reports the catch clauses with exceptions that are never thrown from the corresponding try block.

Redundant closure '.*'

Reports redundant leading and trailing '.*' in pattern for `preg_match` function.

Redundant intersection type

Reports the intersection type declarations that contain redundant types, for example, an intersection type that contains both the parent class and its subclass.

Redundant method override

Reports the overriding methods that only consist of a single call to the parent method.

Redundant modifier

Reports the i (case insensitivity) modifiers that are used in regular expression patterns containing no letters.

Redundant optional argument

Reports redundant arguments that match the corresponding default values for optional parameters.

Redundant parentheses in attribute

Reports empty arguments lists in attributes.

Redundant property initializer

Reports the fields with default initializers that are always overwritten in the class constructor.

Result of 'instanceof' is always 'true'

Reports the instanceof expressions whose argument is within the hierarchy of the checked variable.

Return type in PHPDoc comment does not match the actual return type

Reports the return types in PHPDoc comments that do not match the actual return type of a function.

Second write to 'readonly' property

Reports reassignments of readonly properties.

Short form of type keywords

Reports usages of long form type keywords.

Short open 'echo' tag usage

Reports short PHP echo tag <?= usages.

Short open tag usage

Reports short PHP opening tag <? usages.

Single-statement body with braces

Reports the control structures (such as loops or conditionals) whose bodies are enclosed in braces but only contain a single child statement.

Some enum cases are uncovered

Reports the match expressions that don't cover all enum cases in match arm conditions.

Statement has empty body

Reports the statements that have empty bodies.

Static function should not be abstract

Reports the static methods that are declared as abstract.

Static method called as dynamic

Reports dynamic calls to static class methods.

Strict comparison of operands with incompatible types

Reports the === or !== strict comparisons used on operands with incompatible types.

Strict type checking rules violation

Reports violations of the strict type checking rules.

Suspicious names combination

Reports the assignments and function calls where the name of the variable or parameter probably doesn't match the name of the assigned or passed value.

Switch statement without default branch

Reports the switch statements without a default branch.

Symfony annotation can be replaced with attribute

Suggests replacing Symfony annotations with attributes.

Ternary expression can be replaced with condition

Reports the ternary expressions specified as condition ? true : false that can be safely replaced with just condition.

Ternary expression can be replaced with short version

Reports the ?: ternary expressions in which the condition and the true statement are matching.

The dataset does not exist

Reports a non-existent Pest dataset.

Too many parameters in function declaration

Reports the function/method declarations with the number of parameters exceeding the specified limit.

Traditional syntax array literal detected

Reports traditional array syntax (array()) usages in array literals and suggests replacing them with short array syntax ([]).

Trait usage is not allowed

Reports the class references that are resolved to traits but are specified outside use statements.

Trait use rule resolved to method with different containing class

Reports the trait method use rules that are resolved to methods from a different containing class rather than the one specified in the use declaration.

Type already exists in PHPDoc tag

Reports duplicate types in PHPDoc comments.

Type cast is unnecessary

Reports the type cast operators used on the values that are already of the corresponding type.

Type cast on a scalar value

Reports the type casts that can be evaluated in place and suggests replacing them with actual computed values.

Type declaration is redundant and could be simplified

Reports union type declarations that contain redundant types, for example, a union type that contains both the class alias and the original class.

Type doesn't match property's declared type

Reports the properties' types in PHPDoc @var tags that do not match the declared type of a property.

Type hint 'array|Traversable' can be replaced with 'iterable'

Reports the array|Traversable type hints that can be replaced with iterable.

Type mismatch in property assignment

Reports type violations in properties assignments.

Type tag without variable name

Reports the PHPDoc type tags (@var,@type,@param) that are provided without a specified variable/parameter name.

Typed property might be uninitialized

Reports the attempts to read from an uninitialized typed property.

Undefined PHPUnit data provider

Reports the references to functions/methods in the @dataProvider PHPDoc tag that are not resolved.

Undefined callback

Reports the functions, methods, properties, or classes that are referenced from a callback but are not found.

Undefined class

Reports the references to classes whose declarations are not found in the project files, configured include paths, or among the PHP predefined classes.

Undefined class constant

Reports the references to class constants that are not declared.

Undefined constant

Reports the references to constants that are not found in the project files, configured include paths, or among the PHP predefined constants.

Undefined function

Reports the references to functions that are not defined in the project files, configured include paths, or among the PHP predefined functions.

Undefined goto label

Reports the goto labels that are not found in the current scope.

Undefined method

Reports the references to class methods that are not defined.

Undefined namespace

Reports the references to a namespace that is not found.

Undefined property

Reports the references to class properties that are not declared.

Undefined variable

Produces two types of warnings: Undefined variable: the variable's definition is not found in the project files, configured include paths, or among the PHP predefined variables.

Unhandled exception

Reports the exceptions that are neither enclosed in a try-catch block nor documented via the @throws tag.

Unnecessary 'else' branch

Reports the else branches in if statements whose bodies always execute a terminating statement such as return or throw.

Unnecessary 'return/continue' statement

Reports unnecessary return and continue statements that can be safely removed.

Unnecessary curly braces syntax for variable

Reports unnecessary { and } used for interpolating variables in string literals.

Unnecessary double quotes

Reports double-quoted string literals that do not contain string interpolation, escape sequences, or single quotes.

Unnecessary fully qualified name

Reports the usages of fully qualified class names, which can be shortened without adding the use statement.

Unnecessary leading '\' in 'use' statement

Reports the use statements with an unnecessary leading \.

Unnecessary local variable

Reports the local variables that are used in exit statements, such as throw, return, or yield, immediately after assignment.

Unnecessary pass-by-ref

Reports the variables that are passed by reference to a function/method but are not modified in the function/method body.

Unnecessary spread operator for function call argument

Reports the usages of the spread operator (...) on array literals in function call arguments that may be safely unwrapped.

Unnecessary statement use

Reports the use statements that contain non-fully qualified class names and thus have no effect.

Unpacking arrays with string keys is forbidden for PHP < 8.1

Reports array unpacking with string keys in PHP < 8.1 See Array unpacking with string keys for details.

Unreachable statement

Reports the statements that cannot be reached.

Unresolved include

Reports non-resolved include, include_once, require, and require_once expressions.

Unsupported modifier

Reports the usages of the e modifier in regular expression patterns.

Unused 'match' condition

Reports the conditions in match expressions that will never be matched.

Unused 'switch' branch

Reports the branches in switch statements that do not belong to the set of enum cases and as a result are never executed.

Unused local variable

Reports the variables that are considered unused in the following cases: The value of the variable is not used anywhere or is overwritten immediately.

Unused parameter

Reports the parameters that are considered unused in the following cases: The parameter is passed by value, and the value is not used anywhere or is overwritten immediately.

Unused private method

Reports the private methods that are never used.

Unused private property

Reports the private properties that are never used.

Usage 'assertCount/assertSameSize' methods instead of assertEquals

Reports alternative usage of the assertEquals and assertNotEquals methods with count function as a parameter See Usage of the assertCount for details.

Usage of a silence operator

Reports the usages of the silence operator (@), which is highly discouraged.

Usage of a variable variable

Reports the usages of variable variables (dynamic variable names such as $$a).

Usage of internal entity

Reports the usages of the entities that are marked as @internal and are located in different source roots.

Usage of var

Reports the usages of the var keyword for declaring class properties.

Useless trailing comma

Reports the trailing commas in parameters lists and closures' use lists that do not bring any benefit.

Using 'count()' as index for appending value to array

Reports the count($array) calls that are used as an array index for appending an element to the array: $array[count($array)] = 42.

Using a single underscore '_' as a class name is deprecated since PHP 8.4

Reports usage of a single underscore (_) as a class name, which is deprecated since PHP 8.4.

Variable is only used inside closure

Reports variables in closures' use list that are only used inside closure.

Variable name is not following coding convention

Reports the variables' names that are either too short, too long, or do not follow the specified regular expression pattern.

Visibility modifier can be removed

Reports a public visibility modifier that may be omitted for a property which has reduced set visibility specified.

Vulnerabilities scanner

Call of this function may be unsafe.

Vulnerable paths scanner

Global taint analysis inspection.

Words in Pest dataset names should be separated by spaces

Reports invalid names for pest dataset cases.

Words in Pest test names should be separated by spaces

Reports invalid names for pest test cases.

Write access to 'readonly' property outside of declaration scope

Reports the write accesses to readonly properties that are made outside the declaration scope.

Write access to referenced array value without 'unset'

Reports the write access expressions on variables that are still referencing the array value previously used in a foreach statement.

Wrong catch clauses order

Reports the exceptions that are already caught by a preceding exception and the exceptions that are caught twice.

Wrong string concatenation

Reports the attempts to concatenate strings by using the + operator instead of the dot (.) concatenation operator.

Pointcutexpression

Name

Description

Incorrect Spring AOP pointcut expression

Reports AspectJ pointcut designators which are not supported by Spring.

Pointcut expression errors

Reports issues in AOP pointcut expressions.

Postcss

Name

Description

Invalid custom media

Reports a syntax error in a PostCSS Custom Media query.

Invalid custom selector

Reports a syntax error in PostCSS Custom Selector.

Invalid media query range

Checks range context syntax, which may alternatively be used for media features with a 'range' type.

Invalid nested rule

Reports a nested style rule whose syntax doesn't comply with the PostCSS Nested or the PostCSS Nesting specification.

Unresolved CSS module value

Reports an unresolved reference to a CSS Module Value (@value declaration).

Properties

Name

Description

Duplicate property

Reports duplicate property keys with different values, duplicate keys, or duplicate property values.

Inconsistent resource bundle

Reports problems in the properties files contained in the resource bundle.

Invalid Quarkus application.properties configuration

Reports syntax errors, type errors, deprecated and unresolvable keys and values in Quarkus .properties configuration files.

Invalid properties configuration

Reports unresolved and deprecated configuration keys and invalid values in Spring Boot application .properties configuration files, which can lead to runtime errors.

Message format validation in properties files

Reports the following MessageFormat problems in property values: Unknown format types MessageFormat supports only these format types: number date time choice Other format types will be reported.

Micronaut application.properties

Reports deprecated configuration keys and invalid values in Micronaut application .properties configuration files.

Missing message format parameter

Reports properties values that look like java.text.MessageFormat format strings but do not use some the parameters of the {xx} kind.

Properties file or resource bundle is alphabetically unsorted

Reports alphabetically unsorted resource bundles or .properties files.

Property key/value delimiter doesn't match code style settings

Reports properties in which key or value delimiters do not match code style settings.

Suspicious resource bundle locale languages

Reports locales with language codes that are not supported by Java.

Three dot characters instead of the ellipsis

Reports three "dot" characters which are used instead of the ellipsis character for UTF-8 properties files.

Trailing spaces in property

Reports properties whose keys or values end with a whitespace.

Unresolved file or class reference in a spring.handlers or spring.schemas file

Reports unresolved class and file references in spring.handlers and spring.schemas files.

Unused property

Reports properties that are not referenced outside of the .properties file they are contained in.

Protobuf

Name

Description

Duplicated import statements

Reports effectively equivalent import statements.

Puppet

Name

Description

Deprecated in Puppet 3

Reports the use of the syntax deprecated since Puppet 3, such as import statements.

Deprecated in Puppet 4

Reports the use of the syntax deprecated since Puppet 4, such as: The class name for classes Uppercase variable names Qualified variables with underscores Note that these constructions work properly in Puppet 3.x and earlier.

Multiple hash set parameters

Reports resource instances with two or more HashSet parameters (* =>).

Unresolved symbol

Reports unresolved symbols in Puppet files.

Python

Name

Description

A byte literal contains a non-ASCII character

Reports characters in byte literals that are outside ASCII range.

Accessing a protected member of a class or a module

Reports cases when a protected member is accessed outside the class, a descendant of the class where it is defined, or a module.

An instance attribute is defined outside `__init__`

Reports a problem when instance attribute definition is outside __init__ method.

An invalid interpreter

Reports problems if there is no Python interpreter configured for the project or if the interpreter is invalid.

Assigning function calls that don't return anything

Reports cases when an assignment is done on a function that does not return anything.

Assignment can be replaced with augmented assignment

Reports assignments that can be replaced with augmented assignments.

Assignments to 'for' loop or 'with' statement parameter

Reports the cases when you rewrite a loop variable with an inner loop.

Attempt to call a non-callable object

Reports a problem when you are trying to call objects that are not callable, like, for example, properties:.

Celery task class or function is not registered

Reports an unregistered task in Celery Beat Schedule.

Check Python source code coverage

Reports methods, classes and files whose coverage is below a certain threshold.

Class has no `__init__` method

Reports cases in Python 2 when a class has no __init__ method, neither its parent classes.

Class must implement all abstract methods

Reports cases when not all abstract properties or methods are defined in a subclass.

Class-specific decorator is used outside the class

Reports usages of @classmethod or @staticmethod decorators in methods outside a class.

Classic style class usage

Reports classic style classes usage.

Code is incompatible with specific Python versions

Reports incompatibility with the specified versions of Python.

Constance setting is not in fieldsets

Detects missing keys in CONSTANCE_CONFIG_FIELDSETS (a constant for configuring Django Constance).

Deprecated function, class, or module

Reports usages of Python functions, or methods that are marked as deprecated and raise the DeprecationWarning or PendingDeprecationWarning warning.

Dictionary contains duplicate keys

Reports using the same value as the dictionary key twice.

Dictionary creation can be rewritten by dictionary literal

Reports situations when you can rewrite dictionary creation by using a dictionary literal.

Django ORM error

Reports several methods that may not be called due to some ORM reasons.

Errors in string formatting operations

Reports errors in string formatting operations.

Exceptions do not inherit from standard 'Exception' class

Reports cases when a custom exception class is raised but does not inherit from the builtin Exception class.

File contains non-ASCII character

Reports cases in Python 2 when a file contains non-ASCII characters and does not have an encoding declaration at the top.

First argument of the method is reassigned

Reports cases when the first parameter, such as self or cls, is reassigned in a method.

Fixture is not requested by test functions

Reports if a fixture is used without being passed to test function parameters or to @pytest.mark.usefixtures decorator.

Function call can be replaced with set literal

Reports calls to the set function that can be replaced with the set literal.

Global variable is not defined at the module level

Reports problems when a variable defined through the global statement is not defined in the module scope.

Improper first parameter

Reports methods that lack the first parameter that is usually named self.

Improper position of from __future__ import

Reports from __future__ import statements that are used not at the beginning of a file.

Inappropriate access to properties

Reports cases when properties are accessed inappropriately: Read-only properties are set Write-only properties are read Non-deletable properties are deleted Example: class MyClass: @property def read_only(self): return None def __write_only_setter(self, value): pass write_only = property(None, __write_only_setter) a = MyClass() a.read_only = 10 # property cannot be set del a.read_only # property cannot be deleted print(a.write_only) # property cannot be read.

Incompatible signatures of __new__ and __init__

Reports incompatible signatures of the __new__ and __init__ methods.

Incompatible stub packages

Reports stub packages that do not support the version of the corresponding runtime package.

Inconsistent indentation

Reports inconsistent indentation in Python source files when, for example, you use a mixture of tabs and spaces in your code.

Incorrect arguments in @pytest.mark.parametrize

Reports functions that are decorated with @pytest.mark.parametrize but do not have arguments to accept parameters of the decorator.

Incorrect call arguments

Reports discrepancies between declared parameters and actual arguments, as well as incorrect arguments, for example, duplicate named arguments, and incorrect argument order.

Incorrect docstring

Reports mismatched parameters in a docstring.

Incorrect property definition

Reports problems with the arguments of property() and functions annotated with @property.

Incorrect type

Reports type errors in function call expressions, targets, and return values.

Invalid TypedDict definition and usages

Reports invalid definition and usage of TypedDict.

Invalid definition and usage of Data Classes

Reports invalid definitions and usages of classes created with dataclasses or attr modules.

Invalid definition of 'typing.NamedTuple'

Reports invalid definition of a typing.NamedTuple.

Invalid protocol definitions and usages

Reports invalid definitions and usages of protocols introduced in PEP-544.

Invalid type hints definitions and usages

Reports invalid usages of type hints.

Invalid usage of ClassVar variables

Reports invalid usages of ClassVar annotations.

Invalid usage of new-style type parameters and type aliases

Reports invalid usage of PEP 695 type parameter syntax.

Invalid usages of @override decorator

Reports when a method decorated with @override doesn't have a matching method in its ancestor classes.

Invalid usages of classes with '__slots__' definitions

Reports invalid usages of a class with __slots__ definitions.

Invalid usages of final classes, methods, and variables

Reports invalid usages of final classes, methods and variables.

Method Series.to_list() is recommended

Reports redundant list in list(Series.values) statement for pandas and polars libraries.

Method is not declared static

Reports any methods that do not require a class instance creation and can be made static.

Method signature does not match signature of overridden method

Reports inconsistencies in overriding method signatures.

Missed call to '__init__' of the super class

Reports cases when a call to the super constructor in a class is missed.

Missing `await` syntax in coroutine calls

Reports coroutines that were called without using the await syntax.

Missing or empty docstring

Reports missing and empty docstrings.

Missing type hinting for function definition

Reports missing type hints for function declaration in one of the two formats: parameter annotations or a type comment.

No encoding specified for file

Reports a missing encoding comment in Python 2.

Non-optimal list declaration

Reports cases when a list declaration can be rewritten with a list literal.

Old-style class contains new-style class features

Reports occurrences of new-style class features in old-style classes.

Overloads in regular Python files

Reports cases when overloads in regular Python files are placed after the implementation or when their signatures are not compatible with the implementation.

PEP 8 coding style violation

Reports violations of the PEP 8 coding style guide by running the bundled pycodestyle.py tool.

PEP 8 naming convention violation

Reports violations of the PEP8 naming conventions.

Problematic nesting of decorators

Reports problems with nesting decorators.

Prohibited trailing semicolon in a statement

Reports trailing semicolons in statements.

Redeclared names without usages

Reports unconditional redeclarations of names without being used in between.

Redundant boolean variable check

Reports equality comparison with a boolean literal.

Shadowing built-in names

Reports shadowing built-in names, such as len or list.

Shadowing names from outer scopes

Reports shadowing names defined in outer scopes.

Single quoted docstring

Reports docstrings that do not adhere to the triple double-quoted string format.

Statement has no effect

Reports statements that have no effect.

Stub packages advertiser

Reports availability of stub packages.

Suspicious relative imports

Reports usages of relative imports inside plain directories, for example, directories neither containing __init__.py nor explicitly marked as namespace packages.

The default argument is mutable

Reports a problem when a mutable value as a list or dictionary is detected in a default value for an argument.

The function argument is equal to the default parameter value

Reports a problem when an argument passed to the function is equal to the default parameter value.

Too complex chained comparisons

Reports chained comparisons that can be simplified.

Tuple assignment balance is incorrect

Reports cases when the number of expressions on the right-hand side and targets on the left-hand side are not the same.

Tuple item assignment is prohibited

Reports assignments to a tuple item.

Type in docstring does not match inferred type

Reports types in docstring that do not match dynamically inferred types.

Unbound local variables

Reports local variables referenced before assignment.

Unclear exception clauses

Reports exception clauses that do not provide specific information about the problem.

Unnecessary backslash

Reports backslashes in places where line continuation is implicit inside (), [], and {}.

Unresolved Constance setting

Reports unresolved keys in Django Constance configuration.

Unresolved columns

Reports attempts to access PySpark DataFrame columns that do not exist in the schema.

Unused local symbols

Reports local variables, parameters, and functions that are locally defined, but not used name in a function.

Using equality operators to compare with None

Reports comparisons with None.

Wrong arguments to call super

Reports cases when any call to super(A, B) does not meet the following requirements:.

Wrong order of 'except' clauses

Reports cases when except clauses are not in the proper order, from the more specific to the more generic, or one exception class is caught twice.

__init__ method that returns a value

Reports occurrences of return statements with a return value inside __init__ methods of classes.

Regexp

Name

Description

Anonymous capturing group or numeric back reference

Reports anonymous capturing groups and numeric back references in a RegExp.

Begin or end anchor in unexpected position

Reports ^ or \A anchors not at the beginning of the pattern and $, \Z or \z anchors not at the end of the pattern.

Consecutive spaces

Reports multiple consecutive spaces in a RegExp.

Duplicate branch in alternation

Reports duplicate branches in a RegExp alternation.

Duplicate character in character class

Reports duplicate characters inside a RegExp character class.

Element in class is already covered

Reports the elements in regular expression character classes that are already covered by another element in the same class.

Empty branch in alternation

Reports empty branches in a RegExp alternation.

Escaped meta character

Reports escaped meta characters.

Octal escape

Reports octal escapes, which are easily confused with back references.

Ranges in class can be merged

Reports the alphabetic ranges or characters in regular expression character classes that only adjust the already existing ranges.

Redundant '\d', '[:digit:]', or '\D' class elements

Reports redundant \d or [:digit:] that are used in one class with \w or [:word:] (\D with \W) and can be removed.

Redundant character escape

Reports redundant character escape sequences that can be replaced with unescaped characters preserving the meaning.

Redundant nested character class

Reports unnecessary nested character classes.

Regular expression can be simplified

Reports regular expressions that can be simplified.

Single character alternation

Reports single char alternation in a RegExp.

Suspicious back reference

Reports back references that will not be resolvable at runtime.

Unnecessary non-capturing group

Reports unnecessary non-capturing groups, which have no influence on the match result.

Requirements

Name

Description

Requirement is not satisfied

Reports packages mentioned in requirements files (for example, requirements.txt, or dependencies section in pyproject.toml files) but not installed, or imported but not mentioned in requirements files.

Rest

Name

Description

Role is not defined

Reports undefined roles in reStructuredText files.

Ruby

Name

Description

'case' statement without 'else' block

Reports case statements without else blocks.

'find' or 'find_by' method call in view

Reports usages of find or find_by in a view or view helper.

'nil' dereference

Reports possible nil dereferences.

'super' call with no superclass defined

Reports super calls outside of methods or in classes that have no superclass defined.

'then' in multiline 'if'/'unless' block

Reports redundant then keywords in multiline if/unless blocks.

'unless' statement with 'else'

Reports unless statements used with else.

Array of string literals instead of '%w'

Reports arrays of string literals that can be replaced with %w.

Assignment expression in conditional

Reports usages of assignment expressions in conditionals.

Block used instead of method reference

Reports blocks that can be replaced with method references.

Brakeman

Reports issues from the Brakeman scanner.

Class variable usage

Reports the use of class variables.

Class/module with too many instance variables

Reports classes/modules with too many instance variables.

Class/module with too many methods

Reports classes/modules with too many methods.

Complex call chain

Reports chained calls that can be simplified with the safe navigation operator (&.).

Conditional expression with parentheses

Reports conditional expressions with parentheses inside if, elsif, unless, while, and until statements.

Deprecated feature

Reports usages of deprecated methods and constants.

Deprecated syntax

Reports the use of the syntax deprecated from Ruby 1.9.

Duplicate key in hash

Reports duplicate keys in hashes, method definitions, and calls.

Duplicated step definitions

Reports duplicated Cucumber step definitions.

Dynamic constant assignment

Reports dynamic constant assignment.

Empty 'else' block

Reports empty else blocks.

Empty 'rescue' block

Reports empty rescue blocks.

Expression can be simplified

Reports boolean expressions that can be simplified.

Expression substitution in single-quoted string

Reports expression substitutions #{...} in single-quoted strings.

Frozen object modification

Reports method calls that attempt to modify frozen objects.

Hash with strings as keys

Reports hashes with strings as keys.

Incorrect 'Hash[...]' call

Reports improperly constructed Hash[...] calls.

Incorrect call argument count

Reports method calls where: The number of arguments passed to the method doesn't match the number of parameters A required block is missing.

Incorrect context for jump statement

Reports the incorrect use of control flow jump statements, such as return, retry, redo, break, and continue.

Incorrect parentheses in method definition

Reports method definitions with the incorrect parentheses style.

Incorrect tag usage

Reports duplicated @param tags and undefined parameters in @param YARD tags.

Interpolated variable without braces

Reports interpolated variables (instance or global) without braces in expression substitutions.

Invalid call to protected/private method

Reports invalid calls to protected/private methods.

Legacy hash syntax

Reports hashes which use the hash rocket style that can be converted to the ruby 1.9+ style.

Mailbox missing 'process' method

Reports mailboxes that are missing the process method.

Mailbox with no routes

Reports mailboxes that have no routes pointing to them.

Mismatched argument type

Reports method and yield calls with arguments whose inferred types don't match the parameter's expected type.

Mismatched constant type

Reports constant assignments whose inferred types don't match the constant's expected type.

Mismatched global variable type

Reports global variable assignments whose inferred types don't match the global variable's expected type.

Mismatched parameter type

Reports default method and block parameter assignments whose inferred types don't match the parameter's expected type.

Mismatched return type

Reports method and block return values whose inferred types don't match the method's expected return type.

Mismatched variable type

Reports instance and class variable assignments whose inferred types don't match the variable's expected type.

Missing '@param' tag in method parameter

Reports method parameters without @param tags.

Missing '@return' tag in method

Reports methods that are not annotated with a @return tag.

Missing gem

Reports missing gems from the current SDK.

Missing type signature

Reports missing type signatures for classes, modules, constants, global/instance/class variables, methods, and aliases.

Negative condition in control flow statement

Reports control flow statements with negative conditions.

Nested ternary operator

Reports nested ternary operators.

No Ruby interpreter configured for the project

Reports when the current project has no Ruby interpreter configured, or an invalid interpreter configured.

Parameters count mismatch

Reports step definitions where the number of step name parameters does not match the number of parameters of the Ruby block.

Redundant 'return' statement

Reports redundant return keywords and statements.

Redundant parentheses in no-arg method call

Reports no-arg method calls with parentheses.

Redundant safe navigation

Reports the use of the safe navigation operator (&.) with a non-nil receiver, which can be omitted.

Redundant variable used as 'return' value

Reports variables used as return values.

RuboCop

Reports issues from the RuboCop linter.

Shoulda test with incorrect file name

Reports Shoulda tests with incorrect file names.

Simplifiable 'if' statement

Reports if statements that can be replaced with case statements.

Unbalanced brackets

Reports blocks of code with unbalanced brackets.

Unconventional 'for' loop

Reports usages of for loops.

Unconventional class method name

Reports class methods with names that are either too short, too long, or don't match the specified regular expression pattern.

Unconventional class variable name

Reports class variables with names that are either too short, too long, or don't match the specified regular expression pattern.

Unconventional class/module name

Reports classes and modules with names that are either too short, too long or don't match the specified regular expression pattern.

Unconventional constant name

Reports any constants whose names are either too short, too long, or do not follow the specified regular expression pattern.

Unconventional global variable name

Reports global variables with names that are either too short, too long, or don't match the specified regular expression pattern.

Unconventional instance method name

Reports instance methods with names that are either too short, too long, or don't match the specified regular expression pattern.

Unconventional instance variable name

Reports instance variables with names that are either too short, too long, or don't match the specified regular expression pattern.

Unconventional local variable name

Reports local variables with names that are either too short, too long, or don't match the specified regular expression pattern.

Unconventional parameter name

Reports parameters with names that are either too short, too long, or don't match the specified regular expression pattern.

Unexpected argument in method call

Reports unexpected parameter values in method calls.

Unnecessary use of double quotes in string

Reports double-quoted strings that can be converted to single-quoted.

Untranslated i18n property

Reports usages of i18n property keys which are missing translations.

Unused local variable/parameter

Reports local variable or parameter declarations and assignments that are unused.

Variable/parameter scope

Reports the use of local variables or parameters that may be unsafe: Implicit or explicit variables or parameters that shadow an outer variable or parameter Uninitialized variables or parameters Redundant variable declarations inside blocks.

Whitespace before parentheses in method call

Reports method calls (including yield) with whitespace before its parentheses.

Ruby.rbs

Name

Description

Bad type argument type

Reports type arguments passed to generic types which do not subtype the expected upper bound.

Bad type variable default type

Reports default types in type variable declarations which do not subtype the upper bound.

Conflicting type variable count

Reports conflicting partial container declarations due to a mismatch between the number of type variables.

Conflicting type variable variance

Reports type variables whose variance (in, out, or unchecked) conflicts with another declaration.

Cyclic class/module alias declaration

Reports cyclic declarations of class or module aliases.

Duplicate keyword parameter

Reports duplicate keyword parameters in methods, blocks, and proc types.

Inconsistent class/module alias

Reports inconsistent declarations of class and module aliases.

Incorrect inclusion call

Reports inclusion calls (include, prepend and extend) that reference a class.

Incorrect type argument count

Reports references to generic types with the incorrect number of type arguments.

Incorrect type argument variance

Reports type arguments used in an inheritance statement (a superclass clause, self-type, or an inclusion call) which have incorrect variances.

Invalid method overload

Reports invalid method overloads (...).

Invalid type argument usage

Reports type variables used as arguments in locations that their variance does not allow, so long as they are not marked as unchecked.

Literal class referenced

Reports references to the classes NilClass, TrueClass, and FalseClass in type signatures.

Module used as superclass

Reports modules used in superclass clauses.

Simplifiable boolean union

Reports usages of true | false that can be replaced with bool.

Unconventional interface name

Reports interfaces with names that are either too short, too long, or don't match the specified regular expression pattern.

Unconventional type alias name

Reports type aliases with names that are either too short, too long, or don't match the specified regular expression pattern.

Unconventional type variable name

Reports type variables with names that are either too short, too long, or don't match the specified regular expression pattern.

Unconventional use alias name

Reports use aliases with names that are either too short, too long, or don't match the specified regular expression pattern.

Unnecessary qualifier

Reports unnecessary qualifiers within references.

Unused interface

Reports interfaces that are unused within the project.

Unused type alias

Reports type aliases that are unused within the project.

Unused type variable

Reports container, method, and type alias type variables that are unused within the project.

Unused use clause

Reports use clauses that are unused or unnecessary within the file.

Rust

Name

Description

'crate' misplaced in path

Reports incorrect use of the literal `crate` in a path.

A non-constant value was used in a constant expression

Reports a non-constant value or function call used in a constant expression.

Additional non-auto trait in trait object

Reports trait objects with additional non-auto traits.

Anonymous function parameters not allowed

Reports the use of anonymous parameters in functions that do not allow it.

Approximated constants

Reports hard coded numeric constants such as std::f64::consts::PI.

Argument naming convention

Checks if function and method argument names follow the Rust naming convention.

Associated type naming convention

Checks if associated type names follow the Rust naming convention.

Attempt to call not a function

When calling somethings, checks that it is function or method.

Attribute error

Reports issues with attributes including misuse, redundancy, formatting errors, invalid entries, outdated syntax, and more.

Attribute without parentheses

Detects incomplete attributes that require parentheses.

Base expression required after `..`

Highlights .

Blocking `sleep` function cannot be used in `async` context

Detects usages of blocking thread::sleep() function in async contexts.

Boolean expression can be simplified

Detects boolean expressions that can be safely simplified like a || true.

Borrow checker errors

Reports basic borrow checker errors.

Both `Copy` and `Drop` implemented

Reports cases where the `Copy` trait is implemented along with `Drop`, which is considered unsafe and currently not allowed in the Rust language.

Cast can be replaced with literal suffix

Detects as casts that can be replaced with literal suffixes.

Char literal empty or too long

Reports char literals which are empty or too long.

Circular modules

Reports circular module declarations with the #path attribute.

Comma-separated trait bounds

Reports trait bounds for a single type that are separated with a comma instead of a `+` sign.

Compiler feature is unavailable

Reports code that uses unavailable compiler features.

Complex pattern in function

Reports incorrect use of patterns in functions.

Const generic argument expression without braces

Reports const generic argument expressions with missing braces.

Constant naming convention

Checks if constant names follow the Rust naming convention.

Constants cannot refer to statics

Detects constant variables that refer to static variables.

Dangling `else`

Detects suspiciously looking else if-statements split by new lines.

Default parameter values (unsupported)

Reports the use of default parameter values, which are not supported in Rust.

Default type parameters syntax

Report incorrect usage of default type parameters.

Defaults for const parameters not allowed

Reports invalid use of defaults for const parameters.

Deprecated `...` syntax

Reports the use of `...` deprecated syntax.

Derived trait not implemented

Reports members that do not implement the traits being derived.

Detached file

Detects files that are not attached to any Rust module.

Double negation

Detects expressions of the form --x which might be mistook for pre-decrements.

Duplicate definition

Reports duplicate items (such as field declarations, type parameters, etc.).

Duplicate hash key

Reports duplicate keys when creating hash maps.

Duplicate macro pattern

Checks duplicated patterns in macro definitions.

Duplicate trait method parameter name

Checks duplicated parameter names of abstract trait methods.

Dynamic environment capture in `fn`

Reports captures of a dynamic environment in a `fn` item.

Entry point is async

Checks if the entry point of the program was marked as async.

Enum naming convention

Checks if enum names follow the Rust naming convention.

Enum variant naming convention

Checks if enum variant names follow the Rust naming convention.

Equality assertion can be simplified

Detect assert!(a == b) (and assert!(a != b)) macro call that can be simplified into assert_eq!(a, b) (or assert_ne!(a, b)).

Experimental inspections

Some unstable experimental checks which are disabled by default.

Explicit call to `drop`

Reports explicit calls to `drop`.

External linter

This inspection runs external linter to check for rustc or clippy errors.

Failed line in test

Reports failed function calls or assertions in tests.

Field naming convention

Checks if field names follow the Rust naming convention.

Foreign trait implementation

Reports implementations of foreign traits (traits defined outside the current crate) for arbitrary types.

Format macro error

Reports errors in the use of macros that support formatting.

Forward-declared identifier for parameter with default value

Reports generic parameters with default values that use forward-declared identifiers.

Function cannot be variadic

Reports functions that cannot be declared variadic.

Generic arguments must be specified before the first constraint

Reports generic arguments specified after the first constraint.

Immutable reassigned

Reports format! calls with missing format arguments.

Immutable variable reassigned

Detects immutable bindings reassignments.

Inclusive range without an end bound

Reports inclusive ranges without a specified end bound (`..=b` or `a..=b`).

Incorrect const syntax

Reports incorrect const syntax.

Incorrect function syntax

Reports incorrect function syntax.

Incorrect order of lifetime/type/const parameters

Reports incorrectly ordered lifetime, type, and const parameters.

Incorrect type alias syntax

Reports incorrect type alias syntax.

Incorrect visibility restriction

Reports incorrect visibility restrictions.

Index expression has a wrong type

Checks type of index expression.

Ineffective path statements

Detects path statements with no effect.

Inherent `impl` block not allowed for item

Reports inherent `impl` blocks defined for items other than structs, enums, unions, or trait objects.

Inherent `impl` defined outside type's containing crate

Reports inherent type implementations defined outside the type's original crate.

Inherent `impl` for dyn auto trait

Reports inherent implementations for dynamic auto traits.

Invalid 'break' or 'continue'

Reports invalid usages of break and continue in loops.

Invalid `#[start]` attribute

Reports incorrect usage of the #[start] attribute.

Invalid `?` usage

Reports incorrect usage of the ? operator.

Invalid `Copy` implementation

Reports invalid `Copy` implementations.

Invalid `Drop` implementation

Reports invalid `Drop` implementations.

Invalid `self` import

Reports invalid `self` imports.

Invalid crate name

Check if the crate name is valid, namely the crate name must not be empty, and must only contain Unicode alphanumeric or _ (U+005F) characters.

Invalid fields in struct

Reports incorrect field use in struct literals.

Invalid fields in struct or tuple struct pattern

Reports invalid fields in struct and tuple struct patterns.

Invalid label name

Reports labels with invalid names.

Invalid lifetime name

Reports lifetimes with invalid names.

Invalid literal suffix

Reports literals with invalid suffixes.

Invalid macro call

Reports errors when calling macros.

Invalid macro variable type

Reports invalid fragment specifier of a macro variable.

Invalid place expression

Reports invalid place expressions.

Invalid private field/method access

Reports invalid attempts to access private fields or methods.

Item cannot be inside another item

Reports structs, enums, macro definitions and traits placed inside other structs, enums, macro definitions or traits.

Lifetime bounds in parentheses

Reports lifetime bounds in parentheses.

Lifetime naming convention

Checks if lifetime names follow the Rust naming convention.

Literal out of range

Check if a numerical value is out of the range of the receiver.

Liveness analysis

Reports unused local variables and parameters.

Macro naming convention

Checks if macro names follow the Rust naming convention.

Main function not found

Checks if the main function exists in the binary crates.

Manual implementation of `Fn`, `FnMut`, or `FnOnce`

Reports manual implementations of `Fn`, `FnMut`, and `FnOnce` traits.

Match expression can be replaced with a method call

Reports match expressions that can be replaced with a method call.

Method naming convention

Checks if method names follow the Rust naming convention.

Misordered generic arguments

Generic arguments were not provided in the same order as the corresponding generic parameters are declared.

Misplaced `...` argument

Reports variadic functions where `...` is not positioned as the last argument.

Missing `dyn` in trait objects

Checks if trait objects are explicitly specified with dyn keyword.

Missing `else`

Detects suspiciously looking if-statements with potentially missing elses.

Missing parentheses for chained comparison

Reports chained comparison operators with missing parentheses.

Missing struct field type

Reports struct fields declared without a type.

Missing type for constant

Reports constant declarations with missing types.

Module declared outside mod.rs

Reports module declarations in files other than mod.rs.

Module naming convention

Checks if module names follow the Rust naming convention.

Multiple lifetime bounds for trait object

Reports trait objects with multiple lifetime bounds.

Multiple relaxed default bounds for type parameter

Reports type parameters with multiple relaxed default bounds.

Nested `impl Trait` not allowed

Reports the use of nested `impl Trait`.

Nested lifetime quantification

Reports where clauses containing nested quantification over lifetimes, which is not supported.

No boxing for async recursion

Reports recursion used in async functions without boxing.

No file found for module

Reports module declarations with no corresponding file found.

Non-exhaustive match

Checks that match expression is exhaustive, i.e.

Non-existent field access

Reports attempts to access non-existent fields.

Non-inline module declaration missing path attribute

Reports non-inline modules declared inside a block and missing the path attribute.

Non-shorthand field initialization

Reports cases where field initialization shorthand (RFC 1682) can be used.

Non-shorthand field pattern

Detects using Struct { x: x } instead of Struct { x } in a pattern.

Non-string ABI literal

Reports non-string ABI literals.

Non-structural-match type used for const generic parameter

Reports the use of non-structural-match types for const generic parameters.

Object type with no traits

Reports trait objects declared without a single trait.

Parameter type with unknown size

Reports function parameters whose types are unknown at compile time.

Proc macro defined outside `proc-macro` crate

Reports the use of #[proc_macro], #[proc_macro_attribute], and #[proc_macro_derive] attributes in non-procedural macro crates.

Public item in proc-macro crate

Reports public items located in the root of a procedural macro crate and not marked with a #[proc_macro], #[proc_macro_attribute], or #[proc_macro_derive] attribute.

Re-export of a private item

Reports private items that were re-exported publicly.

Redundant `#[must_use]`

Checks for a #[must_use] attribute without further information on functions and methods that return a type already marked as #[must_use].

Redundant `::`

Reports redundant ::.

Redundant `else`

Detects else-statements preceded by irrefutable patterns.

Redundant semicolons

Detects unnecessary trailing semicolons.

Reference dropped

Reports calls to std::mem::drop with a reference instead of an owned value.

Repeated discriminant value

Reports discriminant values that are present more than once in a single enum.

Repeated identifier in pattern

Reports identifiers bound more than once in the same pattern.

Reserved keyword used as an identifier

Reports the use of reserved keywords.

Reserved lifetime name

Reports the use of reserved lifetime names.

Rust 2018 edition violation

Reports the use of keywords reserved in Rust 2018 edition, as well as features unavailable in Rust 2018 edition.

Rust 2024 edition violation

Reports the use of keywords reserved in Rust 2024 edition, as well as features unavailable in Rust 2024 edition.

Self convention

Checks some naming conventions for methods.

Static constant naming convention

Checks if static constant names follow the Rust naming convention.

Struct inheritance (unsupported)

Reports struct inheritance, which is not supported in Rust.

Struct naming convention

Checks if struct names follow the Rust naming convention.

Supertrait is not implemented

Reports missing supertrait implementations.

Suspicious assignment

Detects use of the non-existent =*, =! and =- operators that are probably typos.

Trait expected

Reports non-trait items referenced as traits.

Trait implementation issue

Reports errors in trait implementation like "Missing members", "Unknown member", etc.

Trait naming convention

Checks if trait names follow the Rust naming convention.

Trait safety mismatch

Reports mismatches between the safety of a trait's definition and its implementation.

Tuple-like union

Reports union declarations with tuple syntax.

Type alias naming convention

Checks if type alias names follow the Rust naming convention.

Type checker

The Rust type checker.

Type checker (experimental)

The Rust type checker (experimental).

Type does not implement trait

Reports the use of types that do not implement the necessary traits.

Type does not implement trait (experimental)

Reports the use of types that do not implement the necessary traits.

Type mismatched the trait's associated type.

A type mismatched an associated type of a trait.

Type parameter naming convention

Checks if type parameter names follow the Rust naming convention.

Type placeholder used in item signature

Reports the use of type placeholders (_) in an item's signature.

Unclosed text literal

Reports unclosed text literals.

Undeclared label

Reports undeclared labels.

Undeclared lifetime name

Reports undeclared lifetimes.

Union expression fields count

Checks that union expr has exactly one field.

Unknown crate types

Detects an unknown crate type found in a crate_type attribute.

Unlabeled `continue`/`break` in `while` loop condition

Reports the use of `break`/`continue` keywords without labels in `while` loop conditions.

Unlabeled `continue`/`break` in labeled block

Reports the use of unlabeled `break`/`continue` statements inside labeled blocks.

Unnecessary cast

Detects unnecessary as casts.

Unnecessary lifetime annotations

Checks for lifetime annotations which can be removed by relying on lifetime elision.

Unnecessary path prefix

Detects unnecessarily qualified paths.

Unnecessary return

Reports unnecessary return statements at the end of a block.

Unnecessary visibility qualifier

Reports unnecessary visibility qualifiers.

Unreachable label

Reports unreachable labels.

Unreachable patterns

Checks that match expression doesn't have unreachable patterns.

Unresolved method

Reports unresolved method references.

Unresolved method (experimental)

Reports unresolved method references.

Unresolved path

Reports unresolved path references.

Unresolved path (experimental)

Reports unresolved path references.

Unsafe CString pointer

Detects unsafe usage of CString.

Unsafe inherent implementation

Reports inherent implementations marked as unsafe.

Unsafe item in safe context

Reports the use of unsafe items in a safe context.

Unsafe module

Reports modules declared as unsafe.

Unstable item

Reports the use of unstable items.

Unsupported `let` expression

Reports `let` expressions in places where they are unsupported.

Unused `#[must_use]`

Detects unused result of a type flagged as #[must_use].

Unused `mut` modifier

Detects unnecessary mut qualifiers.

Unused labels

Detects labels that are never used.

Unwrap can be replaced with `?`

Reports calls to `unwrap()` that can be replaced with `?`.

Use of `dyn`/`impl Trait` in type parameter bounds

Reports the use of `dyn` and `impl Trait` in type parameter bounds.

Use of increment/decrement operator (unsupported)

Reports the use of `++` and `--` operators, which are not supported in Rust.

Variable naming convention

Checks if variable names follow the Rust naming convention.

Variadic parameters for non-C ABI function

Reports C-variadic functions that do not use a compatible calling convention.

Wrong associated type arguments

Checks if correct associated type arguments were used for a type or a trait reference.

Wrong number of generic arguments

Checks if the right number of generic arguments was used for a type, trait, function call or method call.

Wrong number of lifetime parameters

Checks if the right number of lifetime parameters was used for a type or trait.

Wrong number of type or const parameters

Checks if an attempted implementation of a trait method or an associated type has the right number of type or const parameters.

`#[dbg]` usage

Reports usages of dbg! macro.

`#[derive]` not allowed

Reports `derive` attributes applied to items other than structs, enums, or unions.

`#[inline]` not allowed

Reports `inline` attributes applied to items other than functions or closures.

`#[repr(inttype)]` missing for enum

Reports enums that require a `#[repr(inttype)]` attribute.

`Copy` type dropped

Reports calls to std::mem::drop with values that derive the Copy trait.

`Sized`/`Unsized` trait implemented explicitly

Reports explicit implementations of the `Sized` and `Unsized` traits.

`ToString` should not be implemented directly

Detects implementations of ToString trait which, as its documentation states, shouldn't be implemented directly and Display trait should be implemented instead.

`_` on the right-hand side of assignment

Reports invalid use of underscores (`_`) in expressions: they are only allowed on the left-hand side of an assignment.

`async` non-`move` closure with parameters (unsupported)

Reports the use of `async` non-`move` closures with parameters for Rust 1.76 or earlier versions that do not support it.

`compile_error!` macro

Highlights `compile_error!()` macro invocation.

`continue`/`break` used outside `loop`/`while`

Reports the use of `break`/`continue` keywords outside `loop`/`while` blocks.

`crate` in paths

Reports `crate` used in paths.

`default` qualifier not allowed

Reports invalid `default` keyword placement.

`extern crate self` missing `as <name>`

Reports `extern crate self` that is not followed by `as <name>`.

`if` condition is constant

Reports if expressions that have true or false constant literal condition and can be simplified.

`impl Trait` not allowed

Reports incorrect use of `impl Trait`.

`impl` member order differs from trait

Checks if members in the impl have a same order as in the trait.

`main` function with generic parameters

Reports `main` functions defined with generic parameters.

`println!` macro can be simplified

Detects usages of println!("") which can be simplified to println!() since from Rust 1.14.0.

`return` can be lifted

Reports if and match statements that can be converted to expressions by lifting a return out.

`return` must have a value

Reports `return;` statements contained in functions whose return type is not `()`.

`self` function parameter not allowed

Reports the use of `self` as a function parameter in case it is not allowed.

`self` in static method

Reports the use of the `self` keyword in static methods.

`self` unavailable in context

Reports the use of `self` in contexts where it is not available.

`self`/`super` misplaced in path

Reports the use of `self` and `super` keywords not at the beginning of the path.

`thread_rng().gen()` can be replaced with `random()`

Detects usage of thread_rng().gen() that can be replaced with random() from rand crate.

`try!` macro usage

Finds usages of the try! macro which can be replaced with ? operator starting from Rust 1.13.0.

`while true` can be replaced with `loop`

Detects while loops which can be replaced with loop.

`with` call can be replaced with thread local stable method

Detects usages of LocalKey::with() method that can be replaced with stable thread local methods.

SQL

Name

Description

Adding not null column without default value

Reports attempts to create NOT NULL columns without DEFAULT values.

Aggregate-related problems

Reports invalid usages of SQL aggregate functions.

Ambiguous reference

Reports columns that have identical names but belong to different tables.

Auto-increment duplicate

Reports tables that contain two columns with an automatic increment.

Builtin functions

Reports truncations of string arguments in ISNULL functions.

Check using clause columns

Reports columns in the USING clause that does not exist in both tables.

Column is shadowed by alias

Reports SELECT aliases with names that match column names in the FROM clause.

Column should be in group by clause

Reports columns that are not in the GROUP BY clause or inside an aggregate function call.

Constant expression

Reports conditions and expressions that are always true, false or null.

Current console schema introspected

Reports schemas and databases in the current session that are not introspected.

Delete or update statement without where clauses

Reports usages of DELETE or UPDATE statements without WHERE clauses.

Deprecated type

Reports usages of types that are deprecated and might disappear in future versions of DBMS.

Duplicating column name in SELECT

Reports duplicated names of column aliases in SELECT lists.

Each derived table should have alias

Reports derived tables without aliases.

Excessive JOIN count

Reports queries with excessive number of JOINS.

Function signature

Reports signature issues for built-in functions.

Identifier should be quoted

Reports situations when you use SQL reserved keywords as identifier names in your query.

Illegal cursor state

Reports illegal cursor states inside SQL routines.

Implicit string truncation

Reports variables that exceed the defined length in characters.

Index is dependent on column

Reports cases when you try to drop columns from indexed tables.

Insert NULL into NOT NULL column

Reports cases when you insert NULL values into columns that accept only NOT NULL values.

Insertion into generated columns

Reports INSERT statements that assign values to generated columns.

Misleading references

Reports ambiguous references in SQL code.

Missing column aliases

Reports queries without explicit aliases in output expressions (for example, in the SELECT statement).

Missing return statement

Reports functions that have no RETURN statements.

Multiple row limiting/offset clauses in queries

Reports usages of multiple row limiting clauses in a single query.

Named arguments should be used

Reports arguments that are used without names in routine calls.

No data sources configured

Reports the absence of data sources in the Database tool window (View | Tool Windows | Database).

Null comparison

Reports comparisons with NULL that can be replaced with IS NULL or IS NOT NULL operators.

ORDER BY in queries

Reports usages when the ORDER BY clause is used without TOP, OFFSET, or FOR XML in views, inline functions, derived tables, subqueries, and common table expressions.

Postgres: Select from procedure call

Reports situations when you make SELECT from a function or a DBLINK without an alias with a type (for example, AS t1(s VARCHAR)).

Redundant ELSE NULL clause

Reports redundant ELSE NULL clauses.

Redundant alias expressions

Reports alias expressions that duplicate names of columns in tables and might be redundant.

Redundant code in COALESCE call

Reports all the arguments except for the first expression that does not evaluate to NULL in COALESCE functions.

Redundant ordering direction

Reports redundant ordering directions like ASC and DESC in ORDER BY clauses.

Redundant row limiting in queries

Reports redundant row limiting clauses like FETCH and LIMIT in queries.

Review dbt project configuration

Reports the misconfigured dbt project (Settings | Languages & Frameworks | dbt).

SQL dialect detection

Reports situations when a dialect is not assigned to an SQL file.

SQL source modification detection

Reports situations when source code of a database object has been changed.

Suspicious code in triggers

Reports incorrect usages of transition table variables in triggers.

Types compatibility

Reports type-related errors.

Unicode usage in SQL

Reports string literals that use national characters without the N prefix.

Unsafe 'join' clause in 'delete' statement

Reports missing conditional checks for statements that might modify the whole database.

Unused common table expression

Reports unused common table expressions (CTE) inside the query.

Unused subquery item

Reports columns, aliases, and other subquery items that are not referenced in the outer query expression.

Unused variable

Reports unused arguments, variables, or parameters.

Usages of GOTO statements

Reports usages of backward GOTO statements and GOTO statements used to exit a loop.

Use of transaction management statements in triggers

Reports usages of transaction management statements like COMMIT or ROLLBACK in trigger bodies.

Using CASE instead of COALESCE function and vice versa

Reports situations when CASE and COALESCE calls are interchangeable.

Using CASE instead of conditional function and vice versa

Reports situations when CASE and IF are interchangeable.

Using of named and positional arguments

Reports calls in which positional arguments go after the named ones.

VALUES clause cardinality

Reports situations when a number of parameters in VALUES does not match a number of columns in a target table.

Scss

Name

Description

Unresolved placeholder selector

Reports an unresolved Sass/SCSS placeholder selector reference.

Shell script

Name

Description

ShellCheck

Reports shell script bugs detected by the integrated ShellCheck static analysis tool.

Spel

Name

Description

Incorrect Spring Expression Language (SpEl) syntax

Reports syntax errors in the Spring Expression Language (SpEL) code, such as unresolved references and invalid locations.

Spring-mongodb-json

Name

Description

Spring Data MongoDB JSON unresolved fields

Reports unresolved document fields specified inside of org.springframework.data.mongodb.repository.Query annotation.

Sqldatetime

Name

Description

Ill-formed date/time literals

Reports errors in date and time literals.

Tftpl

Name

Description

No template data language selected

Reports Terraform Template files with no data language selected.

Thymeleafexpressions

Name

Description

Thymeleaf Dialect Extensions errors

Reports incorrect elements in Thymeleaf Dialect Extension <dialect> files:.

Unresolved message resource keys

Reports unresolved message resource keys.

Unresolved references in Thymeleaf expression variables

Reports unresolved references and invalid Thymeleaf expressions.

Toml

Name

Description

Crate not found

Reports any unknown crates listed in Cargo.toml.

Cyclic feature dependency

Detects features that depend on themselves.

Duplicate key

Reports duplicated keys within the same section of a Cargo.toml file.

Invalid crate version

Reports invalid crate versions in Cargo.toml.

Invalid package category

Checks the categories field in the [package] section of Cargo.toml against the crates.io rules: The categories must be chosen from the list of valid category slugs A maximum of 5 categories is allowed.

Newer crate version available

Reports outdated crate versions in Cargo.toml.

Poetry package versions

Reports outdated versions of packages in [tool.poetry.dependencies] and [tool.poetry.dev-dependencies] sections of pyproject.toml.

Schema violation

Reports errors in Cargo.toml related to structure, constraints, and data types.

Unclosed string literal

Reports string literals that are missing a closing quote.

Unused dependency

Detects crates that are not used in the project's source code.

Unused version catalog entry

Detects unused keys in TOML descriptors of version catalogs.

TypeScript

Name

Description

Abstract class constructor can be made protected

Reports a public constructor of an abstract class and suggests making it protected (because it is useless to have it public).

Assigned constructor field parameter

Reports a common mistake in TypeScript code, when a class field is declared as a constructor parameter, and then this parameter is assigned.

Duplicate union or intersection type component

Reports a duplicate type inside a union or intersection.

Equality operator may cause type coercion

Reports a usage of equality operators may cause unexpected type coercions.

Explicit types

Reports a type annotation that doesn't match the current code style for explicit types.

Field can be readonly

Reports a private field that can be made readonly (for example, if the field is assigned only in the constructor).

Incorrect component template definition

Reports a component that doesn’t have an associated template or uses both template and templateUrl properties.

Incorrect generic type argument

Reports an invalid type argument in a function, interface, or class declaration.

Invalid entry component

Reports an invalid Angular component specified in the module’s bootstrap or entryComponents property.

Invalid imported or declared symbol

Reports any symbol that is declared, imported or exported by an Angular module or standalone component that is not a module, component, directive, or pipe or can’t be used in the context of the property.

Invalid usage of imports in non-standalone components

Reports usages of imports property in non-standalone component decorators.

Missing augmentation import

Reports a usage from augmentation module without an explicit import.

Missing global library

Reports a TypeScript library file that is required for a symbol but is not listed under the lib compiler option in tsconfig.json.

Missing or invalid component, directive or pipe declaration in a module

Reports a non-standalone Angular component, directive, or pipe that is not declared in any module or is declared in multiple modules.

Missing tsconfig.json option

Reports a usage that requires an explicit option in tsconfig.json.

Narrowed type

Reports a usage of a variable where the variable type is narrowed by a type guard.

Recursive import or export of an Angular module or a standalone component

Reports a cyclic dependency between Angular modules or standalone components.

Redundant type arguments

Reports a type argument that is equal to the default one and can be removed.

TSLint

Reports a discrepancy detected by the TSLint linter.

Type mismatch

Reports a parameter, return value, or assigned expression of incorrect type.

Undefined export from Angular module

Reports an export of an undeclared or unimported component, directive, or pipes from an Angular module.

Unresolved TypeScript reference

Reports an unresolved reference in TypeScript code.

Unresolved imported name

Reports an unresolved name or binding in an import declaration in TypeScript code.

Unused import in an Angular component declaration

Reports unused imports in Angular components.

UAST

Name

Description

'@RunWith' annotation already exists in a parent class

Reports when parent and child classes in a JUnit test hierarchy are annotated with @RunWith.

'UastHintedVisitorAdapter' hints problems

Reports missing or redundant hints in UastHintedVisitorAdapter creation.

'assertEquals()' between objects of inconvertible types

Reports calls to assertion methods where the "expected" and "actual" arguments are of incompatible types.

'assertEquals()' called on array

Reports JUnit assertEquals() calls with arguments of an array type.

'assertEquals()' may be 'assertSame()'

Reports JUnit assertEquals() calls that can be replaced with an equivalent assertSame() call.

@Cacheable self-invocation method calls

Using @Cacheable: In proxy mode (which is the default), only external method calls coming in through the proxy are intercepted.

@Configuration proxyMethods usage warnings

Reports warnings on incorrectly used proxy methods.

@Interceptor class without binding types

Reports @Interceptor classes without binding types.

@PreFilter/@PreAuthorize/@PostFilter self-invocation method calls

Using @PreFilter/@PostFilter/@PreAuthorize: In proxy mode (which is the default), only external method calls coming in through the proxy are intercepted.

@Transactional self-invocation method calls

Using @Transactional: In proxy mode (which is the default), only external method calls coming in through the proxy are intercepted.

A service can be converted to a light one

Reports classes that can be marked as light services using the @com.intellij.openapi.components.Service annotation instead of being registered as services in plugin.xml A service that is not intended for overriding is not required to be registered in the plugin.xml file.

API must already be removed

Reports declarations marked with @ApiStatus.ScheduledForRemoval that should have been removed in the current version of the declaring library.

Accessible context is missing

Reports Swing components that do not provide accessibility context.

Application service assigned to a static final field or immutable property

Reports assignments of application services to static final fields / immutable properties.

Association field marked with @Colum

Detects incorrect use of @Column annotation for association attributes with @OneToOne and @ManyToOne annotations.

Bean has collision of scope in stereotypes

Reports classes with multiple stereotypes in different scopes or if a scope is not specified.

Bean with non-default scope declares public fields

Reports managed beans with public instance fields that are not in the default @Dependent scope.

Bootstrap configuration included in application context

Reports BootstrapConfiguration included into the Spring Boot application context via a component scan where it might not be needed.

Cache* annotations defined on interfaces/interface methods

Reports @Cache* annotations on interfaces.

Calculate Kotlin and Java code metrics

Counts the number of code lines.

Call to 'System.getProperty(str)' could be simplified

Reports the usage of method System.getProperty(str) and suggests a fix in 2 cases: System.getProperty("path.separator") -> File.pathSeparator System.getProperty("line.separator") -> System.lineSeparator() The second one is not only less error-prone but is likely to be faster, as System.lineSeparator() returns cached value, while System.getProperty("line.separator") each time calls to Properties (Hashtable or CHM depending on implementation).

Call to 'Thread.run()'

Reports calls to run() on java.lang.Thread or any of its subclasses.

Call to 'equals()' or 'hashCode()' on 'URL' object

Reports hashCode() and equals() calls on java.net.URL objects and calls that add URL objects to maps and sets.

Calling 'subscribe' in "reactive" methods

Reports subscribe() calls in "reactive" methods.

Calling method should be annotated with @RequiresBlockingContext

Highlights calls of method annotated with @RequiresBlockingMethod inside non-annotated method.

Calling transformation function on receiver with Mono<Void> type

Reports transform operations called on Mono<Void> value inside a Reactor chain.

Cancellation check in loops

Reports loops, forEach-like methods, and ContainerUtil.process() with missing cancellation checks.

Cancellation exception handled incorrectly

Reports ProcessCanceledException and CancellationException handled incorrectly.

Check Kotlin and Java source code coverage

Reports methods and classes whose coverage is below a certain threshold.

Class implements Publisher

Reports classes that directly implement the Publisher interface.

Class implements Subscriber

Reports classes that directly implement the Subscriber interface.

Class, interface, or method should not be extended

Reports classes, interfaces and methods that extend, implement, or override API elements marked with @ApiStatus.NonExtendable.

Component type mismatch

Reports incorrect registration of plugin components (Actions and Components).

Configuration avoidance

(Gradle 4.9+) Detects usage of API that interacts with tasks eagerly.

Deprecated API usage

Reports usages of deprecated classes, fields, and methods.

Deprecated configurations

Detects usage of configuration methods that were deprecated.

Disposer method parameter without producers

Reports disposer methods without the corresponding producer method.

Eager creation of action presentation

Reports any actions that are registered in the plugin.xml file and instantiate the com.intellij.openapi.actionSystem.Presentation object in their constructors.

Empty method

Reports empty methods that can be removed.

Entity attribute is not marked with association annotation

Checks for associations that are not marked with corresponding annotations.

Entity has more than one id attribute.

Checks for multiple id attributes in one entity.

Entity listener problems

Reports the following JPA specification errors:.

Entity listener warnings

Reports entity listener classes without any entity listener methods.

Field blocks intention preview

Reports fields in LocalQuickFix and IntentionAction implementations that prevent intention preview action from functioning properly.

File.equals() usage

Reports usages of java.io.File.equals()/hashCode()/compareTo() methods.

Final declaration can't be overridden at runtime

Reports cases when your code prevents a class from being subclassed by some framework (for example, Spring or Hibernate) at runtime.

For @ManyToMany associations, the REMOVE entity state transition doesn't make sense to be cascaded because it will propagate beyond the link table.

Checks for @ManyToMany associations with the CascadeType.REMOVE attribute.

Hardcoded strings

Reports any instances of hardcoded String literals.

Illegal package dependencies

Reports illegal dependencies between scopes according to the dependency rules given.

Incorrect @Decorator class

Reports incorrect @Decorator bean definitions.

Incorrect @Specializes usage

Reports incorrect usages of the @Specializes annotation.

Incorrect @Stereotype annotation class

Reports incorrect @Stereotype annotation classes:.

Incorrect @Typed annotation usage

Reports @Typed annotation usages that violate the following rules:.

Incorrect MIME Type declaration

Reports incorrect MIME types (for example, in Content-Type strings) for HTTP servers and clients.

Incorrect autowiring in Spring bean components

Reports autowiring problems on injection points of Spring beans @Component, @Service, and so on.

Incorrect bean scope

Reports incorrect bean scopes:.

Incorrect dependency injection place

Reports incorrect injection points: fields, methods, and parameters annotated with @Inject that violate the CDI specification.

Incorrect disposer method

Reports incorrect disposer methods.

Incorrect managed bean definition

Reports incorrect bean definition rules.

Incorrect observer method

Reports incorrect observer method definitions.

Incorrect parentDisposable parameter

Reports using Application or Project as a parent Disposable in plugin code.

Incorrect repository method declaration

Reports Micronaut Data repository methods that do not match the query pattern criteria.

Incorrect repository method parameter

Reports incorrect repository method parameter types.

Incorrect repository method return type

Reports incorrect Micronaut Data repository method return types.

Incorrect required cache names definition

Reports incorrect @Cache* annotation names.

Incorrect service retrieving

Reports the following problems when retrieving services: Attempts to retrieve an unregistered service.

Incorrect string capitalization

Reports strings in method parameters and return values annotated with @Nls and having the capitalization parameter to conform to capitalization rules existing in most platform UI guidelines.

Incorrect usage of @CachePut and @Cacheable on the same method

Reports @CachePut and @Cacheable annotations declared on the same method.

Incorrect usage of bean type that cannot be proxied

Reports incorrect usages of bean types that cannot be proxied.

Incorrect use of @Find annotation

Reports Hibernate @Find annotation errors.

Incorrectly configured @EventListener methods

Reports incorrect @EventListener methods.

Incorrectly configured @Profile expression

Reports incorrect @Profile expressions:.

Injection point with ambiguous dependencies

Reports injection points in bean classes that have ambiguous dependencies.

Inspection suppression annotation

Reports comments or annotations suppressing inspections.

Invalid 'PlatformTransactionManager' declaration in @Transactional component

Reports PlatformTransactionManager classes that are not correctly defined in the application context for the current @Transactional component.

Invalid @ConfigurationProperties

Reports invalid prefixes defined in the @ConfigurationProperties annotations:.

Invalid @ContextConfiguration

Reports incorrect Spring context configurations.

Invalid @Sql and @SqlGroup configurations

Reports unresolved file references in the scripts attributes of the @Sql annotation and the corresponding aliased attributes of the @Sql meta annotations.

Invalid Spring Boot application setup

Reports @SpringBootApplication in the default package and redundant @EnableAutoConfiguration or @ComponentScan annotations.

Invalid icon path in @Presentation

Reports invalid and deprecated value for icon attribute in com.intellij.ide.presentation.Presentation annotation.

Invalid package in @ComponentScan or its meta annotation

Reports unresolved packages in @ComponentScan annotations and corresponding aliased attributes of @ComponentScan meta annotations.

JPA converter must be annotated with @Converter annotation

Checks for the presence of @Converter annotation on JPA converter.

JUnit 3 'super.tearDown()' is not called from 'finally' block

Reports calls of the JUnit 3's super.tearDown() method that are not performed inside a finally block.

JUnit 3 test can be JUnit 4

Reports JUnit 3 test classes that can be converted to JUnit 4 test classes.

JUnit 4 test can be JUnit 5

Reports JUnit 4 tests that can be automatically migrated to JUnit 5.

JUnit 5 obsolete assertions

Reports any calls to methods from the junit.framework.Assert, org.junit.Assert, or org.junit.Assume classes inside JUnit 5 tests.

JUnit assertion can be 'assertThat()' call

Reports calls to Assert.assertEquals(), Assert.assertTrue(), etc.

JUnit malformed declaration

Reports JUnit test member declarations that are malformed and are likely not recognized by the JUnit test framework.

JUnit test annotated with '@Ignore'/'@Disabled'

Reports usages of JUnit 4's @Ignore or JUnit 5's @Disabled annotations.

Jakarta Data repository method errors

Reports Jakarta Dat repository methods for which the builder cannot generate the corresponding query.

Log condition does not match logging call

Reports is log enabled for conditions of if statements that do not match the log level of the contained logging call.

Logging call not guarded by log condition

Reports logging calls that are not surrounded by a guard condition.

Logging calls guarded by log condition

Reports logging calls surrounded with a guard condition.

Lombok @Builder needs a proper constructor for this class

Checks that all-args constructor exists for @lombok.Builder in JPA entities.

Map key may leak

Reports using Language or FileType as a map key in plugin code.

Method always returns the same value

Reports methods and method hierarchies that always return the same constant.

Method can only be overridden

Reports calls to API methods marked with @ApiStatus.OverrideOnly.

Method parameter always has the same value

Reports method parameters that always have the same constant value.

Migrate to getOptionPane()

Reports createOptionsPanel() methods in inspection implementation, which can be automatically converted to getOptionsPane().

Mismatch in @PathVariable declarations and usages

Reports @PathVariable parameters that are declared in the method signature but are absent in the URL path or vice versa.

Missing '@Deprecated' annotation on scheduled for removal API

Reports declarations marked with @ApiStatus.ScheduledForRemoval without @Deprecated.

Missing or empty 'prefix' attribute value in the '@ConfigMapping' annotation

Reports missing or empty prefix attribute value in the @io.smallrye.config.ConfigMapping annotation.

Non-default constructor in serializable class

Reports non-default constructor in serializable classes.

Non-default constructors for service and extension class

Reports extension/service class having a non-default (empty) constructor.

Non-distinguishable logging calls

Reports SLF4J, Log4j2 logging calls in one class, such as logger.info("message: {}", key) with similar log messages.

Non-platform TokenSet declared in ParserDefinition

Reports TokenSet field declarations referencing non-platform element types in ParserDefinition classes.

Non-safe string is passed to safe method

Reports cases when a non-safe object is passed to a method with a parameter marked with @Untainted annotations, returned from annotated methods or assigned to annotated fields, parameters, or local variables.

Non-safe string is used as SQL

Reports cases for Java and Kotlin languages when a non-safe string is passed to a method as a SQL query.

Number of placeholders does not match number of arguments in logging call

Reports SLF4J, Log4j2 and akka.event.LoggingAdapter logging calls, such as logger.info("{}: {}", key) where the number of {} placeholders in the logger message doesn't match the number of other arguments to the logging call.

Persistent attribute signature checks

Reports the following JPA specification errors:.

Persistent attribute type checks

Reports property type mismatch for JPA attributes.

Persistent entity misses primary key

Reports missing identification property persistence objects.

Persistent object class signature checks

Reports incorrectly defined persistent object classes in the following cases:.

Plugin DSL structure

Detects disallowed statements before 'plugins {}' block.

Possibly blocking call in non-blocking context

Reports thread-blocking method calls in code fragments where threads should not be blocked.

Possibly misplaced call to Gradle method

Detects possibly misplaced calls to Gradle methods.

Potential deadlock in service initialization

Reports read/write actions and invokeAndWait called from the scope of service initialization: service constructors and initialization blocks (including static) service companion object's initialization blocks (Kotlin) service methods used in initialization blocks and fields initialization PersistentStateComponent initialization lifecycle methods: loadState noStateLoaded initializeComponent Running a read/write action or calling invokeAndWait during service initialization may cause deadlocks.

Query returning Page must have a Pageable parameter.

Verifies that a Pageable parameter is present in queries returning Page.

QuickFix's getFamilyName() implementation must not depend on a specific context

Reports QuickFix.getFamilyName() using contextual information.

Return null or something nullable from a lambda in transformation method

Reports transform operations that may return null inside a Reactive Stream chain.

Serializable class without 'serialVersionUID'

Reports classes that implement Serializable and do not declare a serialVersionUID field.

Simplifiable service retrieving

Reports service getting calls that can be replaced with a calls to an existing static getInstance() or getInstance(Project) methods.

Specifying FetchType.LAZY for the non-owning side of the @OneToOne association will not affect the loading. The related entity will still be loaded as if the FetchType.EAGER is defined.

Checks for the non-owning side of the @OneToOne associations with the FetchType.Lazy attribute.

Spring Data repository method errors

Reports Spring Data CRUD repository methods for which the Spring Data Query builder cannot generate the corresponding query.

Spring Data repository method parameters errors

Reports Spring Data CRUD repository method parameters with incorrect types.

Spring Data repository method return type errors

Reports Spring Data CRUD repository methods with incorrect return types.

Stateful extension

Reports extensions and quick-fixes holding potentially leaking state.

Static initialization in extension point implementations

Reports static initialization in extension point implementations.

Stream handler method error

Reports inconsistency errors in stream handler methods.

String template as argument to logging call

Reports string templates that are used as arguments to SLF4J and Log4j 2 logging methods.

Suspicious Hooks.onOperatorDebug() usage

Reports the usage of Hooks.onOperatorDebug() when ReactorDebugAgent.init() is called.

Test class without tests

Reports non-abstract test cases without any test methods.

Test in product source

Reports test classes and test methods that are located in production source trees.

Test method without assertions

Reports test methods that do not contain any assertions.

Test-only usage in production code

Reports @TestOnly- and @VisibleForTesting-annotated methods and classes that are used in production code.

TestCase with non-trivial constructors

Reports test cases with initialization logic in their constructors.

Threading and concurrency problems

Reports threading and concurrency issues in code using information from com.intellij.util.concurrency.annotations annotations.

Throw statement in Reactive operator

Reports throw expressions in the Reactor/RxJava operator code.

Too long same methods chain

Reports long Reactive Streams transformation chains.

UElement as PsiElement usage

Reports usage of UAST UElement as PsiElement.

Undeclared '@Produces' / '@Consumes' MIME types for '@Path'

Reports endpoint methods without the @Produces or @Consumes annotations.

Undesirable class usage

Reports usages of undesirable classes (mostly Swing components).

Unfinished StepVerifier

Reports missing StepVerifier terminal calls.

Unknown HTTP header

Reports unknown HTTP headers that do not match any publicly known headers.

Unknown init/destroy method in the @Bean annotation

Reports unresolved method references on initMethod and destroyMethod parameters of the @Bean annotation.

Unnecessary debug initialization

Reports redundant ReactorDebugAgent.init() calls.

Unrecognized dependency notation

Detects incorrect dependency notations.

Unresolved @PathParam reference

Reports @PathParam parameters that are declared in a method signature and missing in the URL path or visa versa.

Unresolved @PathVariable reference

Reports @PathVariable parameters that are declared in a method signature and missing in the URL path or vise versa.

Unresolved cache annotation parameter reference

Reports Micronaut Cache annotations where the value of the parameters attribute contains names of undefined method parameters.

Unresolved database references in annotations

Reports references inside the following Persistence ORM annotations if they cannot be resolved within the configured datasource:.

Unresolved entity graph names

Reports the following unresolved attributes inside EntityGraph-related annotations:.

Unresolved file references in @ImportResource locations

Reports unresolved files and directories in locations attributes of @ImportResource annotations and the corresponding aliased attributes of the @ImportResource meta annotations.

Unresolved file references in @PropertySource and @TestPropertySource locations

Reports unresolved files or directories in @PropertySource and @TestPropertySource annotations.

Unresolved message channel

Reports unresolved channel attributes in @StreamListener, @SendTo, @Output, and @Input annotations.

Unresolved plugin configuration reference

Reports unresolved references to plugin configuration elements.

Unresolved queries and query parameters

Reports unresolved symbols in named and native queries and related API methods: Unknown named query Unknown query parameter Example: @Entity @NamedQuery(name = "SelectByConditionQuery", query = "...") public class JavaEntity { ..

Unresolved references in queries

Reports unresolved symbols in the following JPA annotations and API methods:.

Unresolved view reference

Reports unresolved Spring MVC View references.

Unsafe VFS recursion

Reports usage of VirtualFile.getChildren() inside recursive methods.

Unsafe return statements visitor

Reports unsafe use of JavaRecursiveElementVisitor.visitReturnStatement().

Unspecified action place

Reports passing unspecified place parameter for ActionManager.createActionToolbar() and ActionManager.createActionPopupMenu().

Unstable API Usage

Reports usages of an API marked with one of the annotations as unstable.

Unstable type is used in signature

Reports declarations of classes, methods, and fields that reference an unstable API type in the signature, but are not marked with the same unstable annotation.

Unsupported character

Reports characters in property files that are unsupported by the ISO-8859-1 charset when Java 1.8 or earlier is used.

Unused publisher

Reports unused Publisher instances.

Update/Delete queries must be annotated with @Modifying, otherwise an InvalidDataAccessApiUsageException will be thrown.

Checks that delete/update queries are annotated with the @Modifying annotation.

Usage of API marked for removal

Reports usages of deprecated APIs (classes, fields, and methods) that are marked for removal with @Deprecated(forRemoval=true).

Usage of IntelliJ API not available in older IDEs

Reports usages of IntelliJ Platform API introduced in a version newer than the one specified in <idea-version> @since-build in plugin.xml.

Usages of API which isn't available at the configured language level

Reports usages of the API that is unavailable at the configured language level.

Usages of ApiStatus.@Obsolete

Reports declarations (classes, methods, fields) annotated as @ApiStatus.Obsolete.

Use 'PluginId#equals(Object)'

Reports comparing PluginId instances using ==.

Use 'PsiType#equals(Object)' with primitive types

Reports comparing PsiPrimitiveType instances using ==.

Use 'VirtualFile#equals(Object)'

Reports comparing VirtualFile instances using ==.

Use DPI-aware borders

Reports usages of javax.swing.border.EmptyBorder and JBUI.Borders.emptyXyz() that can be simplified.

Use DPI-aware insets

Reports usages of java.awt.Insets and JBUI.insetsXyz() that can be simplified.

Use Darcula aware JBColor

Reports usages of java.awt.Color.

Using @AllArgsConstructor for JPA entities without defined no-argument constructor breaks JPA specification.

Checks that @lombok.AllArgsConstructor used in JPA entities.

Using @Builder for JPA entities without defined no-argument constructor breaks JPA specification.

Checks that @lombok.Builder used in JPA entities.

Using new Color(a,a,a)

Reports usages of java.awt.Color to create gray colors.

Vetoed @Alternative bean

Reports vetoed @Alternative beans.

Wrong access modifier of bean members with CDI annotations

Reports injected fields, observer methods, and bean constructors with private access.

Zip contains parameter with Mono<Void> type

Reports zip operations that contains arguments with Mono<Void> return value inside a Reactor chain.

VTL

Name

Description

Directive arguments inspection

Reports illegal values or argument types of Velocity directives.

File references inspection

Reports if Velocity file references in #include and #parse directives are resolved incorrectly.

References inspection

Reports if Velocity references are resolved incorrectly.

Types inspection

Reports if binary and unary expressions have operands with incorrect types.

Well-formedness inspection

Reports illegal usages of formal notation within #macro and #set directives.

Vue

Name

Description

Data function

Reports a Vue component data property that is not a function.

Duplicate template/script tag

Reports multiple usages of the template or script tag in a Vue file.

Missing component import

Reports Vue components, which require to be imported in Vue templates.

Unrecognized directive

Reports an unrecognized Vue directive.

Unrecognized slot

Reports an unrecognized Vue slot.

Webhelpxml

Name

Description

Combinable elements

Detects elements that can be combined.

Element filter shadowed by ancestors

Detects content filters that are shadowed by filters of parent elements.

Element without an 'id' attribute

Highlights elements that don't have the id attribute.

Empty code block

Detects empty code blocks and empty source code files.

File glossary.xml not found

Suggests creating glossary.xml when tooltip used, but glossary.xml not listed.

Format element checker

Checks the <format> element style and color validity.

GIF can be replaced with video

Checks if there is an MP4 video to replace an animation with.

Include uses 'filter' instead of 'use-filter'

Detects includes with the filter attribute instead of use-filter.

Incorrect label ID

Detects incorrect references to <primary-label> and <secondary-label> identifiers.

Invalid filter value

Reports problematic filter declarations that may result in unexpected behavior: Explicit empty values in filter attributes Redundant or misplaced negation ! operators.

Large image without a thumbnail

Detects large images without a thumbnail and suggests making them expandable.

Link to topic not in current instance

Detects links pointing to an existing topic that is not in the current help instance tree.

Missing alt attribute inspection

Detects <img> elements without the alt attribute.

Missing space

Detects the absence of whitespace characters around tags.

Missing title

Checks for missing title attribute in chapter, def, and tab elements.

Non-empty code block uses source file

Detects non-empty code blocks that also define a valid source file via the src attribute.

Non-latin characters in attribute values

Detects non-Latin characters in attribute values.

Redundant link text

Detects links to topics where the topic title matches the link text.

Root file tag must have an 'id' attribute

Detects missing or incorrect topic IDs in XML files.

Topic not in current instance

Warns you when the topic currently open in the editor is not in the current help instance.

Unexpected media file type

Detects media references that do not match their expected media types, for example, image references in <video> tags and videos in image elements.

Unreachable external image

Detects unreachable URLs to external images.

Unreachable external link

Detects unreachable external links.

Unreachable external video

Detects unreachable URLs to external videos.

Unsupported language in code block

Detects unsupported languages in code blocks.

Unused snippet

Detects snippets that are not included anywhere.

Unused topic

Warns you when the topic file is not used anywhere.

Video has no preview image

Detects videos without a preview image.

Wide code block

Detects code blocks with long lines.

XML-like tags in code block

Detects XML-like tags inside <code-block>.

XML

Name

Description

Absolute paths

Reports absolute paths in JSP files.

Anchor is overridden

Detects overridden anchors in XML <a href> links.

Color component is out of range

Reports RGB color components that are out of the valid range.

Conflicting Spring bean attribute

Reports configuration conflicts on <bean> attributes.

Debug mode is activated in the Spring Security configuration

Reports activated <debug> that may expose sensitive information.

Deprecated API usage in XML

Reports usages of deprecated classes and methods in XML files.

Deprecated library is used in Maven

Reports deprecated maven dependency.

Deprecated symbol

Reports a deprecated XML element or attribute.

Duplicate 'id' attribute

Reports a duplicate id attribute in XML.

Duplicate Dependencies

Reports duplicate dependencies.

Duplicate category sort order

Detects non-unique sort order values of <seealso> categories in c.list.

Duplicate changeset's `id` attribute within one file for the same `author`. Adjust the changeset's `author` or `id` value.

Detects duplicate changeset id attributes within one file.

Duplicate plugin declaration

Reports the duplication of the plugin declaration in pom.xml.

Duplicate redirect

Detects duplicate redirects.

Duplicate topic in TOC

Detects topics that are added to the TOC more than once.

Duplicated bean names in XML-based application context

Reports duplicate bean names defined in the application context.

Empty element content

Reports XML elements without contents.

Empty tag

Reports empty tags that do not work in some browsers.

Event handler method signature problems

Reports event handler issues, including incompatible argument types, ambiguous event handler methods, and incorrect return types.

Extension class is a Kotlin object

Reports extensions which are instantiated by the IntelliJ Platform, but are declared as Kotlin objects.

Failed external validation

Reports a discrepancy in an XML file with the specified DTD or schema detected by the Xerces validator.

Hibernate configuration XML is not added to facet

Reports missing Hibernate XML configuration files.

Inactive profile highlighting

Reports inactive profiles in the Spring XML application contexts.

Incompatible kotlinx.coroutines dependency is used with Kotlin 1.3+ in Maven

Reports kotlinx.coroutines library dependencies in Maven that should be updated in order to be compatible with Kotlin 1.3 and later.

Inconsistent injection value in XML application context

Reports inconsistent tags and attributes on injection points in XML application contexts.

Incorrect JDK-proxied bean type

Reports incorrectly configured JDK-proxied bean types.

Incorrect Spring AOP advice or advisor element

Reports incorrect advices and advisor elements if there are no pointcut or pointcut-ref attributes.

Incorrect Spring AOP aspect or pointcut element

Reports incorrect aspects and pointcuts.

Incorrect Spring Core XML-based application context

Reports issues with the Spring Framework XML-based application context:.

Incorrect Spring Integration XML-based application context

Reports issues with the Spring Integration XML-based application context:.

Incorrect Spring Security XML-based application context

Reports issues with the Spring Security XML-based context:.

Incorrect WADL configuration

Reports configuration errors in WADL files.

Incorrect XML Spring bean autowiring

Reports incorrect autowiring of Spring beans configured in XML application contexts.

Incorrect bean definitions in beans.xml

Reports incorrect bean definitions in beans.xml configuration files.

Incorrect constructor injection in XML Spring bean

Reports Spring <bean> using constructor-based dependency injection.

Incorrect declaration

Reports duplicate declarations and illegal identifiers in XSLT variables, parameters, and named templates:.

Incorrect elements in Bean Validation <constraint-mappings> files

Reports incorrect elements in Bean Validation <constraint-mappings> files:.

Incorrect elements in Bean Validation <validation-config> files

Reports incorrect elements in Bean Validation <validation-config> files:.

Incorrect injected bean type

Reports incorrect types of custom schema bean injections defined in the XML application context.

Incorrect non-public method referenced in "factory-method" attribute

Reports non-public methods referenced in the factory-method attributes of <bean> elements.

Incorrect reference to abstract bean

Reports referenced abstract beans.

Incorrect resource type

Reports incorrect files referenced in the XML application context.

Incorrect template invocation

Reports missing arguments, passing arguments that are not declared, and passing arguments for parameters more than once in named XSLT template invocations.

Incorrectly configured 'util' schema beans defined in XML application context

Reports incorrect schema beans defined in XML application contexts.

Incorrectly configured XML bean lookup-method

Reports incorrect <lookup-method> for a bean in XML application contexts.

Incorrectly defined method referenced in "factory-method" attribute

Reports incorrect method references in the factory-method attribute of the <bean> element.

Injection value in XML application context violates conventions

Reports properties configured via <value> or <ref> sub-elements and offers to replace them with the corresponding attributes.

Invalid Hibernate DB-related XML mappings

Reports Hibernate XML configuration DB-related mapping errors including:.

Invalid Hibernate XML configuration

Reports Hibernate XML configuration errors including:.

Invalid Hibernate XML mappings

Reports Hibernate XML configuration mapping errors including:.

Invalid filter definition in XML-based component scans

Reports inconsistent <filter> definitions in <component-scan> of XML application contexts.

Invalid non-abstract bean instantiation

Reports instantiation errors on interface/abstract class <bean> declarations.

JBoss/WildFly

Reports incorrect JBoss-specific XML deployment descriptors:.

Java EE application descriptor correctness

Reports the following problems inside `application.xml` configuration files:.

JavaFX redundant property values

Reports properties in .fxml files (both attributes and tags) that have the default values and therefore are redundant.

JavaFX unused imports

Reports unused imports in .fxml files.

Jsp directive inspection

Reports JSP import directives without a URI or tagdir attributes.

Jsp properties inspection

Reports unresolved properties from *.properties files.

Kotlin Maven Plugin misconfigured

Reports kotlin-maven-plugin configuration issues.

Library and maven plugin versions are different

Reports different Kotlin stdlib and compiler versions.

Live templates i18n

Reports hardcoded text in live template description.

MIME type

Lets you control MIME type name validity.

Malformed content of 'script' tag

Reports contents of script tags that are invalid XML.

Maven Model Inspection

Reports resolution problems in a Maven model.

Maven and IDE plugins versions are different

Reports that Maven plugin version isn't properly supported in the current IDE plugin.

Mismatched image size

Reports a width and height attribute value of a img tag that is different from the actual width and height of the referenced image.

Missing @Required property injections in the spring xml bean declaration

Reports @Required setter bean properties that are not injected or autowired.

Missing associated label

Reports a form element (input, textarea, or select) without an associated label.

Missing request separator in HTML/XML body

Reports possible requests in injected XML/HTML body where request separator ### is missing.

Missing required 'alt' attribute

Reports a missing alt attribute in a img or applet tag or in a area element of an image map.

Missing required 'lang' attribute

Reports a missing lang (or xml:lang) attribute in a html tag.

Missing required 'summary' attribute

Reports a missing summary attribute in a table tag.

Missing required 'title' attribute

Reports a missing title attribute frame, iframe, dl, and a tags.

Missing required 'title' element

Reports a missing title element inside a head section.

Missing required attribute

Reports a missing mandatory attribute in an XML/HTML tag.

Obsolete attribute

Reports an obsolete HTML5 attribute.

Obsolete tag

Reports an obsolete HTML5 tag.

Orm.xml problems

Reports unresolved references to any database objects inside `orm.xml` configuration files:.

Parent version missed

Reports the absence of the parent version element for versions that do not support consumer POM feature.

Persistence.xml is not added to facet

Reports missing persistence.xml configuration files and suggests adding the file to the persistence facet.

Phing inspection

Reports unresolved resource references in Phing build files.

Plugin Logo check

Reports missing plugin logo.

Plugin.xml dynamic plugin verification

Reports dynamic plugin problems.

Plugin.xml extension registration

Reports problems with extension registration in plugin.xml.

Plugin.xml i18n verification

Reports hardcoded texts in plugin.xml.

Plugin.xml text capitalization

Reports text capitalization problems in plugin.xml.

Plugin.xml validity

Reports problems in plugin.xml.

Presentational tag

Reports a presentational HTML tag.

Redirect from existing topic

Detects redirects from web filenames of existing topics.

Redundant TOC title

Detects TOC titles that match the topic title.

Redundant attribute with default value

Reports a redundant assignment of the default value to an XML attribute.

Redundant groupId

Reports the unnecessary <groupId> definition since it is already defined in the parent pom.xml.

Security role name correctness

Reports invalid security role names.

Self-including JSP files

Reports any include directives in a JSP file which refer to the containing JSP file.

Servlet mapping

Reports servlets without associated mappings.

Shadowed variable

Reports shadowed XSLT variables.

Spring Integration 2.1 deprecations

Reports XML elements deprecated in the current version of the Spring Integration XML-based application context.

Spring bean name violates conventions

Reports <bean> names that don't follow the bean naming conventions.

Tag body content type

Reports JSP tag body content that does not conform to the TLD body-content specification.

Tag library descriptor inspection

Reports problems in JSP TLD files.

The value from properties file is incompatible with the attribute type

Reports attribute values defined in a .properties file that do not match the type of the attribute.

Unassignable injection point type in XML application context

Reports invalid injection point types (properties and constructor arguments).

Unbound namespace prefix

Reports an unbound namespace prefix in XML.

Unknown <bean> scope

Reports unknown values of the scope attribute in <bean> elements.

Unnecessary autowired dependency in XML application context

Reports autowire attributes in <bean> elements and suggests to explicitly inject bean properties if possible.

Unnecessary default tag

Reports redundant tags in .fxml files.

Unparsed custom Spring beans

Reports unknown Spring bean types that have not yet been parsed or if a bean uses an unsupported tag for the custom namespace.

Unreachable URL in TOC

Detects external URLs in the table of contents that can't be reached.

Unresolved 'id' reference

Reports an unresolved id reference in XML.

Unresolved DTD reference

Reports inconsistency in a DTD-specific reference, for example, in a reference to an XML entity or to a DTD element declaration.

Unresolved Liquibase property

Detects unresolved Liquibase property usages.

Unresolved database references in XML

Reports Persistence ORM XML descriptors that cannot be resolved within the configured datasource and suggests refreshing the datasource or assigning a different one.

Unresolved file in a link

Reports an unresolved file in a link.

Unresolved fragment in a link

Reports an unresolved last part of an URL after the # sign.

Unresolved fx:id attribute reference

Reports unresolved fx:id references.

Unresolved placeholders configured in the Spring XML application context

Reports unresolved placeholders configured in Spring XML contexts.

Unresolved references

Reports an unresolved references in XML.

Unresolved style class reference

Reports unresolved CSS style classes.

Unresolved web link

Reports an unresolved web link.

Unused schema declaration

Reports an unused namespace declaration or location hint in XML.

Unused variable or parameter

Reports local variables and parameters that are never used.

Usage of properties in parent description

Reports that the usage of properties in modules parent definition is prohibited.

Web.xml errors

Reports the following problems in descriptors that are used to deploy your Web Module to a server:.

Web.xml warnings

Reports duplicated welcome-files listed in the descriptor for deploying a Web Module to a server.

Wrong root element

Reports a root tag name different from the name specified in the <doctype> tag.

XML highlighting

Reports XML validation problems in the results of a batch code inspection.

kotlin-test-junit could be used

Reports usage of kotlin-test and junit dependency without kotlin-test-junit.

persistence.xml problems

Reports the following problems inside XML configuration files:.

Xpath

Name

Description

Hardcoded namespace prefix

Reports comparisons of the name() function with a string that contains a colon (:).

Implicit type conversion

Reports implicit conversions between the predefined XPath-types STRING, NUMBER, BOOLEAN, and NODESET.

Redundant type conversion

Reports unnecessary type conversions.

Unknown element or attribute name

Reports names of elements or attributes that are used in an XPath-expression but are missing in the associated XML files and are not defined in the referenced schemas.

XPath predicate with index 0

Reports usages of 0 in a predicate index or in a comparison with the function position().

Yaml

Name

Description

Cyclic job dependency

Detects cyclic dependencies for jobs in GitHub workflow YML file.

Deprecated Kubernetes resource properties

Reports deprecated keys in Kubernetes resource files.

Deprecated Kubernetes resources

Report deprecated Kubernetes resource types.

Deprecated YAML key

Reports deprecated keys in YAML files.

Duplicated EnvVar definitions

Reports duplicate EnvVars in Kubernetes container definitions.

Duplicated YAML keys

Reports duplicated keys in YAML files.

Invalid Chart.yaml values

Reports unrecognized values in Chart.yaml and requirements.yaml.

Invalid OpenRewrite YAML recipe

Reports OpenRewrite YAML recipe problems.

Invalid Quarkus YAML configuration

Reports deprecated and unresolvable keys and values in Quarkus application YAML configuration files.

Invalid YAML configuration

Reports unresolved and deprecated configuration keys and invalid values in Spring Boot application .yaml configuration files, which can lead to runtime errors.

Invalid action parameters

Reports the absence of mandatory parameters that do not have a default value for an action.

Invalid parameters

Reports the absence of mandatory parameters that do not have a default value for an action.

Ktor application.yaml

Reports deprecated configuration keys and invalid values in Ktor application .yaml configuration files.

Micronaut application.yaml

Reports deprecated configuration keys and invalid values in Micronaut application .yaml configuration files.

Missing Chart.yaml keys

Reports missing required keys in Chart.yaml.

Missing Kubernetes YAML keys

Reports missing required keys in Kubernetes resource files.

Missing docker-compose YAML keys

Reports missing required keys in Docker Compose files.

Missing request separator in YAML body

Reports possible requests in injected YAML body where request separator ### is missing.

Non-editable Kubernetes resource properties

Reports non-editable (read-only) keys in Kubernetes resource files.

Non-editable Kubernetes resources

Reports non-editable (read-only) Kubernetes resource types.

OpenAPI documentation for current module is outdated

Reports that OpenAPI documentation for the current Ktor module is outdated.

Possible OpenAPI/Swagger specification candidate

Detects YAML files that can be interpreted as a part of OpenAPI/Swagger specification.

Recursive alias

Reports recursion in YAML aliases.

Suspicious type mismatch

Reports a mismatch between a scalar value type in YAML file and types of the values in the similar positions.

Undefined action parameters

Reports the presence of parameters which are not defined in an action.

Undefined action reference

Detects unresolved action references in GitHub action and workflow files.

Undefined action/file reference

Detects unresolved action references in GitHub action and workflow files.

Undefined job dependency

Detects dependencies to undefined Jobs in GitHub workflow YML file.

Undefined parameters

Reports the presence of parameters which are not defined in an action.

Unknown Chart.yaml keys

Reports unrecognized keys in Chart.yaml.

Unknown Kubernetes YAML keys

Reports unrecognized keys in Kubernetes resource files.

Unknown Kubernetes YAML values

Reports invalid values in Kubernetes resource files.

Unknown Kubernetes resources

Reports unrecognized Kubernetes resource types.

Unknown docker-compose YAML keys

Reports unrecognized keys in Docker Compose files.

Unknown docker-compose YAML values

Reports unrecognized values in Docker Compose files.

Unquoted port mappings

Reports unquoted port mappings in Docker Compose files.

Unresolved alias

Reports unresolved aliases in YAML files.

Unused anchor

Reports unused anchors.

Validation by JSON Schema

Reports inconsistencies between a YAML file and a JSON Schema if the schema is specified.

Go

Name

Description

'FailNow' in a non-test goroutine

Reports calls to testing.T.FailNow and similar methods located in goroutines in test files.

'Unmarshal' is called with the incorrect argument

Reports calls to json.Unmarshal and similar functions if the argument that is passed to store the result is not a pointer or an interface.

'context.CancelFunc' is not called

Reports execution paths that do not call the cancel function returned by context.WithCancel and similar functions.

'defer' in the loop

Reports defer statements inside loops.

Assignment to a receiver

Reports assignments to method receivers.

Bool condition

Reports parts of boolean expressions that are either always true, always false, or redundant.

Check GO source code coverage

Reports methods and files whose coverage is below a certain threshold.

Comment has no leading space

Reports comments without a leading space.

Comment of exported element starts with the incorrect name

Reports comments that do not start with the name of the exported element.

Constant condition

Reports conditions in code that always evaluate to true or false.

Convert string literals

Reports double-quoted string literals that can be converted into raw string literals and raw string literals that can be converted to double-quoted string literals.

Cyclic imports

Reports cyclic imports.

Data flow analysis

Write your description here.

Defer/go statement calls 'recover' or 'panic' directly

Reports defer and go statements that call panic() or recover() directly.

Direct comparison of errors

Reports direct comparison of errors, for example, using ==, and suggests using errors.Is instead.

Disabled GOPATH indexing

Reports disabled GOPATH indexing that might prevent proper resolution of code references.

Empty declaration

Reports empty declarations.

Empty slice declared using a literal

Reports slice declarations with empty literal initializers used instead of nil.

Error may be not nil

Reports instances where variables might have nil or an unexpected value because of the associated error that is not checked for being non-nil, as in v, err := foo().

Error string should not be capitalized or end with punctuation

Reports format issues in error strings.

Exceeded shift expression

Reports shift expressions that equal or exceed the width of the integer.

Exported element should have a comment

Reports exported declarations without a documentation comment.

Exported element should have its own declaration

Reports exported variables or constants in comma-separated lists of declarations.

Fuzzing is supported starting with Go 1.18

Reports presence of fuzz tests when Go SDK version is less than 1.18.

Imported package name as a name identifier

Reports declarations of variables, arguments or functions that overlap with the used import.

Impossible interface type assertion

Reports impossible interface-to-interface type assertions.

Incorrect 'strings.Replace' count argument

Reports strings.Replace calls with the replace count 0 instead of -1.

Incorrect usage of 'fmt.Printf' and 'fmt.Println' functions

Reports incorrect usages of fmt.Printf, fmt.Println, and similar formatting and printing functions.

Incorrect usage of the 'errors.As' function

Reports calls of the errors.As function when the second argument is not a pointer to an interface or to a type that implements an error.

Incorrect usage of the 'sync/atomic' package

Reports assignment statements of the form x = atomic.AddUint64(&x, 1).

Infinite 'for' loop

Reports empty for loops.

Integer to string type conversion

Reports conversions of string(x)-alike expressions where x is an integer but not byte or rune.

Invalid conversions of 'uintptr' to 'unsafe.Pointer'

Reports possibly incorrect conversions of uintptr to unsafe.Pointer.

Irregular usage of 'iota'

Reports irregular usage of iota within a constant declaration.

Leading whitespace in directive comment

Reports leading whitespaces before Go directives in comments.

Locks mistakenly passed by value

Reports locks that are mistakenly passed by values.

Loop variables captured by the func literal

Reports references to loop variables from within func literals in defer and go statements.

Malformed build tag

Reports malformed build tags and build tags in the incorrect location.

Malformed struct tag

Reports struct tags that do not conform to Go conventions for struct tags.

Malformed test function name

Reports malformed names of tests, benchmarks, and examples.

Missing 'case' statements for 'iota' consts in 'switch'

Reports unhandled values in switch statements when the iota identifier is in the const declaration.

Missing trailing comma before a newline in a composite literal

Reports a missing trailing comma before a newline in composite literals, function call arguments, and function parameter lists.

Mixed value and pointer receivers

Reports structures with methods that use a mixture of types: value and pointer receivers.

Name starts with a package name

Reports exported names that start with a package name.

Nilness analyzer

Reports problems caused by incorrect usage of the nil value.

Non-standard signature for well-known function names

Reports methods with certain names in the following cases: the method's name matches the name of several well-known interface methods from the standard library the signature does not match the signature of the corresponding interface method Such methods might indicate that the receiver type is intended to satisfy an interface from the standard library, but fails to do so because of the mistake in the method's signature.

Potential nil dereference

Reports instances where pointers that might be nil are dereferenced.

Receiver has a generic name

Reports receiver names like me, this, self, or names that differ from other receiver names for this type.

Redundant 'true' in for loop condition

Reports the redundant true literal in the for loop condition.

Redundant blank argument in range

Reports optional blank variables in range loops.

Redundant comma

Reports commas that may be omitted in the end of argument lists and composite literals.

Redundant import alias

Reports aliases of imported packages that may be omitted.

Redundant parentheses

Reports redundant parentheses in expressions and types.

Redundant second index in slices

Reports a redundant second index (a high bound) in slice expressions.

Redundant semicolon

Reports redundant semicolons.

Redundant types in composite literals

Reports redundant type declarations in composite literals.

Self assignment

Reports expressions that are assigned to themselves.

Shadowing variable

Reports declarations of variables that overlap with the declarations in the outer scope.

Struct initialization without field names

Reports structures that are initialized without specifying their field names.

The 'go:debug' directive is ignored in Go versions earlier than 1.21

Reports go:debug directive usages when a Go SDK version is less than 1.21.

The 'go:debug' directive must be placed before the package clause

Reports 'go:debug' directive being defined not above main or _test packages.

Type assertion on errors fails on wrapped errors

Reports type assertion or type switch on errors, for example, err.(*MyErr) or switch err.(type), and suggests using errors.As instead.

Type can be omitted

Reports types in variable and constant declarations that can be omitted since they can be inferred by the compiler.

Type parameter is declared in lowercase

Reports type parameters that are declared in lowercase.

Unexported return type of the exported function

Reports exported functions with unexported return types.

Unhandled error

Reports calls to functions and methods that do not handle the call result of the error type.

Unit-specific suffix for 'time.Duration'

Reports unit-specific suffixes in constant and variable names of time.Duration type.

Unnecessarily exported identifier

Reports exported identifiers that are used only in the package where they are defined but are not used in other packages.

Unsorted imports

Reports unsorted imports.

Unused constant

Reports constants that are defined but are never used in code.

Unused exported function

Reports unused exported functions.

Unused exported type

Reports unused exported types in the main package and in tests.

Unused function

Reports unused unexported functions.

Unused function or method call result

Reports calls to certain functions and methods that do not handle a call result.

Unused global variable

Reports global variables that are defined but are never used in code.

Unused type

Reports unused types.

Unused type parameter

Reports unused type parameters.

Usage of 'interface{}' as a type

Reports usages of the empty interface as a type or type constraint.

Usage of Snake_Case

Reports usage of snake case instead of camelcase for naming variables, constants and functions.

Usage of context.TODO()

Reports usages of context.TODO().

Last modified: 03 December 2024