SpaceManiac / SpacemanDMM

A BYOND language smartness provider, map renderer, and more.
https://marketplace.visualstudio.com/items?itemName=platymuus.dm-langclient
GNU General Public License v3.0
83 stars 83 forks source link

Various textDocument requests fail and kill the langserver client #395

Closed ToasterBiome closed 4 months ago

ToasterBiome commented 4 months ago

Reparsing a codebase kills the connection to the langserver client: Non-SS13 codebase

Only seems to work if there's certain compilation errors? The one I got was proc not found


executable: c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\bin\dm-langserver-x64-win32.exe
commit: 9d99263bec6664d25e594915f0836c0afae5bbe5
build date: 2024-06-28
extools commit: v0.0.7
auxtools commit: v2.3.3
directory: c:\Users\baiom\source\repos\ET
workspace root: file:///c%3A/Users/baiom/source/repos/ET/
client capabilities: related_info: true, label_offset_support: true, object_tree: false

environment: c:\Users\baiom\source\repos\ET\Environment.dme
disk 0.007s - parse 0.235s - diagnostics 0.000s - total 0.244s
thread 'main' panicked at crates/dm-langserver/src/main.rs:1808:50:
called `Option::unwrap()` on a `None` value
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
[Error - 5:03:55 PM] Connection to server got closed. Server will not be restarted.
[Error - 5:03:55 PM] Request textDocument/documentSymbol failed.
Error: Connection got disposed.
    at Object.dispose (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:46604)
    at Object.dispose (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:110404)
    at O.handleConnectionClosed (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:110579)
    at O.handleConnectionClosed (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:131416)
    at t (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:108726)
    at r.invoke (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31058)
    at n.fire (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31788)
    at K (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:38417)
    at r.invoke (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31058)
    at n.fire (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31788)
    at u.fireClose (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:49613)
    at Socket.<anonymous> (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:50375)
    at Socket.emit (node:events:526:35)
    at Pipe.<anonymous> (node:net:337:12)
[Error - 5:03:55 PM] Request textDocument/colorPresentation failed.
Error: Connection got disposed.
    at Object.dispose (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:46604)
    at Object.dispose (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:110404)
    at O.handleConnectionClosed (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:110579)
    at O.handleConnectionClosed (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:131416)
    at t (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:108726)
    at r.invoke (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31058)
    at n.fire (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31788)
    at K (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:38417)
    at r.invoke (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31058)
    at n.fire (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31788)
    at u.fireClose (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:49613)
    at Socket.<anonymous> (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:50375)
    at Socket.emit (node:events:526:35)
    at Pipe.<anonymous> (node:net:337:12)
[Error - 5:03:55 PM] Request textDocument/documentLink failed.
Error: Connection got disposed.
    at Object.dispose (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:46604)
    at Object.dispose (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:110404)
    at O.handleConnectionClosed (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:110579)
    at O.handleConnectionClosed (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:131416)
    at t (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:108726)
    at r.invoke (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31058)
    at n.fire (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31788)
    at K (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:38417)
    at r.invoke (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31058)
    at n.fire (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:31788)
    at u.fireClose (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:49613)
    at Socket.<anonymous> (c:\Users\baiom\.vscode\extensions\platymuus.dm-langclient-0.2.4\dist\extension.js:2:50375)
    at Socket.emit (node:events:526:35)
    at Pipe.<anonymous> (node:net:337:12) `
SpaceManiac commented 4 months ago

Caused by 9d99263bec6664d25e594915f0836c0afae5bbe5.

Viewing files with certain structures that the Outline view chokes on started crashing instead of just producing goofy output.

Example from /tg/: https://github.com/tgstation/tgstation/blob/1caab5067200a2ef244ef53fb4c83ec2a72af241/code/modules/mining/aux_base.dm#L39