-
Notifications
You must be signed in to change notification settings - Fork 182
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Terraform extentions IntelliSense running very slow #1544
Comments
Very slow for me too. The gap between a save and a format is huge. Taking a couple of secs! Any thoughts? |
We know this has been a frustrating experience and appreciate your understanding while we gathered feedback and examples to diagnose this issue. We've created #1557 as a central place to see updates on what we are doing to address performance issues in terraform-ls in both the short and long term and pinned it to the repo. We'll be adding more detail there as we implement fixes. As we work on this we'll be recording the content and then closing the individual issues so that everyone has one place to look at instead of searching for individual tickets for updates. |
What I've noticed is that the first save (and format) is quite quick. This seems to kick off something in the Terraform language server which causes it to consume a lot of CPU for quite some time. A second attempt to save while the language server is still consuming CPU will cause VSCode to hang, waiting for formatting. If I watch the This seems to primarily occur in the root module which references quite a few other local modules. The modules themselves are much less affected. |
We've released With the fix, we should be back to terraform-ls If you have the time, please give it a try and let us know how it works for you. Please open a new issue rather than replying here, as this issue has gotten so many replies with different experiences it is hard to process. I am going to close this as we're using #1557 as a central tracking issue, so subscribe to that to see continued updates. |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Extension Version
v2.27.0
VS Code Version
Version: 1.80.1
Commit: 74f6148eb9ea00507ec113ec51c489d6ffb4b771
Date: 2023-07-12T17:20:23.298Z (1 wk ago)
Electron: 22.3.14
ElectronBuildId: 21893604
Chromium: 108.0.5359.215
Node.js: 16.17.1
V8: 10.8.168.25-electron.0
OS: Darwin x64 22.5.0
Operating System
macOS Ventura 13.4 (22F66)
Terraform Version
Terraform v1.5.3 on darwin_amd64
Steps to Reproduce
I am experiencing significant performance issues with the Terraform extension in Visual Studio Code (VS Code). Specifically, the IntelliSense feature, which provides code suggestions, is running very slowly and causing delays in my workflow. On the other hand, the Python extension, which I also have installed, works as expected, providing quick and responsive suggestions.
Steps to Reproduce:
Expected Behavior
IntelliSense should start automatically and display suggestions immediately after I start typing, just like the Python extension does.
Actual Behavior
Instead of immediate suggestions, there is a considerable delay of approximately 5 seconds or more before IntelliSense displays any Terraform suggestions.
Terraform Configuration
No response
Project Structure
No response
Gist
No response
Anything Else?
I have the Python extension installed as well, and it operates smoothly without any noticeable delays.
My VS Code workspace does not contain an excessive number of files or folders that could be causing the slowdown.
The slowness issue persists even when I disable other extensions, leaving only the Terraform extension enabled.
I have deleted the installation, and extions folder as described in the VS code documentation, but still the issue persist.
Workarounds
No response
References
No response
Help Wanted
Community Note
The text was updated successfully, but these errors were encountered: