pragmagic / vscode-nim

An extension for VS Code which provides support for the Nim language.
Other
237 stars 37 forks source link

Nimsuggest degradation with time, potential workaround #95

Closed cooldome closed 5 years ago

cooldome commented 5 years ago

I am using VSCode with nim plugin daily for more than a year now. I have noticed that nimsuggest works really well when you just started VSCode, but with every code modification and recompilation nimsuggest gets slower and slower and consumes more memory.

After couple of hours of active work nimsuggest becomes useless, you need to kill it and restart and then it works again.

While it is definitely problem of nimsuggest and not of this plugin. I suggest simple workaround on the plugin side to considerably improve user experience: periodically restart nimsuggest after timeout. Let's say restart nimsuggest every 5 minutes. Exact time can be configurable, zero can mean no restart to replicate existing behaviour.

exelotl commented 5 years ago

This would be really handy! Function hints just stop working completely for me after a short while, and killing nimsuggest does indeed seem to fix it.