cursive
cursive copied to clipboard
Multiple project-specific REPL commands with same name causes exception
If a user has two projects open, and they each contain a project-specific REPL command with the same name, IntelliJ will produce an error in the log:
2024-04-20 10:18:04,066 [ 377549] SEVERE - #c.i.o.a.i.ActionManagerImpl - ID 'Cursive.Repl.Command.load most recent scope capture!' is already taken by action 'load most recent scope capture! (null)' (class cursive.repl.commands.ReplCommandAction) null. Action 'load most recent scope capture! (null)' (class cursive.repl.commands.ReplCommandAction) cannot use the same ID
java.lang.Throwable: ID 'Cursive.Repl.Command.load most recent scope capture!' is already taken by action 'load most recent scope capture! (null)' (class cursive.repl.commands.ReplCommandAction) null. Action 'load most recent scope capture! (null)' (class cursive.repl.commands.ReplCommandAction) cannot use the same ID
at com.intellij.openapi.diagnostic.Logger.error(Logger.java:376)
at com.intellij.openapi.actionSystem.impl.ActionManagerImplKt.reportActionIdCollision(ActionManagerImpl.kt:1992)
at com.intellij.openapi.actionSystem.impl.ActionManagerImplKt.registerAction(ActionManagerImpl.kt:2075)
at com.intellij.openapi.actionSystem.impl.ActionManagerImplKt.registerAction$default(ActionManagerImpl.kt:2061)
at com.intellij.openapi.actionSystem.impl.ActionManagerImpl.registerAction(ActionManagerImpl.kt:962)
at cursive.repl.commands.ReplCommandsKt.registerActions(ReplCommands.kt:102)
etc etc
This will also cause those commands not to be visible in the IDE.