tinymist icon indicating copy to clipboard operation
tinymist copied to clipboard

Intrusive completions after `:` in math mode

Open tingerrr opened this issue 7 months ago • 0 comments

Describe the bug Typing a colon within a math node opens completions which quickly get accepted by accident, inserting stuff like $: equation(|)$. The same happens if the node is unclosed ($:| instead of $:|$ with | being the cursor position).

image

I'm unsure whether this can be qualified as a bug, or if it is simply undesirable behavior for me. I'm also unsure if this is a helix problem or a tinymist problem, I don't use VS Code, so I can't really test this.

Most of the time, when I type a colon in math mode, I'm either writing quantifiers (forall n in NN : ...) or type annotations of some kind ($f : NN -> RR$). None of these really require me to get completions, as what follows are usually symbols.

Package/Software version:

Helix version: helix 24.7 (22a05140)

tinymist extension version:

tinymist
Build Timestamp:     2024-04-17T12:01:31.978359992Z
Build Git Describe:  879d95a
Commit SHA:          879d95a74b19b91d1c1b183d87f4c0ada4bd4e75
Commit Date:         None
Commit Branch:       None
Cargo Target Triple: x86_64-unknown-linux-gnu
Typst Version:       0.11.0

Logs:

tinymist client and server log:

2024-07-17T11:19:21.055 helix_core::syntax [ERROR] TS parser failed, disabling TS for the current buffer: Err(Cancelled)
2024-07-17T11:19:53.981 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:53Z INFO  tinymist::server::lsp] notifying textDocument/didChange - at Instant { tv_sec: 7377, tv_nsec: 931955160 }\n"
2024-07-17T11:19:53.981 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:53Z INFO  tinymist::server::lsp] notifing textDocument/didChange succeeded in 314.31µs\n"
2024-07-17T11:19:53.981 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:53Z INFO  typst_ts_compiler::service::diag::console] /src/de/thesis.typ: compiling ...\n"
2024-07-17T11:19:53.981 helix_lsp::transport [ERROR] tinymist err <- "    \n"
2024-07-17T11:19:53.991 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:53Z INFO  typst_ts_compiler::service::diag::console] /src/de/thesis.typ: Compilation succeeded in 9.710894ms\n"
2024-07-17T11:19:53.991 helix_lsp::transport [ERROR] tinymist err <- "    \n"
2024-07-17T11:19:53.991 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:53Z INFO  tinymist::actor::render] RenderActor: check path Some(/src/de/thesis.typ) and root Some(\"/home/tinger/Source/github.com/tingerrr/masters-thesis\") with output directory \n"
2024-07-17T11:19:53.991 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:53Z INFO  tinymist::actor::render] RenderActor: validating document for export mode Never title is false\n"
2024-07-17T11:19:53.991 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:53Z INFO  tinymist::actor::cluster] received diagnostics from primary: diag(Some(0))\n"
2024-07-17T11:19:54.002 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::actor::typ_server] CompileServerActor: evict compilation cache in 11.00301ms\n"
2024-07-17T11:19:54.059 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::server::lsp] notifying textDocument/didChange - at Instant { tv_sec: 7378, tv_nsec: 10324556 }\n"
2024-07-17T11:19:54.060 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::server::lsp] notifing textDocument/didChange succeeded in 732.79µs\n"
2024-07-17T11:19:54.060 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  typst_ts_compiler::service::diag::console] /src/de/thesis.typ: compiling ...\n"
2024-07-17T11:19:54.060 helix_lsp::transport [ERROR] tinymist err <- "    \n"
2024-07-17T11:19:54.078 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  typst_ts_compiler::service::diag::console] /src/de/thesis.typ: Compilation succeeded in 18.439797ms\n"
2024-07-17T11:19:54.078 helix_lsp::transport [ERROR] tinymist err <- "    \n"
2024-07-17T11:19:54.078 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::actor::render] RenderActor: check path Some(/src/de/thesis.typ) and root Some(\"/home/tinger/Source/github.com/tingerrr/masters-thesis\") with output directory \n"
2024-07-17T11:19:54.078 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::actor::render] RenderActor: validating document for export mode Never title is false\n"
2024-07-17T11:19:54.078 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::actor::cluster] received diagnostics from primary: diag(Some(0))\n"
2024-07-17T11:19:54.091 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::actor::typ_server] CompileServerActor: evict compilation cache in 12.549945ms\n"
2024-07-17T11:19:54.884 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::server::lsp] notifying textDocument/didChange - at Instant { tv_sec: 7378, tv_nsec: 835135795 }\n"
2024-07-17T11:19:54.885 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::server::lsp] notifing textDocument/didChange succeeded in 784.38µs\n"
2024-07-17T11:19:54.885 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  typst_ts_compiler::service::diag::console] /src/de/thesis.typ: compiling ...\n"
2024-07-17T11:19:54.885 helix_lsp::transport [ERROR] tinymist err <- "    \n"
2024-07-17T11:19:54.957 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  typst_ts_compiler::service::diag::console] /src/de/thesis.typ: Compilation succeeded in 71.909134ms\n"
2024-07-17T11:19:54.957 helix_lsp::transport [ERROR] tinymist err <- "    \n"
2024-07-17T11:19:54.957 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::actor::render] RenderActor: check path Some(/src/de/thesis.typ) and root Some(\"/home/tinger/Source/github.com/tingerrr/masters-thesis\") with output directory \n"
2024-07-17T11:19:54.957 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::actor::render] RenderActor: validating document for export mode Never title is false\n"
2024-07-17T11:19:54.957 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::actor::cluster] received diagnostics from primary: diag(Some(0))\n"
2024-07-17T11:19:54.969 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:54Z INFO  tinymist::actor::typ_server] CompileServerActor: evict compilation cache in 12.154629ms\n"
2024-07-17T11:19:55.803 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  tinymist::server::lsp] notifying textDocument/didChange - at Instant { tv_sec: 7379, tv_nsec: 753935250 }\n"
2024-07-17T11:19:55.803 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  tinymist::server::lsp] notifing textDocument/didChange succeeded in 269.79µs\n"
2024-07-17T11:19:55.803 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  typst_ts_compiler::service::diag::console] /src/de/thesis.typ: compiling ...\n"
2024-07-17T11:19:55.803 helix_lsp::transport [ERROR] tinymist err <- "    \n"
2024-07-17T11:19:55.808 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  tinymist::harness] handling textDocument/completion - (304) at Instant { tv_sec: 7379, tv_nsec: 759555909 }\n"
2024-07-17T11:19:55.871 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  typst_ts_compiler::service::diag::console] /src/de/thesis.typ: Compilation succeeded in 68.101658ms\n"
2024-07-17T11:19:55.871 helix_lsp::transport [ERROR] tinymist err <- "    \n"
2024-07-17T11:19:55.871 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  tinymist::actor::render] RenderActor: check path Some(/src/de/thesis.typ) and root Some(\"/home/tinger/Source/github.com/tingerrr/masters-thesis\") with output directory \n"
2024-07-17T11:19:55.871 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  tinymist::actor::render] RenderActor: validating document for export mode Never title is false\n"
2024-07-17T11:19:55.871 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  tinymist::actor::cluster] received diagnostics from primary: diag(Some(0))\n"
2024-07-17T11:19:55.884 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  tinymist::actor::typ_server] CompileServerActor: evict compilation cache in 12.378047ms\n"
2024-07-17T11:19:55.885 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  tinymist_query::upstream::complete] continue after completing literal\n"
2024-07-17T11:19:55.887 helix_lsp::transport [ERROR] tinymist err <- "[2024-07-17T09:19:55Z INFO  tinymist::harness] handled  textDocument/completion - (304) in 78.21ms\n"

tingerrr avatar Jul 17 '24 09:07 tingerrr