Closed
Description
For instance when asking for code actions on caféx
, I get no suggestions and see this in the lsp logs
2025-04-18T17:25:32.048 helix_lsp::transport [ERROR] err: <- Other(failed to send a message to server
Caused by:
channel closed)
2025-04-18T17:25:32.048 helix_lsp::transport [ERROR] codebook err: <- StreamClosed
2025-04-18T17:25:43.417 helix_lsp::transport [ERROR] codebook err <- "\n"
2025-04-18T17:25:43.418 helix_lsp::transport [ERROR] codebook err <- "thread 'tokio-runtime-worker' panicked at /Users/divarvel/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/spellbook-0.3.1/src/suggester.rs:442:21:\n"
2025-04-18T17:25:43.418 helix_lsp::transport [ERROR] codebook err <- "byte index 4 is not a char boundary; it is inside 'é' (bytes 3..5) of `caféx`\n"
2025-04-18T17:25:43.418 helix_lsp::transport [ERROR] codebook err <- "note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace\n"
2025-04-18T17:25:43.418 helix_lsp::transport [ERROR] codebook err <- "[2025-04-18T15:25:43Z ERROR codebook_lsp::lsp] Error getting suggestions for word 'caféx' in file '/Users/divarvel/file.md'\n"
2025-04-18T17:25:43.418 helix_lsp::transport [ERROR] codebook err <- " Error: task 56 panicked with message \"byte index 4 is not a char boundary; it is inside 'é' (bytes 3..5) of `caféx`\"\n"
I assume it’s because codebook does not handle multi-byte chars. The panic actually occurs within spellbook but I’m not sure whether the error is within spellbook or if it’s due to the way codebook uses it. I see multi-byte chars in spellbook tests, which could indicate the issue is in codebook
Metadata
Metadata
Assignees
Labels
No labels