# Incompatible Changes in IntelliJ Platform and Plugins API 2024.* List of known Breaking API Changes in 2024.* ## 2024.1 ### IntelliJ Platform 2024.2 ### IntelliJ Platform 2024.1 `com.intellij.refactoring.RefactoringHelper.prepareOperation(UsageInfo [] usages, List elements)` abstract method added : Use instead of `com.intellij.refactoring.RefactoringHelper.prepareOperation(UsageInfo [] usages)` and `com.intellij.refactoring.RefactoringHelper.prepareOperation(UsageInfo [] usages, PsiElement primaryElement)`. `com.intellij.refactoring.RefactoringHelper.prepareOperation(UsageInfo [] usages)` method removed : Use `com.intellij.refactoring.RefactoringHelper.prepareOperation(UsageInfo [] usages, List elements)` instead. `com.intellij.refactoring.RefactoringHelper.prepareOperation(UsageInfo [] usages, PsiElement primaryElement)` method removed : Use `com.intellij.refactoring.RefactoringHelper.prepareOperation(UsageInfo [] usages, List elements)` instead. `com.jetbrains.commandInterface.commandLine.psi.CommandLineFile` class moved to package `com.intellij.commandInterface.commandLine.psi` : Update code usages. `com.jetbrains.commandInterface.commandLine.CommandLineLanguage` class moved to package `com.intellij.commandInterface.commandLine` : Update code usages. `com.jetbrains.commandInterface.commandLine.psi.CommandLineArgument` class moved to package `com.intellij.commandInterface.commandLine.psi` : Update code usages. `com.jetbrains.commandInterface.commandLine.psi.CommandLineOption` class moved to package `com.intellij.commandInterface.commandLine.psi` : Update code usages. `com.intellij.application.options.editor.CodeFoldingConfigurable.applyCodeFoldingSettingsChanges()` method removed : Use top-level method `CodeFoldingConfigurableKt.applyCodeFoldingSettingsChanges` instead. `com.intellij.ide.bookmark.providers.LineBookmarkProvider.Companion` class removed : Use `com.intellij.ide.bookmark.providers.LineBookmarkProvider.Util` instead. `com.intellij.execution.process.mediator.util` package removed : The sole extension method `Deferred.blockingGet()` contained in this package is an anti-pattern, and was not supposed to be exposed in the first place. The process mediator and the elevation service are now product modules, and no longer part of the platform. `com.intellij.vcs.log.VcsLogFileHistoryHandler.getSupportedVcs()` abstract method added : Must be implemented. `com.intellij.vcs.log.VcsLogFileHistoryHandler.getHistoryFast(root: VirtualFile, filePath: FilePath, hash: Hash?, filters: VcsLogFilterCollection, commitCount: Int)` abstract method added : Parameter `filters: VcsLogFilterCollection` was added to provide filtering capabilities to file history. Implement `com.intellij.vcs.log.VcsLogFileHistoryHandler#getSupportedFilters` to specify which filters are supported by this extension (currently, branch filter, revision filter and range filter are available). `com.intellij.vcs.log.VcsLogFileHistoryHandler.collectHistory(root: VirtualFile, filePath: FilePath, hash: Hash?, filters: VcsLogFilterCollection, consumer)` abstract method added : Parameter `filters: VcsLogFilterCollection` was added to provide filtering capabilities to file history. Implement `com.intellij.vcs.log.VcsLogFileHistoryHandler#getSupportedFilters` to specify which filters are supported by this extension (currently, branch filter, revision filter and range filter are available). Method `com.intellij.psi.util.PsiTreeUtilKt.getFirstLeaf(PsiElement)` renamed to `com.intellij.psi.util.PsiTreeUtilKt.firstLeaf(PsiElement)` : Update code usages. Method `com.intellij.psi.util.PsiTreeUtilKt.getLastLeaf(PsiElement)` renamed to `com.intellij.psi.util.PsiTreeUtilKt.lastLeaf(PsiElement)` : Update code usages. Method `com.intellij.psi.util.PsiTreeUtilKt.getChildLeafs(PsiElement)` renamed to `com.intellij.psi.util.PsiTreeUtilKt.childLeafs(PsiElement)` : Update code usages. `org.apache.tools` package removed : Please provide all necessary libraries in your plugin distribution. `com.intellij.openapi.projectRoots.impl.ProjectJdkImpl.readExternal(Element, ProjectJdkTable)` method removed : Use `com.intellij.openapi.projectRoots.impl.ProjectJdkImpl.readExternal(Element, Function)` instead. `com.intellij.openapi.projectRoots.impl.SdkConfigurationUtil.createSdk(Collection, String, SdkType, SdkAdditionalData, String)` method return type changed from `ProjectJdkImpl` to `Sdk` : Update code usages. `com.intellij.openapi.projectRoots.impl.SdkConfigurationUtil.createSdk(Collection, VirtualFile, SdkType, SdkAdditionalData, String)` method return type changed from `ProjectJdkImpl` to `Sdk` : Update code usages. ### Java Plugin 2024.1 `com.intellij.lang.properties.RemovePropertyLocalFix` class removed : Use `com.intellij.codeInsight.daemon.impl.quickfix.DeleteElementFix` instead. `com.intellij.psi.util.PsiUtil#isLanguageLevel10OrHigher()` method removed : It's recommended to use a new method `com.intellij.psi.util.PsiUtil#isAvailable()` instead to check whether a particular feature is available, rather than to check against a language level. If you still need an explicit language level check, you may use `PsiUtil.getLanguageLevel(element).isAtLeast(level)`. `com.intellij.psi.util.PsiUtil#isLanguageLevel11OrHigher()` method removed : It's recommended to use a new method `com.intellij.psi.util.PsiUtil#isAvailable()` instead to check whether a particular feature is available, rather than to check against a language level. If you still need an explicit language level check, you may use `PsiUtil.getLanguageLevel(element).isAtLeast(level)`. `com.intellij.psi.util.PsiUtil#isLanguageLevel14OrHigher()` method removed : It's recommended to use a new method `com.intellij.psi.util.PsiUtil#isAvailable()` instead to check whether a particular feature is available, rather than to check against a language level. If you still need an explicit language level check, you may use `PsiUtil.getLanguageLevel(element).isAtLeast(level)`. `com.intellij.psi.util.PsiUtil#isLanguageLevel16OrHigher()` method removed : It's recommended to use a new method `com.intellij.psi.util.PsiUtil#isAvailable()` instead to check whether a particular feature is available, rather than to check against a language level. If you still need an explicit language level check, you may use `PsiUtil.getLanguageLevel(element).isAtLeast(level)`. `com.intellij.psi.util.PsiUtil#isLanguageLevel17OrHigher()` method removed : It's recommended to use a new method `com.intellij.psi.util.PsiUtil#isAvailable()` instead to check whether a particular feature is available, rather than to check against a language level. If you still need an explicit language level check, you may use `PsiUtil.getLanguageLevel(element).isAtLeast(level)`. ### Django Plugin 2024.1 Package `com.jetbrains.jinja2` renamed to `com.intellij.jinja` : Update code usages. ### Restructured Text Plugin 2024.1 `com.jetbrains.rest.RestLanguage` class moved to package `com.intellij.python.reStructuredText` : Update code usages. ### GitHub Plugin 2024.1 `org.jetbrains.plugins.github.pullrequest.comment.GHPRDiffReviewSupport` class removed : Migrated to MVVM. `org.jetbrains.plugins.github.pullrequest.comment.GHPRDiffReviewSupport.Companion` class removed : Migrated to MVVM. `org.jetbrains.plugins.github.pullrequest.action.GHPRActionKeys.getPULL_REQUEST_DATA_PROVIDER()` method removed : Migrated to MVVM, hidden implementation details. ### Kotlin Plugin 2024.1 `org.jetbrains.kotlin.ir.visitors.IrElementVisitor.visitInlinedFunctionBlock(inlinedFunctionBlock: IrInlinedFunctionBlock, data: D)` abstract method added `org.jetbrains.kotlin.ir.visitors.IrElementVisitor.visitReturnableBlock(returnableBlock: IrReturnableBlock, data: D)` abstract method added `org.jetbrains.kotlin.ir.visitors.IrElementVisitorVoid.visitInlinedFunctionBlock(inlinedFunctionBlock: IrInlinedFunctionBlock)` abstract method added `org.jetbrains.kotlin.ir.visitors.IrElementVisitorVoid.visitInlinedFunctionBlock(inlinedFunctionBlock: IrInlinedFunctionBlock, data: Nothing?)` abstract method added `org.jetbrains.kotlin.ir.visitors.IrElementVisitorVoid.visitReturnableBlock(returnableBlock: IrReturnableBlock)` abstract method added `org.jetbrains.kotlin.ir.visitors.IrElementVisitorVoid.visitReturnableBlock(retunrableBlock: IrReturnableBlock, data: Nothing?)` abstract method added `org.jetbrains.kotlin.fir.expressions.FirConstExpression` class renamed `org.jetbrains.kotlin.fir.expressions.FirLiteralExpression` `org.jetbrains.kotlin.ir.declarations.IrDeclarationOrigin.DELEGATE` class removed : `org.jetbrains.kotlin.ir.declarations.IrDeclarationOrigin.Companion.DELEGATE` should be used instead `org.jetbrains.kotlin.ir.declarations.IrDeclarationOrigin.DELEGATED_MEMBER` class removed : `org.jetbrains.kotlin.ir.declarations.IrDeclarationOrigin.Companion.DELEGATED_MEMBER` should be used instead `org.jetbrains.kotlin.config.JvmDefaultMode.DEFAULT` field removed : Use `org.jetbrains.kotlin.config.JvmDefaultMode.DISABLE` Method `org.jetbrains.kotlin.backend.common.lower.LocalDeclarationsLoweringKt.getParentsWithSelf(IrDeclaration)` renamed to `org.jetbrains.kotlin.ir.util.IrUtilsKt.getParentsWithSelf` `org.jetbrains.kotlin.daemon.common.CompileService.Companion.getNO_SESSION()` method removed : Use `org.jetbrains.kotlin.daemon.common.CompileService.NO_SESSION` const instead Class `org.jetbrains.kotlin.ir.declarations.IrDeclarationOriginImpl` made final : Create a new `IrDeclarationOrigin` by delegation. See https://github.com/JetBrains/kotlin/blob/a3b55cf758f3a7ceb596f65507c2f61ada5266af/compiler/ir/ir.tree/src/org/jetbrains/kotlin/ir/declarations/IrDeclarationOrigin.kt#L20 ### Maven Plugin 2024.1 `org.jetbrains.idea.maven.indices.MavenIndex.getUpdateTimestamp()` method removed : Use `org.jetbrains.idea.maven.indices.MavenIndexImpl.getUpdateTimestamp()` instead. `MavenIndex` is an obsolete interface now with `MavenIndexImpl` as the only implementation, consider using `MavenGAVIndex` to get information about available Maven GAV coordinates, or `MavenSearchIndex` to search Maven artifacts by content. `org.jetbrains.idea.maven.indices.MavenIndex.getFailureMessage()` method removed : Use `org.jetbrains.idea.maven.indices.MavenIndexImpl.getFailureMessage()` instead. `MavenIndex` is an obsolete interface now with `MavenIndexImpl` as the only implementation, consider using `MavenGAVIndex` to get information about available Maven GAV coordinates, or `MavenSearchIndex` to search Maven artifacts by content. `org.jetbrains.idea.maven.indices.MavenIndex.getRepositoryPathOrUrl()` method removed : Use `org.jetbrains.idea.maven.indices.MavenRepositoryIndex.getRepository().getUrl()` instead. Also, `MavenRepositoryInfo.getKind()` could be used to distinguish between local and remote repo. `org.jetbrains.idea.maven.indices.MavenIndicesManager.scheduleUpdateContent(List, boolean)` method removed : Use `org.jetbrains.idea.maven.indices.searcher.MavenLuceneIndexer.update(List, Boolean)` to update content for lucene indices. You should not care of GAV indices update. `org.jetbrains.idea.maven.indices.MavenIndicesManager.scheduleUpdateIndicesList(Consumer)` method removed : Use `org.jetbrains.idea.maven.indices.searcher.MavenIndicesManager.scheduleUpdateIndicesList()` to update an indices list for a specific project. To get all search indices for specific project use `MavenSystemIndicesManager.getClassIndexForRepository()`, you can get a list of all repositories with `MavenIndexUtils.getAllRepositories(Project)`. ### Database Plugin 2024.1 `com.intellij.database.datagrid.DataGrid.getLocalFilterState()` abstract method added : Only recompilation is needed for classes that implement `DataGrid` and delegate calls to an actual `DataGrid` implementation. `com.intellij.database.datagrid.DataGrid.getColumnAttributes()` abstract method added : Only recompilation is needed for classes that implement `DataGrid` and delegate calls to an actual `DataGrid` implementation.