Recently I've released the 0.2.2 version of my plugin https://plugins.jetbrains.com/plugin/17037-awk-support to the marketplace.
This is a custom language support plugin.
Then I noticed that when I asked IDEA to check for updates and installed the new version - it immediately shown the internal IDE error.
Some notable parts of the error text are:
Caused by: com.intellij.diagnostic.ImplementationConflictException: Language with ID 'AWK' is already registered: class intellij_awk.AwkLanguage
java.lang.RuntimeException: java.util.concurrent.ExecutionException: com.intellij.diagnostic.PluginException: Cannot create class intellij_awk.AwkParserDefinition
java.lang.IllegalStateException: Index is not created for `Stubs`
The complete file with exceptions is here https://github.com/xonixx/intellij-awk/files/7267655/err.txt
Then IDEA just disables the plugin.
Manual restart of IDEA and enabling back the plugin makes the new version work just fine.
What I also noticed that IDEA didn't ask for restart after plugin update, so I assume what happens is a conflict in existing active version of plugin with the one being installed.
I'm frustrated by this problem since it's bad user experience for final plugin users and I don't see an obvious way to test for this issue before the release. Could it be that I should somehow force the IDEA restart after my plugin updated? Could it be something related to the newest version of IDEA? - I didn't have this issue with past updates of my plugin.
IntelliJ IDEA 2021.2.2 (Ultimate Edition)
Build #IU-212.5284.40, built on September 14, 2021
Would be grateful for any advice to fix and prevent this problem for future releases of my plugin.