Inspectopedia 2024.3 Help

Code

'UastHintedVisitorAdapter' hints problems   New in this release

Reports missing or redundant hints in UastHintedVisitorAdapter creation.

A service can be converted to a light one   New in this release

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.

Accessible context is missing   New in this release

Reports Swing components that do not provide accessibility context.

ActionUpdateThread is missing   New in this release

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

Application service assigned to a static final field or immutable property   New in this release

Reports assignments of application services to static final fields / immutable properties.

Calling method should be annotated with @RequiresBlockingContext   New in this release

Highlights calls of method annotated with @RequiresBlockingMethod inside non-annotated method.

Cancellation check in loops   New in this release

Reports loops, forEach-like methods, and ContainerUtil.process() with missing cancellation checks.

Cancellation exception handled incorrectly   New in this release

Reports ProcessCanceledException and CancellationException handled incorrectly.

Companion object in extensions   New in this release

Reports incorrect companion objects' usage in extensions.

Component type mismatch   New in this release

Reports incorrect registration of plugin components (Actions and Components).

Component/Action not registered   New in this release

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

Eager creation of action presentation   New in this release

Reports any actions that are registered in the plugin.xml file and instantiate the com.intellij.openapi.actionSystem.Presentation object in their constructors.

Extension class should be final and non-public   New in this release

Reports extension classes that are non-final or public.

Extension registered as service/component   New in this release

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

Field blocks intention preview   New in this release

Reports fields in LocalQuickFix and IntentionAction implementations that prevent intention preview action from functioning properly.

File.equals() usage   New in this release

Reports usages of java.io.File.equals()/hashCode()/compareTo() methods.

Forbidden in suspend context method usage   New in this release

Reports inappropriate usages of methods in Kotlin coroutines, which uses threading context (annotated with @RequiresBlockingContext).

Incorrect parentDisposable parameter   New in this release

Reports using Application or Project as a parent Disposable in plugin code.

Incorrect service retrieving   New in this release

Reports the following problems when retrieving services: Attempts to retrieve an unregistered service.

Invalid icon path in @Presentation   New in this release

Reports invalid and deprecated value for icon attribute in com.intellij.ide.presentation.Presentation annotation.

JComponent must use UiDataProvider   New in this release

Reports JComponent classes implementing incorrect data provider interface.

Kotlin object registered as extension   New in this release

Reports Kotlin objects that are registered as plugin extensions.

Light service must be final   New in this release

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

Listener implementation implements 'Disposable'   New in this release

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

Map key may leak   New in this release

Reports using Language or FileType as a map key in plugin code.

Migrate to getOptionPane()   New in this release

Reports createOptionsPanel() methods in inspection implementation, which can be automatically converted to getOptionsPane().

Mismatch between light service level and its constructor   New in this release

Reports mismatches between light service levels and its constructors.

Non-default constructor in serializable class   New in this release

Reports non-default constructor in serializable classes.

Non-default constructors for service and extension class   New in this release

Reports extension/service class having a non-default (empty) constructor.

Non-platform TokenSet declared in ParserDefinition   New in this release

Reports TokenSet field declarations referencing non-platform element types in ParserDefinition classes.

Potential deadlock in service initialization   New in this release

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.

QuickFix's getFamilyName() implementation must not depend on a specific context   New in this release

Reports QuickFix.getFamilyName() using contextual information.

Simplifiable service retrieving   New in this release

Reports service getting calls that can be replaced with a calls to an existing static getInstance() or getInstance(Project) methods.

Stateful extension   New in this release

Reports extensions and quick-fixes holding potentially leaking state.

Static initialization in extension point implementations   New in this release

Reports static initialization in extension point implementations.

Threading and concurrency problems   New in this release

Reports threading and concurrency issues in code using information from com.intellij.util.concurrency.annotations annotations.

UElement as PsiElement usage   New in this release

Reports usage of UAST UElement as PsiElement.

Undesirable class usage   New in this release

Reports usages of undesirable classes (mostly Swing components).

Unresolved plugin configuration reference   New in this release

Reports unresolved references to plugin configuration elements.

Unsafe VFS recursion   New in this release

Reports usage of VirtualFile.getChildren() inside recursive methods.

Unsafe return statements visitor   New in this release

Reports unsafe use of JavaRecursiveElementVisitor.visitReturnStatement().

Unspecified action place   New in this release

Reports passing unspecified place parameter for ActionManager.createActionToolbar() and ActionManager.createActionPopupMenu().

Usage of IntelliJ API not available in older IDEs   New in this release

Reports usages of IntelliJ Platform API introduced in a version newer than the one specified in <idea-version> @since-build in plugin.xml.

Use 'PluginId#equals(Object)'   New in this release

Reports comparing PluginId instances using ==.

Use 'PsiType#equals(Object)' with primitive types   New in this release

Reports comparing PsiPrimitiveType instances using ==.

Use 'VirtualFile#equals(Object)'   New in this release

Reports comparing VirtualFile instances using ==.

Use 'com.intellij.util.io.ProcessKt.awaitExit()'   New in this release

Reports usages of Process.waitFor() and Process.onExit() in coroutine context.

Use DPI-aware borders   New in this release

Reports usages of javax.swing.border.EmptyBorder and JBUI.Borders.emptyXyz() that can be simplified.

Use DPI-aware insets   New in this release

Reports usages of java.awt.Insets and JBUI.insetsXyz() that can be simplified.

Use Darcula aware JBColor   New in this release

Reports usages of java.awt.Color.

Using PsiElement string representation to generate new expression is incorrect   New in this release

Reports direct usage of PsiElement and PsiType in strings.

Using new Color(a,a,a)   New in this release

Reports usages of java.awt.Color to create gray colors.

Last modified: 03 December 2024