Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

harper-ls --stdio using too many threads #198

Open
acampove opened this issue Oct 3, 2024 · 5 comments
Open

harper-ls --stdio using too many threads #198

acampove opened this issue Oct 3, 2024 · 5 comments
Assignees
Labels
bug Something isn't working harper-ls

Comments

@acampove
Copy link

acampove commented Oct 3, 2024

Hi,

I just downloaded this with Mason and I am using it with neovim. I suddenly found out that I cannot spawn threads and when I check with htop I see that harper-ls is using about 150 theads:

image

Why is this happening? How can I configure this tool to use only one thread?

Cheers.

@grantlemons
Copy link
Contributor

This should be configured by tokio to be the number of cores on your machine, how many do you have?

@elijah-potter elijah-potter added harper-ls bug Something isn't working and removed harper-ls labels Oct 3, 2024
@acampove
Copy link
Author

acampove commented Oct 4, 2024

This should be configured by tokio to be the number of cores on your machine, how many do you have?

I probably have around 128 cores. Do you know how to configure this using? I definitely do not think the program should be allowed to use all the cores. It should be limited to 2, at most 3. I am seeing the same problem with pyright, BTW.

@elijah-potter
Copy link
Collaborator

Ah. This should be a simple fix. We'll set harper-ls to cap out at 4 threads. That should be more than enough.

@elijah-potter
Copy link
Collaborator

@grantlemons drafted a fix and it has been merged. I'm going to spend some time with Harper this afternoon to make sure everything checks out before creating a release. At that point, you can confirm that the problem is fixed.

@acampove
Copy link
Author

acampove commented Oct 5, 2024

@grantlemons Thanks, could you please make another tag, 0.12.0? I am using Mason and this seems to download the latest tag.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working harper-ls
Projects
None yet
Development

No branches or pull requests

3 participants