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

Add requests to pause and resume indexing #1304

Closed
adam-fowler opened this issue May 15, 2024 · 4 comments
Closed

Add requests to pause and resume indexing #1304

adam-fowler opened this issue May 15, 2024 · 4 comments
Labels
enhancement New feature or request

Comments

@adam-fowler
Copy link
Contributor

Description

When I run a build in Xcode it pauses indexing is it worthwhile providing support for this in SourceKit-LSP?

@adam-fowler adam-fowler added the enhancement New feature or request label May 15, 2024
@ahoppen
Copy link
Collaborator

ahoppen commented May 15, 2024

Synced to Apple’s issue tracker as rdar://128149559

@ahoppen
Copy link
Collaborator

ahoppen commented May 21, 2024

Unless a compelling use for it comes up, I would prefer to not pause indexing automatically in SourceKit-LSP. Especially with #1260, indexing shouldn’t compete with the running processes for system resources.

@ahoppen ahoppen closed this as completed May 21, 2024
@adam-fowler
Copy link
Contributor Author

I guess as long as it doesn't slowdown or interrupt builds that'll be fine. But at the moment Xcode pauses indexing when building.

@ahoppen
Copy link
Collaborator

ahoppen commented May 22, 2024

Oh, I see, you meant while building, I caught on to the run part of your description.

Xcode has index while building, so a build does index your project as well, so it doesn’t make sense to run a background index simultaneously. In SourceKit-LSP, you currently either purely use index-while-building (status quo) or background indexing (what I’ve been implementing recently) and there’s no way to merge the two. The exact details of how to achieve that (and if we want to at all) are still TBD (#1270 has some of the challenges) and until we do that, there’s no reason to pause indexing during a build.

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

2 participants