Plug-In developed with Groovy 2.3.9 and runtime on target is 2.2.1 (Idea 14.0)

I have developed a plug-in using the latest 14.1 Idea Community Edition for the SDK.  It contains a groovy class, and is built with Groovy 2.3.9.    The target for the plugin are developers on Idea 13 and 14.0.

When I install the plugin on the 14.1 version, it runs fine.    When a developer with 14.0 installs it, it fails due to a groovy incompatibility. (Groovy ShortTypeHandling ClassNotFoundException).   The 14.0 project has several modules that require Groovy 2.4, but when it runs the plug-in, it chooses to run with the bundled runtime.

I would attempt to use a Groovy 2.2.1 or earlier SDK for the plugin development, but they are unsupported.   So, being rather new to Idea, I thought I would ask how I can configure the plug-in to require and export a non-bundled and later version of Groovy.

2 comments
Comment actions Permalink

If you put groovy-all-xxx.jar version to 'lib' directory of your plugin distribution it should be used instead of the bundled Groovy. Also you can
upload separate versions of your plugin compiled with different Groovy version for different IDEA versions.

--
Nikolay Chashnikov
JetBrains
http://www.jetbrains.com
"Develop with pleasure!"

0
Comment actions Permalink

Thanks, Nikolay.   I eventually went on to add groovy as a "Compile" dependency on the project which more or less had the same effect as your first suggestion I think.   Compiling different versions would seem to be a great idea if I wanted to keep the plugin ZIP a smaller size than the 13MB groovy jar (which I do) so thanks for that recommendation also.

0

Please sign in to leave a comment.