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

Import items no longer being autocompleted in v0.12.8 #945

Closed
Andrew15-5 opened this issue Dec 4, 2024 · 3 comments
Closed

Import items no longer being autocompleted in v0.12.8 #945

Andrew15-5 opened this issue Dec 4, 2024 · 3 comments
Labels
bug Something isn't working completion Features about LSP completion

Comments

@Andrew15-5
Copy link
Contributor

Andrew15-5 commented Dec 4, 2024

Describe the bug

Yesterday and today, I noticed that the latest version doesn't show up any items in the completion dropdown menu (in Neovim v0.10.0) when trying to look into what a package has to offer. Pretty sure it's a regression.

#import "@preview/package:0.0.0":

Moreover, before this version I had a small issue where the items show up only if I request them after : , but it will not show them if I've already written something (e.g., : package-ite).

Package/Software version:

tinymist extension version: v0.11.0. Get it by tinymist --version in terminal.

tinymist
tinymist
Build Timestamp:     2024-12-03T14:31:25.526257462Z
Build Git Describe:  v0.12.8
Commit SHA:          27460a9c53960be8803dd0ff23e20fa9740987fd
Commit Date:         None
Commit Branch:       None
Cargo Target Triple: x86_64-unknown-linux-gnu
Typst Version:       0.12.0
Typst Source:        git+https://github.com/Myriad-Dreamin/typst.git?tag=tinymist-v0.12.0#58426a90a7ef721738a01be09793d33e55eb75a9

Logs:

tinymist server log(Output Panel -> tinymist):

logs
[START][2024-12-04 12:50:48] LSP logging initiated
[2024-12-04T09:50:48Z INFO  tinymist] tinymist version information: [["Build Timestamp", "2024-12-03T14:31:25.526257462Z"], ["Build Git Describe", "v0.12.8"], ["Commit SHA", "27460a9c53960be8803dd0ff23e20fa9740987fd"], ["Commit Date", "None"], ["Commit Branch", "None"], ["Cargo Target Triple", "x86_64-unknown-linux-gnu"], ["Typst Version", "0.12.0"], ["Typst Source", "git+https://github.com/Myriad-Dreamin/typst.git?tag=tinymist-v0.12.0#58426a90a7ef721738a01be09793d33e55eb75a9"]]
[2024-12-04T09:50:48Z INFO  tinymist] starting Language server: LspArgs {
        mirror: MirrorArgs {
            mirror: "~/tinymist-input-mirror.json",
            replay: "",
        },
        font: CompileFontArgs {
            font_paths: [],
            ignore_system_fonts: false,
        },
    }
