KronicDeth / intellij-elixir

Elixir plugin for JetBrain's IntelliJ Platform (including Rubymine)
Other
1.83k stars 153 forks source link

Add support for 2024.2 #3628

Closed joshuataylor closed 1 month ago

joshuataylor commented 1 month ago

There are quite a few changes with 2024.2, and I was hoping we could support 2024.1.4 alongside 2024.2, as long as possible, as 2024.2 is still quite new.

Unfortunately it looks like this isn't possible for a method we use, I've updated it and it should now verify properly on 242.* (2024.2+).

I'll tag a release for testing, once we get the Marketplace stuff sorted, you'll be able to download it via the EAP Channel, until then the ZIP method is okay.

nilsivanson commented 1 month ago

I built the plugin from these sources a couple of days ago and have been running with no issues on IDEA Ultimate 2024.2.

  1. Clone Repository
  2. Checkout branch
  3. Run gradle command buildPlugin (Gradle->Elixir->Tasks->intellij->buildPlugin)
  4. Manually "install plugin from disk" zip-file generated in build/distributions in Settings->Plugins->Cogwheel icon->Install Plugin from Disk
gaggle commented 1 month ago

@nilsivanson you made me brave enough to try that, and your steps worked perfectly 🎉:

$ git clone git@github.com:KronicDeth/intellij-elixir.git
Cloning into 'intellij-elixir'...
remote: Enumerating objects: 101804, done.
remote: Counting objects: 100% (543/543), done.
remote: Compressing objects: 100% (210/210), done.
remote: Total 101804 (delta 292), reused 472 (delta 263), pack-reused 101261 (from 1)
Receiving objects: 100% (101804/101804), 71.14 MiB | 1.99 MiB/s, done.
Resolving deltas: 100% (71314/71314), done.
$ cd intellij-elixir/
$ git co feature/support-2024.2
branch 'feature/support-2024.2' set up to track 'origin/feature/support-2024.2'.
Switched to a new branch 'feature/support-2024.2'

And et voilà Elixir plugin is working, code is highlighted, I'll report back if any issues but thank you for the simple steps @nilsivanson (this is literally the first time I've run Gradle)

gaggle commented 1 month ago

FWIW, exception:

Details

``` org.elixir_lang.psi.impl.ElixirInterpolatedSigilLineImpl java.lang.Throwable: Do not know whether to inject Markdown in documentation at org.elixir_lang.errorreport.Logger.error(Logger.kt:45) at org.elixir_lang.errorreport.Logger.error(Logger.kt:25) at org.elixir_lang.injection.markdown.Injector.getLanguagesToInjectInQuote(Injector.kt:75) at org.elixir_lang.injection.markdown.Injector.getLanguagesToInject(Injector.kt:25) at com.intellij.psi.impl.source.tree.injected.InjectedLanguageManagerImpl.processInPlaceInjectorsFor(InjectedLanguageManagerImpl.java:494) at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtilBase.probeElementsUpInner(InjectedLanguageUtilBase.java:237) at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtilBase.lambda$probeElementsUp$0(InjectedLanguageUtilBase.java:217) at com.intellij.openapi.application.impl.ReadActionCacheImpl$allowInWriteAction$1.invoke(ReadActionCacheImpl.kt:41) at com.intellij.openapi.application.impl.ReadActionCacheImpl$allowInWriteAction$1.invoke(ReadActionCacheImpl.kt:41) at com.intellij.openapi.application.impl.ReadActionCacheImpl.allowInWriteAction(ReadActionCacheImpl.kt:29) at com.intellij.openapi.application.impl.ReadActionCacheImpl.allowInWriteAction(ReadActionCacheImpl.kt:41) at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtilBase.probeElementsUp(InjectedLanguageUtilBase.java:216) at com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtilBase.enumerate(InjectedLanguageUtilBase.java:159) at com.intellij.psi.impl.source.tree.injected.InjectedLanguageManagerImpl.enumerateEx(InjectedLanguageManagerImpl.java:379) at com.intellij.codeInsight.daemon.impl.InspectionRunner.getInjectedWithHosts(InspectionRunner.java:507) at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$inspect$10(InspectionRunner.java:219) at com.intellij.concurrency.JobLauncherImpl.procInOrderAsync(JobLauncherImpl.java:539) at com.intellij.codeInsight.daemon.impl.InspectionRunner.inspectInjectedPsi(InspectionRunner.java:464) at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$inspect$11(InspectionRunner.java:217) at com.intellij.concurrency.JobLauncherImpl.procInOrderAsync(JobLauncherImpl.java:539) at com.intellij.codeInsight.daemon.impl.InspectionRunner.lambda$inspect$12(InspectionRunner.java:202) at com.intellij.codeInspection.InspectionEngine.withSession(InspectionEngine.java:205) at com.intellij.codeInsight.daemon.impl.InspectionRunner.inspect(InspectionRunner.java:162) at com.intellij.codeInsight.daemon.impl.LocalInspectionsPass.collectInformationWithProgress(LocalInspectionsPass.java:140) at com.intellij.codeInsight.daemon.impl.ProgressableTextEditorHighlightingPass.doCollectInformation(ProgressableTextEditorHighlightingPass.java:84) at com.intellij.codeHighlighting.TextEditorHighlightingPass.collectInformation(TextEditorHighlightingPass.java:57) at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$2(PassExecutorService.java:418) at com.intellij.platform.diagnostic.telemetry.helpers.TraceKt.runWithSpanIgnoreThrows(trace.kt:118) at com.intellij.platform.diagnostic.telemetry.helpers.TraceUtil.runWithSpanThrows(TraceUtil.java:36) at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$3(PassExecutorService.java:413) at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.tryRunReadAction(AnyThreadWriteThreadingSupport.kt:291) at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:965) at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$4(PassExecutorService.java:404) at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeProcessUnderProgress$13(CoreProgressManager.java:660) at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:735) at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:691) at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:659) at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:79) at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.doRun(PassExecutorService.java:403) at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$run$0(PassExecutorService.java:379) at com.intellij.openapi.fileTypes.impl.FileTypeManagerImpl.cacheFileTypesInside(FileTypeManagerImpl.java:802) at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$run$1(PassExecutorService.java:379) at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.executeByImpatientReader(AnyThreadWriteThreadingSupport.kt:486) at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:179) at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.run(PassExecutorService.java:377) at com.intellij.concurrency.JobLauncherImpl$VoidForkJoinTask$1.exec(JobLauncherImpl.java:190) at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:507) at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1491) at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:2073) at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:2035) at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:187) ```

To be clear though: I'm not sure these are caused by this version, as previous versions also exhibited the occasional non-fatal issues.

joshuataylor commented 1 month ago

Need to merge #3619 before this, due to the IntelliJ gradle plugin, I think.

Message about required migration to IntelliJ Platform Gradle Plugin 2.0 when targeting IntelliJ Platform 2024.2+ (242+).

Fun.

joshuataylor commented 1 month ago

Closing in favour of https://github.com/KronicDeth/intellij-elixir/pull/3619