JetBrains / js-graphql-intellij-plugin

GraphQL language support for WebStorm, IntelliJ IDEA and other IDEs based on the IntelliJ Platform.
https://jimkyndemeyer.github.io/js-graphql-intellij-plugin/
MIT License
879 stars 97 forks source link

A question about supported platforms #657

Closed BoD closed 1 year ago

BoD commented 1 year ago

Hi! I see that 2 versions of the plugin are published:

master branch:

pluginVersion=4.0.0
pluginSinceBuild=231.0
pluginUntilBuild=233.*

222 branch:

pluginVersion=4.0.0-222
pluginSinceBuild=222.0
pluginUntilBuild=223.*

As of today,

Therefore 4.0.0-222 doesn't support Idea Stable because of its Until, and 4.0.0 doesn't support Android Studio Stable because of its Since.

Therefore, as the author of a plugin that depends on the GraphQL plugin, and trying to support both Android Studio and Idea,I can't depend on either 4.0.0 nor 4.0.0-222, I think I will also need to have 2 versions: one that depends on 4.0.0, and one that depends on 4.0.0-222.

Diffing the master and 222 branches, it looks to me that there are no code differences, correct? If I understand correctly, this means that there could be only one published version with pluginSinceBuild=222.0 and pluginUntilBuild=233.*, which would simplify things.

Am I missing anything? Thanks!

vepanimas commented 1 year ago

Hi @BoD,

I need to publish different versions because the binary compatibility of some JS-related classes was broken in version 231. As a result, a plugin compiled with 231 EAP won't work with earlier versions. AFAIK, you can't specify an exact version of a plugin dependency in a plugin manifest. However, you can try compiling with the latest 231 EAP and version 4.0.0 of the GraphQL plugin. Then, check that it works with 222 IDEA with 4.0.0-222 GraphQL plugin installed. Loading graphql.config.js should not cause any exceptions. If it works, that means everything is okay.

When you will be ready to release your plugin, I can also check it if you want.

BoD commented 1 year ago

Thanks a lot for replying!

some JS-related classes was broken in version 231

Oooh I see, so you basically had to exclude 231.

you can't specify an exact version of a plugin dependency in a plugin manifest. However, you can try compiling with the latest 231 EAP and version 4.0.0 of the GraphQL plugin. Then, check that it works with 222 IDEA with 4.0.0-222 GraphQL plugin installed. Loading graphql.config.js should not cause any exceptions. If it works, that means everything is okay.

That makes sense, thank you! I was confused by the 2 different kind of dependencies (compilation/gradle, which is versioned, vs manifest which is not).

Thanks a lot, it looks like what you say will work (I'm getting verifier errors, but that's a separate issue).