vectorgraphics / asymptote

2D & 3D TeX-Aware Vector Graphics Language
https://asymptote.sourceforge.io/
GNU General Public License v3.0
550 stars 90 forks source link

cannot start lsp server with neovim #393

Open Rainboylvx opened 1 year ago

Rainboylvx commented 1 year ago

according to neovim doc https://neovim.io/doc/user/lsp.html#lsp-quickstart

I create a minial config lsp.lua

vim.cmd([[autocmd BufNewFile,BufRead *.asy setlocal filetype=asy ]])

vim.lsp.start({
  name = 'asy lsp server',
  cmd = {'/usr/bin/asy','--lsp'}
})

then ,i use command below

nvim -u lsp.lua hello.asy

and get error

client 1 quit with exit code 0 and signal 6

my envirment os : archlinux

asymptote version

Asymptote version 2.87-4 [(C) 2004 Andy Hammerlindl, John C. Bowman, Tom Prince]

ENABLED OPTIONS:
V3D      3D vector graphics output
WebGL    3D HTML rendering
OpenGL   3D OpenGL rendering
SSBO     GLSL shader storage buffer objects
GSL      GNU Scientific Library (special functions)
FFTW3    Fast Fourier transforms
XDR      External Data Representation (portable binary file format for V3D)
CURL     URL support
LSP      Language Server Protocol
Readline Interactive history and editing
Sigsegv  Distinguish stack overflows from segmentation faults
GC       Boehm garbage collector
threads  Render OpenGL in separate thread

DISABLED OPTIONS:
Eigen    Eigenvalue library
MicroTransactionsMatterToo commented 1 year ago

Seems to be related to #394 , the language server doesn't seem to appreciate dealing with the capability information sent by editors and segfaults when parsing the JSON. Signal 6 is SIGABRT, which is typically caused by memory allocation issues.

johncbowman commented 7 months ago

Is this issue still present with Asymptote 2.87?