Skip to content
This repository has been archived by the owner on Sep 22, 2024. It is now read-only.

KTS takes a while to load when most grammars are installed #325

Open
hadronized opened this issue Apr 23, 2024 · 0 comments
Open

KTS takes a while to load when most grammars are installed #325

hadronized opened this issue Apr 23, 2024 · 0 comments
Labels
prio:medium Something requiring attention

Comments

@hadronized
Copy link
Owner

hadronized commented Apr 23, 2024

I tried

ktsctl manage -fcia

Which basically installs everything. Once that is done (it can take a while), starting KTS for the first time and having it answer back to clients is long. We have several options:

  • Load grammars in an asynchronous way. That is tricky, as it means that if a buffer is open for language lang while its associated grammar is not loaded yet, we will not enable KTS for this buffer, even when we load lang’s resources. Solving Choose when to highlight more dynamically #260 might help here.
  • We should also provide a way to never make the server exit, even when the last session exits. That would open the possibility to have it run once and for all (for instance via a systemd unit on Linux), or simply have it started at the first start of Kakoune.

In both cases, I think we want the feature; asynchronous grammar loading with supporting “enabling” KTS for a buffer at various times, and make it possible to keep KTS run forever (which is the case if --kakoune is not passed, btw).

Related problems

I’m creating that section so that people can look up for similar problems and not open a duplicate issue:

  • Buffer is never highlighted (because we miss the init phase?).
  • Opening a file on the CLI with kak foo.rs does not highlight right away / immediately.
@hadronized hadronized added this to the kak-tree-sitter v0.6 milestone Apr 23, 2024
@hadronized hadronized added the prio:medium Something requiring attention label Apr 23, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
prio:medium Something requiring attention
Projects
None yet
Development

No branches or pull requests

1 participant