IDEA 2025.2 ERROR: 'kotlin.sequences.Sequence kotlin.sequences.SequencesKt.sequenceOf(java.lang.Object)'

Hi Team

When switched plugin SDK to IDEA 2025.2 we have our tests fail to run with the following error:

ERROR: 'kotlin.sequences.Sequence kotlin.sequences.SequencesKt.sequenceOf(java.lang.Object)'
java.lang.NoSuchMethodError: 'kotlin.sequences.Sequence kotlin.sequences.SequencesKt.sequenceOf(java.lang.Object)'
	at com.intellij.platform.workspace.storage.impl.WorkspaceEntityBase.getReferences$intellij_platform_workspace_storage(Entities.kt:46)
	at com.intellij.platform.workspace.storage.impl.WorkspaceEntityBase.getReferences$intellij_platform_workspace_storage$default(Entities.kt:39)
	at com.intellij.platform.workspace.storage.impl.WorkspaceEntityBase.referrers(Entities.kt:36)
	at com.intellij.platform.workspace.storage.impl.WorkspaceEntityExtensionDelegate.getValue(WorkspaceEntityExtensionDelegate.kt:44)
	at com.intellij.java.workspace.entities.JavaModuleSettingsKt.getJavaSettings(javaModuleSettings.kt:75)
	at com.intellij.workspaceModel.ide.legacyBridge.impl.java.CompilerModuleExtensionBridge.getJavaSettings(CompilerModuleExtensionBridge.kt:33)
	at com.intellij.workspaceModel.ide.legacyBridge.impl.java.CompilerModuleExtensionBridge.isCompilerOutputPathInherited(CompilerModuleExtensionBridge.kt:55)
	at com.intellij.openapi.roots.impl.CompilerProjectExtensionImpl.getRootsToWatch(CompilerProjectExtensionImpl.java:96)
	at com.intellij.openapi.roots.impl.CompilerProjectExtensionImpl$MyWatchedRootsProvider.getRootsToWatch(CompilerProjectExtensionImpl.java:145)
	at com.intellij.openapi.roots.impl.ProjectRootManagerComponent.collectWatchRoots(ProjectRootManagerComponent.kt:293)
...	

I’ve found the following issue in Bazel plugin YouTrack

Stating that “we need to exclude the std libs attached by the rules_kotlin and use the one provided by IntelliJ Platform”. However, I’m unsure about the exact steps needed to achieve this.

Could anyone please provide detailed instructions or guidance on how to properly configure this exclusion?

1 Like

First, you need to identify the problematic dependencies that pull in kotlin-stdlib. Then you can do something like this:

dependencies {
    ...
    implementation('com.example:some-problematic-library:1.0.0') {
        exclude(group = "org.jetbrains.kotlin", module = "kotlin-stdlib")     
    }
}

Make any progress? I already deal with conflicting dependencies like tapani mentioned, but it seems to hav stopped impacting since upgrading the build to 2025.2…. did you get anywhere? Currently trying to hack out the bundledPlugins…. yuck!

The tests that are failing? For me the only ones use the LightJavaCodeInsightFixtureTestCase5, i might try migrating away from this baseclass

Edit, turns out it was not the only ones, but I think this is a seperate issue.

I just solved this problem by updating to kotlin 2.2.0. Try updating too if you use earlier version