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

tach server runs check too often #486

Open
emdoyle opened this issue Dec 19, 2024 · 0 comments
Open

tach server runs check too often #486

emdoyle opened this issue Dec 19, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@emdoyle
Copy link
Member

emdoyle commented Dec 19, 2024

Right now, the LSP server built into Tach is very naive. When a Python document is opened or saved, it will run a full tach check and then filter the errors to the ones relevant to the file.

A relatively simple improvement would be to create an API for checking a single file at a time, since this should be fast enough (even for large files) to keep the current eager behavior.

Another avenue would be to make the server only re-check the project when Python files or the tach.toml are saved. When a file is opened, it could read the check results from a cached copy in memory, and on change it could either do nothing, or publish empty diagnostics. This seems more complex though, and probably doesn't perform noticeably better in most cases.

@emdoyle emdoyle added the enhancement New feature or request label Dec 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant