ant-druha / intellij-powershell

Adds PowerShell language support to IntelliJ-based IDEs.
https://plugins.jetbrains.com/plugin/10249-powershell
Apache License 2.0
71 stars 20 forks source link

PowerShellEditorServices is v1.10.1 (6 years old) #188

Closed MostHated closed 6 months ago

MostHated commented 6 months ago

I have noticed that this plugin itself receives relatively regular updates (looks like once a month at least for the last few months), but not the bundled packages. The PowerShellEditorServices package included has a release date from v1.10.1: Dec 2018. The current version is v3.17.0: Jan 2024.

You will have to forgive me, as I am not very familiar (at all) with Jetbrains plugins or what they require when integrating an external language/service, but I was wondering if there was a specific reason for this (Ex. Does the PSES library require modification, or there are compatibility issues?) or just no one has got around to it? I am guessing that it must not be as simple as swapping out the old library and replacing it with the new version?

Thanks, -MH

ForNeVeR commented 6 months ago

There is a specific reason for this, but it's not that deep.

Update of anything bundled is currently pretty messy: you have to update a lot of bundled source files and sometimes even binaries, and this doesn't feel right.

I have a task to update PSScriptAnalyzer in my backlog (#109), and maybe will tackle PSES next (hopefully that will be easier after I get some dependency system in place of what we currently have instead).

Thanks for your report.

ForNeVeR commented 6 months ago

Ah, actually, this has already been requested, and I even tried that, and it failed (see the comments) :(

See #51. I'm closing this request as a duplicate.

It is still in my backlog after #109.

MostHated commented 6 months ago

I understand.

The main reason I bring it up, is that overall functionality on my end is broken (presumably because of the age of the library) when using relatively recent functionality.

Example Code in Rider ![](https://img.instance.id/I7mWHX5jnQ4W/direct)
Example Code in VSCode ![](https://img.instance.id/qiSvMte2OUHm/direct)

The same code is recognized as valid in both VSCode with the powershell plugin, as well as neovim when using an updated version PowerShellEditorServices (as seen by the reference count, lack of error, etc in the second image). In Rider, everything below the enum declaration is broken, unfortunately, making it unusable for code that uses newer features.

ForNeVeR commented 6 months ago

Note that highlighting in the plugin doesn't use PSES, so it is unlikely to be broken because of that. We have quite a few issues with certain modern (and often old as well) snippets and language features not being properly recognized, this all is in my current backlog as well.