Interacting between two plugins causes class not found



The specifics to my issue are a bit more than the title says. I'm building an Intellij based product which has 2 plugins. These plugins need to have a one way communication, which is fine when running from the IDEA run configuration. The issue arises after I build idea-ce from the ant build.xml file. I only build the linux distribution, it completes successfully, however when I run it, this class not found exception is thrown which wasn't present when testing using the IDEA run configuration.

To test this issue, I'm using a clean clone of intellij ce (branch 201.4865) with an extremely basic plugin setup, which has a tool window with 1 button. When clicked, the button calls a public static method in one of the classes of plugin. When I run this with the IDEA run config, it's fine. After building the linux distribution, no errors are thrown on startup, but when the button is clicked, it throws the class not found error on the line where I call ShSettings.getShellcheckPath(). When I call PlatformUtils.getPlatformPrefix() however, it executes fine.

I'm unsure what I am missing/doing wrong. If anyone could point me in the right direction, that would be great.


1 comment

For anyone googling, I believe you simply can't have plugins which communicate, on a built product. I solved this by splitting my plugins into core plugin and others which depend on core, then removing core plugin from BUNDLED_PLUGIN_MODULES list, and adding it to productLayout.productImplementationModules. 


Please sign in to leave a comment.