[2024-12-04T09:50:48Z INFO  sync_lsp] handling initialize - (1) at Instant { tv_sec: 1116376, tv_nsec: 877530175 }
[2024-12-04T09:50:48Z INFO  tinymist::init] color theme: None
[2024-12-04T09:50:48Z INFO  tinymist::server] LanguageState: initialized with config Config { const_config: ConstConfig { position_encoding: Utf16, cfg_change_registration: true, notify_will_rename_files: false, tokens_dynamic_registration: false, tokens_overlapping_token_support: true, tokens_multiline_token_support: false, doc_line_folding_only: true, doc_fmt_dynamic_registration: true }, compile: CompileConfig { roots: ["/tmp"], output_path: PathPattern(""), export_pdf: Never, root_path: None, font_opts: CompileFontArgs { font_paths: [], ignore_system_fonts: false }, system_fonts: None, font_paths: [], fonts: OnceCell(Uninit), notify_status: false, periscope_args: None, typst_extra_args: Some(CompileExtraOpts { root_dir: None, entry: None, inputs: {}, font: CompileFontArgs { font_paths: [], ignore_system_fonts: false }, package: CompilePackageArgs { package_path: None, package_cache_path: None }, creation_timestamp: None, cert: None }), color_theme: None, has_default_entry_path: false, lsp_inputs: {"x-preview": "{\\"version\\":1,\\"theme\\":\\"\\"}"} }, semantic_tokens: Enable, formatter_mode: Disable, formatter_print_width: None, support_html_in_markdown: false, completion: CompletionFeat { trigger_on_snippet_placeholders: false, trigger_suggest: false, trigger_parameter_hints: false, trigger_suggest_and_parameter_hints: false, postfix: None, postfix_ufcs: None, postfix_ufcs_left: None, postfix_ufcs_right: None, postfix_snippets: None } }
[2024-12-04T09:50:48Z INFO  tinymist::actor] TypstActor: creating server for primary, entry: EntryState { rooted: true, root: Some("/tmp"), main: None }, inputs: {"x-preview": "{\\"version\\":1,\\"theme\\":\\"\\"}"}
[2024-12-04T09:50:48Z INFO  tinymist::init] creating SharedFontResolver with CompileFontArgs { font_paths: [], ignore_system_fonts: false }
[2024-12-04T09:50:48Z INFO  sync_lsp] handled  initialize - (1) in 1.48ms
starting LSP server
[2024-12-04T09:50:48Z INFO  sync_lsp] notifying initialized - at Instant { tv_sec: 1116376, tv_nsec: 963345477 }
[2024-12-04T09:50:48Z INFO  tinymist::server] server initialized
[2024-12-04T09:50:48Z INFO  sync_lsp] notifing initialized succeeded in 57.77µs
[2024-12-04T09:50:48Z INFO  sync_lsp] notifying workspace/didChangeConfiguration - at Instant { tv_sec: 1116376, tv_nsec: 963411283 }
[2024-12-04T09:50:48Z INFO  tinymist::init] color theme: None
[2024-12-04T09:50:48Z INFO  tinymist::server] new settings applied
[2024-12-04T09:50:48Z INFO  sync_lsp] notifing workspace/didChangeConfiguration succeeded in 96.65µs
[2024-12-04T09:50:48Z INFO  sync_lsp] notifying textDocument/didOpen - at Instant { tv_sec: 1116376, tv_nsec: 963577379 }
[2024-12-04T09:50:48Z INFO  tinymist::server] did open Url { scheme: "file", cannot_be_a_base: false, username: "", password: None, host: None, port: None, path: "/tmp/2024-12-04T12:42:46Z.typ", query: None, fragment: None }
[2024-12-04T09:50:48Z INFO  tinymist::server] create source: "/tmp/2024-12-04T12:42:46Z.typ"
[2024-12-04T09:50:48Z INFO  tinymist::actor::typ_client] the entry file of TypstActor(primary) is changing to EntryState { rooted: true, root: Some("/tmp"), main: Some(/2024-12-04T12:42:46Z.typ) }
[2024-12-04T09:50:48Z INFO  tinymist::server] file focused[implicit,o]: Some("/tmp/2024-12-04T12:42:46Z.typ")
[2024-12-04T09:50:48Z INFO  sync_lsp] notifing textDocument/didOpen succeeded in 93.53µs
unknown option: bundled
unknown option: main
[WARN][2024-12-04 12:50:48] ...lsp/handlers.lua:135     "The language server tinymist triggers a registerCapability handler for workspace/didChangeConfiguration despite dynamicRegistration set to false. Report upstream, this warning is harmless"
[2024-12-04T09:50:48Z INFO  sync_lsp] handling textDocument/semanticTokens/full - (2) at Instant { tv_sec: 1116377, tv_nsec: 9296327 }
SLF4J: No SLF4J providers were found.
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See https://www.slf4j.org/codes.html#noProviders for further details.
[2024-12-04T09:50:49Z INFO  tinymist::actor::editor] received status request(primary) Compiling
[2024-12-04T09:50:49Z INFO  tinymist_query::analysis::global] analysis revision 4 is created
[2024-12-04T09:50:49Z INFO  reflexo_typst::diag::console] Some(/2024-12-04T12:42:46Z.typ): compilation succeeded in 1.704529ms
[2024-12-04T09:50:49Z INFO  tinymist::actor::editor] received diagnostics from primary:4: diag(Some(0))
[2024-12-04T09:50:49Z INFO  tinymist::actor::editor] received status request(primary) CompileSuccess
[2024-12-04T09:50:49Z INFO  tinymist::task::cache] CacheEvictTask: evict cache in 19.972µs
[2024-12-04T09:50:49Z INFO  tinymist::actor::editor] received status request(primary) Compiling
[2024-12-04T09:50:49Z INFO  reflexo_typst::diag::console] Some(/2024-12-04T12:42:46Z.typ): compilation succeeded in 126.501µs
[2024-12-04T09:50:49Z INFO  tinymist::actor::editor] received diagnostics from primary:5: diag(Some(0))
[2024-12-04T09:50:49Z INFO  tinymist::actor::editor] received status request(primary) CompileSuccess
[2024-12-04T09:50:49Z INFO  tinymist::task::cache] CacheEvictTask: evict cache in 1.01µs
[2024-12-04T09:50:49Z INFO  sync_lsp] handled  textDocument/semanticTokens/full - (2) in 164.05ms
[2024-12-04T09:50:49Z INFO  sync_lsp] handling textDocument/documentHighlight - (3) at Instant { tv_sec: 1116377, tv_nsec: 493077237 }
[2024-12-04T09:50:49Z INFO  tinymist_query::analysis::global] analysis revision 5 is created
[2024-12-04T09:50:49Z INFO  sync_lsp] handled  textDocument/documentHighlight - (3) in 200.33µs
[2024-12-04T09:50:49Z INFO  tinymist_query::analysis::global] analysis revision 0 is dropped
[2024-12-04T09:50:49Z INFO  sync_lsp] notifying $/cancelRequest - at Instant { tv_sec: 1116377, tv_nsec: 507381579 }
[2024-12-04T09:50:49Z WARN  sync_lsp] unhandled notification: $/cancelRequest
[2024-12-04T09:50:49Z INFO  sync_lsp] handling textDocument/documentHighlight - (4) at Instant { tv_sec: 1116377, tv_nsec: 507909338 }
[2024-12-04T09:50:49Z INFO  sync_lsp] handled  textDocument/documentHighlight - (4) in 153.21µs
[2024-12-04T09:50:50Z INFO  sync_lsp] handling textDocument/inlayHint - (5) at Instant { tv_sec: 1116378, tv_nsec: 965031564 }
[2024-12-04T09:50:50Z INFO  sync_lsp] handled  textDocument/inlayHint - (5) in 175.49µs
[2024-12-04T09:50:50Z INFO  sync_lsp] handling textDocument/foldingRange - (6) at Instant { tv_sec: 1116379, tv_nsec: 9934286 }
[2024-12-04T09:50:50Z INFO  sync_lsp] handled  textDocument/foldingRange - (6) in 90.44µs
[2024-12-04T09:50:51Z INFO  sync_lsp] handling textDocument/completion - (7) at Instant { tv_sec: 1116379, tv_nsec: 518584502 }
[2024-12-04T09:50:51Z INFO  sync_lsp] handled  textDocument/completion - (7) in 4.28ms

Additional context

tinymist-input-mirror.json

In the logs, there is a warning:

The language server tinymist triggers a registerCapability handler for workspace/didChangeConfiguration despite dynamicRegistration set to false. Report upstream, this warning is harmless

@Eric-Song-Nop Eric-Song-Nop added bug Something isn't working completion Features about LSP completion labels Dec 5, 2024
@Eric-Song-Nop
Copy link
Collaborator

Eric-Song-Nop commented Dec 5, 2024

66fff06 is the source of the later issue

@Eric-Song-Nop
Copy link
Collaborator

#714 introduced the first error
@Myriad-Dreamin may you check this?

@Myriad-Dreamin
Copy link
Owner

fixed by #949.

The language server tinymist triggers a registerCapability handler for workspace/didChangeConfiguration despite dynamicRegistration set to false. Report upstream, this warning is harmless

This is exactly the #921.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working completion Features about LSP completion
Projects
None yet
Development

No branches or pull requests

3 participants