Skip to content
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

CPU usage with vscode and the petrol library #1489

Open
clecat opened this issue Feb 26, 2025 · 1 comment
Open

CPU usage with vscode and the petrol library #1489

clecat opened this issue Feb 26, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@clecat
Copy link

clecat commented Feb 26, 2025

Hello,

I am currently working with the library petrol while coding in vscode and I have encountered a strange issue with ocamllsp: Indeed, whenever I try to code SQL queries using Petrol's Query and Expr modules, my whole editor seems to slow down quite substantially and code correction stops working altogether.

When I check my processes, it appears that the ocamllsp process has a CPU usage of 100%. The only "workaround" is found is to kill the process and use the short time window where everything works fine before it starts again.

I figured I should open this issue as you might have better solutions,
Thank you for your time, Gwen

@voodoos voodoos added the bug Something isn't working label Feb 27, 2025
@voodoos
Copy link
Collaborator

voodoos commented Feb 27, 2025

Thanks to Gwen's guidance I was able to reproduce the issue consistently. It is to the codeActions request that enters a seamingly infinite loop.

There is workaround in vscode: disable the display of the code action lightbulb 💡

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants