Error with Markdown plugin dependency using Gradle Kotlin DSL

Answered

Hi!

I'm having a ClassNotFoundException in my PluginClassLoader referencing classes from Markdown plugin.

Issue was reproduced using a brand new intellij-platform-plugin-template, adding a single dependency with org.intellij.markdown.plugin:

After refreshing gradle, plugin compiles fine, and so verify plugin task.

 

 

When running plugin, an exception is thrown when plugin code reaches any class from Markdown dependant plugin:

Caused by: java.lang.ClassNotFoundException: org.intellij.plugins.markdown.lang.MarkdownTokenTypes PluginClassLoader[...]

Added external libraries view.

3 comments
Comment actions Permalink

Pedro, you're trying to use a class from the java module – you have to add com.intellij.java to your platformPlugins list.

0
Comment actions Permalink

The simplest explanation is usually the best one! I was missing the declaration in the plugin.xml... I thought the `patchPluginXml` task worked the magic. Thanks!

0

Please sign in to leave a comment.