What does providers being deprecated mean for plugins?
Just saw this warning: ElixirSense.suggestions/3 is deprecated. providers will be dropped in the future.
What does this mean for ElixirSense's plugin setup? We utilize this heavily for Ash Framework.
@zachdaniel Provider code has been moved to ElixirLS in almost not changed form. I don't currently plan to break compatibility with the plugins but I'm unhappy with some aspects
- The current approach scans all modules for plugins on each complete request. This introduces noticeable delay as it reaches over the code server. We need a better plugin registration mechanism.
- Plugins are currently the most common crash reason. When a plugin loads it unloads elixir_sense modules from the ElixirLS release. It loads it's own older version of those modules and since then ElixirLS breaks in weirdest places with UndefinedFunctionError, MatchError. Loading a plugin must not unload/overwrite ElixirLS internal modules.
ElixirSense.Pluginbehaviour will either need to be extracted to a separate library (and renamed toElixirLS.Plugin) or the plugins should not implement it explicitly. - So far the plugin architecture only supports completions but we already have a need for definitions plugin.
This all sounds great to me 👍. I’ve got no issue reworking our plugin to meet a new api, and I’ve also got no problem if there is like an “install” step that users have to do, like putting something in their config. Let me know how I can help on this front :)
Since Lexical relies on elixir_sense plugins a had to revert most of the changes. At least for now the providers are here to stay