Plugin dev using gradle: Could not determine target platform version, please check project setup

Answered

Hi

 

I'm using gradle to developer IntelliJ plugins:

build.gradle

intellij {
//version gradle.ext.intellij_version
version '2021.2'
...
}

plugin.xml

<applicationListeners>

<listener class="wfplugins.wftools.WFToolsLoggerOpened"
topic="com.intellij.openapi.project.ProjectManagerListener"/>

</applicationListeners>

And Intellij (2021.2 EAP) highlights it in red:

   Could not determine target platform version, please check project setup
   Inspection info: Reports problems in plugin.xml.
   Invalid configuration can lead to problems at runtime.

 

Thanks

Boaz

 

 

3 comments
Comment actions Permalink

Project SDK set to JDK, not Intellij Plugin SDK , now it‘s OK。

1
Comment actions Permalink

Funny enough, I ran into the exact same issue with the Key Promoter earlier today. As far as I can see, my usage of "applicationListeners" is correct and I'm sure yours is correct as well. I identified the problem in the devkit plugin and will discuss in the upcoming days if there is a quick fix for this.

0
Comment actions Permalink
intellij {
//version gradle.ext.intellij_version
version '2021.2'
...
}

This configuration is not valid. I assume you're trying to build against `LATEST-EAP-SNAPSHOT` or another version missing the platform target baseline version number in its name.
If you _really_ must build against 212 EAP, specify exact published EAP build number, or "212-EAP-SNAPSHOT" if you absolutely require building against latest snapshot.

0

Please sign in to leave a comment.