d-language-server / dls

A Language Server implementation for D
http://dls.dub.pm
106 stars 14 forks source link

DLS failing to start #7

Open damianday opened 6 years ago

damianday commented 6 years ago

OS: Windows 10 x64 DMD2 is in my path Fresh install of vscode dls v1.8.1

[Error - 8:31:26 AM] Starting client failed Error: Unsupported server configuration { "command": "" } at _getServerWorkingDir.then.serverWorkingDir (C:\Users\Damian.vscode\extensions\laurenttreguier.vscode-dls-1.8.1\node_modules\vscode-languageclient\lib\main.js:356:35) at

LaurentTreguier commented 6 years ago

What's your VSCode install like? Is it stable or insiders, and is it the classic system wide install or the new user level install? (I've never tested the latter)

What happens if you run dub fetch dls and dub run --arch=x86_64 dls:bootstrap in a command prompt?

damianday commented 6 years ago

VSCode Stable, it is system wide install.

Visual Code version: Version: 1.26.1 Commit: 493869ee8e8a846b0855873886fc79d480d342de Date: 2018-08-16T18:38:57.434Z Electron: 2.0.5 Chrome: 61.0.3163.100 Node.js: 8.9.3 V8: 6.1.534.41 Architecture: x64

Windows PowerShell Windows PowerShell Copyright (C) Microsoft Corporation. All rights reserved.

PS D:\dlang\Projects\legend> dub fetch dls Please note that you need to use dub run <pkgname> or add it to dependencies of your package to actually use/run it. dub does not do actual installation of packages outside of its own ecosystem. PS D:\dlang\Projects\legend> dub run --arch=x86_64 dls:bootstrap Building package dls:bootstrap in C:\Users\Damian\AppData\Local\dub\packages\dls-0.9.0\dls\bootstrap\ Running pre-generate commands for dls:i18n... Performing "debug" build using dmd for x86_64. dls:protocol 0.9.0: building configuration "library"... dls:i18n 0.9.0: building configuration "library"... dls:bootstrap 0.9.0: building configuration "application"... Linking... D:\dlang\dmd2\windows\bin\lld-link.exe: error: could not open libcmt.lib: no such file or directory Error: linker exited with status 1 dmd failed with exit code 1. PS D:\dlang\Projects\legend> dub run dls Building package dls in C:\Users\Damian\AppData\Local\dub\packages\dls-0.9.0\dls\ Fetching msgpack-d 1.0.0-beta.7 (getting selected version)... Fetching libdparse 0.8.8 (getting selected version)... Fetching emsi_containers 0.8.0-alpha.9 (getting selected version)... Fetching dub 1.10.0 (getting selected version)... Fetching dsymbol 0.3.12 (getting selected version)... Fetching libddoc 0.3.0-beta.1 (getting selected version)... Fetching inifiled 1.3.1 (getting selected version)... Fetching dscanner 0.5.8 (getting selected version)... Invalid source/import path: C:\Users\Damian\AppData\Local\dub\packages\dcd-0.9.10\dcd\bin Running pre-generate commands for dcd... Running pre-generate commands for dls:i18n... Invalid source/import path: C:\Users\Damian\AppData\Local\dub\packages\dscanner-0.5.8\dscanner\bin Running pre-generate commands for dscanner... Running pre-generate commands for dls... The system cannot find the path specified. Command failed with exit code 1

When I run the command below I can get it to link. PS D:\dlang\Projects\legend> dub run dls:bootstrap Building package dls:bootstrap in C:\Users\Damian\AppData\Local\dub\packages\dls-0.9.0\dls\bootstrap\ Running pre-generate commands for dls:i18n... Performing "debug" build using dmd for x86. dls:protocol 0.9.0: building configuration "library"... dls:i18n 0.9.0: building configuration "library"... dls:bootstrap 0.9.0: building configuration "application"... Linking... Running C:\Users\Damian\AppData\Local\dub\packages\dls-0.9.0\dls\bootstrap\dls_bootstrap.exe

My visual studio installation is: Visual Studio Community 2017 15.8.1

damianday commented 6 years ago

After running dub run dls:bootstrap it seems to be working fine now for x86, I guess the problem is related to trying to build it with x64

LaurentTreguier commented 6 years ago

Yes, apparently the new lld linker has problems with x86_64... It works fine with visual studio build tools. I'll try to work around this in the extensions.

However it's weird that dmd tries to use lld instead of visual studio if it's installed.

LaurentTreguier commented 6 years ago

The install at first launch should be fixed with vscode-dls 1.9.0

Kozzi11 commented 5 years ago

Same issue for me on ma archlinux pc

Kozzi11 commented 5 years ago

Ok for some unknown reason I have not installed dub on my system, but still it should give me better error msg

LaurentTreguier commented 5 years ago

Oh. I'll add a check for whether dub is installed just in case then

patrickkh7788 commented 5 years ago

I try this first time, dcd is download last version. open with a lot errors:

core.exception.RangeError@/Users/travis/dlang/ldc-1.13.0/bin/../import/std/utf.d(448): Range violation
----------------
??:? pure nothrow @nogc @safe int core.internal.string.numDigits!(10u).numDigits(ulong) [0x10de204f9]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x10de3b96a]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x10de3c65e]
??:? bool core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter.__xopEquals(ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter), ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter)) [0x10de1b671]
??:? pure nothrow @nogc core.exception.InvalidMemoryOperationError core.exception.staticError!(core.exception.InvalidMemoryOperationError).staticError() [0x10de1bf27]
??:? pure @safe ulong std.utf.toUCSindex!(wchar).toUCSindex(const(wchar)[], ulong) [0x10d9afd65]
??:? pure @nogc @safe ulong std.algorithm.iteration.reduce!(dls.util.document.Document.byteAtPosition(const(dls.protocol.definitions.Position)).__lambda2).reduce!(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result).reduce(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result) [0x10d9a72ed]
??:? void inifiled.readINIFile!(dscanner.analysis.config.StaticAnalysisConfig).readINIFile(ref dscanner.analysis.config.StaticAnalysisConfig, immutable(char)[]) [0x10d89fab0]
??:? std.typecons.Flag!("each").Flag std.algorithm.iteration.each!(dls.tools.analysis_tool.AnalysisTool.scanAllWorkspaces().__lambda1).each!(dls.util.uri.Uri[]).each(dls.util.uri.Uri[]) [0x10d89ef32]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*) [0x10d8b7039]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*).__lambda3(std.typecons.Nullable!(std.json.JSONValue).Nullable) [0x10d913f60]
??:? pure nothrow @safe void std.container.dlist.DList!(dls.util.disposable_fiber.DisposableFiber).DList.removeFront() [0x10d8bc65c]
??:? pure @safe ulong std.conv.to!(ulong).to!(immutable(char)[]).to(immutable(char)[]) [0x10d8bbd1f]
??:? nothrow void core.thread.thread_scanAll(scope void delegate(void*, void*) nothrow).__lambda2!(core.thread.ScanType, void*, void*).__lambda2(core.thread.ScanType, void*, void*) [0x10de24913]
[Info  - 1:17:43 PM] Connection to server got closed. Server will restart.
core.exception.RangeError@/Users/travis/dlang/ldc-1.13.0/bin/../import/std/utf.d(448): Range violation
----------------
??:? pure nothrow @nogc @safe int core.internal.string.numDigits!(10u).numDigits(ulong) [0x10313c4f9]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x10315796a]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x10315865e]
??:? bool core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter.__xopEquals(ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter), ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter)) [0x103137671]
??:? pure nothrow @nogc core.exception.InvalidMemoryOperationError core.exception.staticError!(core.exception.InvalidMemoryOperationError).staticError() [0x103137f27]
??:? pure @safe ulong std.utf.toUCSindex!(wchar).toUCSindex(const(wchar)[], ulong) [0x102ccbd65]
??:? pure @nogc @safe ulong std.algorithm.iteration.reduce!(dls.util.document.Document.byteAtPosition(const(dls.protocol.definitions.Position)).__lambda2).reduce!(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result).reduce(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result) [0x102cc32ed]
??:? void inifiled.readINIFile!(dscanner.analysis.config.StaticAnalysisConfig).readINIFile(ref dscanner.analysis.config.StaticAnalysisConfig, immutable(char)[]) [0x102bbbab0]
??:? std.typecons.Flag!("each").Flag std.algorithm.iteration.each!(dls.tools.analysis_tool.AnalysisTool.scanAllWorkspaces().__lambda1).each!(dls.util.uri.Uri[]).each(dls.util.uri.Uri[]) [0x102bbaf32]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*) [0x102bd3039]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*).__lambda3(std.typecons.Nullable!(std.json.JSONValue).Nullable) [0x102c2ff60]
??:? pure nothrow @safe void std.container.dlist.DList!(dls.util.disposable_fiber.DisposableFiber).DList.removeFront() [0x102bd865c]
??:? pure @safe ulong std.conv.to!(ulong).to!(immutable(char)[]).to(immutable(char)[]) [0x102bd7d1f]
??:? nothrow void core.thread.thread_scanAll(scope void delegate(void*, void*) nothrow).__lambda2!(core.thread.ScanType, void*, void*).__lambda2(core.thread.ScanType, void*, void*) [0x103140913]
[Info  - 1:17:48 PM] Connection to server got closed. Server will restart.
core.exception.RangeError@/Users/travis/dlang/ldc-1.13.0/bin/../import/std/utf.d(448): Range violation
----------------
??:? pure nothrow @nogc @safe int core.internal.string.numDigits!(10u).numDigits(ulong) [0x110ce24f9]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x110cfd96a]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x110cfe65e]
??:? bool core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter.__xopEquals(ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter), ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter)) [0x110cdd671]
??:? pure nothrow @nogc core.exception.InvalidMemoryOperationError core.exception.staticError!(core.exception.InvalidMemoryOperationError).staticError() [0x110cddf27]
??:? pure @safe ulong std.utf.toUCSindex!(wchar).toUCSindex(const(wchar)[], ulong) [0x110871d65]
??:? pure @nogc @safe ulong std.algorithm.iteration.reduce!(dls.util.document.Document.byteAtPosition(const(dls.protocol.definitions.Position)).__lambda2).reduce!(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result).reduce(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result) [0x1108692ed]
??:? void inifiled.readINIFile!(dscanner.analysis.config.StaticAnalysisConfig).readINIFile(ref dscanner.analysis.config.StaticAnalysisConfig, immutable(char)[]) [0x110761ab0]
??:? std.typecons.Flag!("each").Flag std.algorithm.iteration.each!(dls.tools.analysis_tool.AnalysisTool.scanAllWorkspaces().__lambda1).each!(dls.util.uri.Uri[]).each(dls.util.uri.Uri[]) [0x110760f32]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*) [0x110779039]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*).__lambda3(std.typecons.Nullable!(std.json.JSONValue).Nullable) [0x1107d5f60]
??:? pure nothrow @safe void std.container.dlist.DList!(dls.util.disposable_fiber.DisposableFiber).DList.removeFront() [0x11077e65c]
??:? pure @safe ulong std.conv.to!(ulong).to!(immutable(char)[]).to(immutable(char)[]) [0x11077dd1f]
??:? nothrow void core.thread.thread_scanAll(scope void delegate(void*, void*) nothrow).__lambda2!(core.thread.ScanType, void*, void*).__lambda2(core.thread.ScanType, void*, void*) [0x110ce6913]
[Info  - 1:17:52 PM] Connection to server got closed. Server will restart.
core.exception.RangeError@/Users/travis/dlang/ldc-1.13.0/bin/../import/std/utf.d(448): Range violation
----------------
??:? pure nothrow @nogc @safe int core.internal.string.numDigits!(10u).numDigits(ulong) [0x1099a24f9]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x1099bd96a]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x1099be65e]
??:? bool core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter.__xopEquals(ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter), ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter)) [0x10999d671]
??:? pure nothrow @nogc core.exception.InvalidMemoryOperationError core.exception.staticError!(core.exception.InvalidMemoryOperationError).staticError() [0x10999df27]
??:? pure @safe ulong std.utf.toUCSindex!(wchar).toUCSindex(const(wchar)[], ulong) [0x109531d65]
??:? pure @nogc @safe ulong std.algorithm.iteration.reduce!(dls.util.document.Document.byteAtPosition(const(dls.protocol.definitions.Position)).__lambda2).reduce!(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result).reduce(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result) [0x1095292ed]
??:? void inifiled.readINIFile!(dscanner.analysis.config.StaticAnalysisConfig).readINIFile(ref dscanner.analysis.config.StaticAnalysisConfig, immutable(char)[]) [0x109421ab0]
??:? std.typecons.Flag!("each").Flag std.algorithm.iteration.each!(dls.tools.analysis_tool.AnalysisTool.scanAllWorkspaces().__lambda1).each!(dls.util.uri.Uri[]).each(dls.util.uri.Uri[]) [0x109420f32]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*) [0x109439039]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*).__lambda3(std.typecons.Nullable!(std.json.JSONValue).Nullable) [0x109495f60]
??:? pure nothrow @safe void std.container.dlist.DList!(dls.util.disposable_fiber.DisposableFiber).DList.removeFront() [0x10943e65c]
??:? pure @safe ulong std.conv.to!(ulong).to!(immutable(char)[]).to(immutable(char)[]) [0x10943dd1f]
??:? nothrow void core.thread.thread_scanAll(scope void delegate(void*, void*) nothrow).__lambda2!(core.thread.ScanType, void*, void*).__lambda2(core.thread.ScanType, void*, void*) [0x1099a6913]
[Info  - 1:17:56 PM] Connection to server got closed. Server will restart.
core.exception.RangeError@/Users/travis/dlang/ldc-1.13.0/bin/../import/std/utf.d(448): Range violation
----------------
??:? pure nothrow @nogc @safe int core.internal.string.numDigits!(10u).numDigits(ulong) [0x1066364f9]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x10665196a]
??:? pure nothrow @nogc @safe uint rt.cover.max!(uint).max(uint, uint) [0x10665265e]
??:? bool core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter.__xopEquals(ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter), ref const(core.demangle.mangle!(int function(scope int delegate(immutable(object.ModuleInfo*)))).mangle(const(char)[], char[]).DotSplitter)) [0x106631671]
??:? pure nothrow @nogc core.exception.InvalidMemoryOperationError core.exception.staticError!(core.exception.InvalidMemoryOperationError).staticError() [0x106631f27]
??:? pure @safe ulong std.utf.toUCSindex!(wchar).toUCSindex(const(wchar)[], ulong) [0x1061c5d65]
??:? pure @nogc @safe ulong std.algorithm.iteration.reduce!(dls.util.document.Document.byteAtPosition(const(dls.protocol.definitions.Position)).__lambda2).reduce!(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result).reduce(ulong, std.range.iota!(const(ulong), const(ulong)).iota(const(ulong), const(ulong)).Result) [0x1061bd2ed]
??:? void inifiled.readINIFile!(dscanner.analysis.config.StaticAnalysisConfig).readINIFile(ref dscanner.analysis.config.StaticAnalysisConfig, immutable(char)[]) [0x1060b5ab0]
??:? std.typecons.Flag!("each").Flag std.algorithm.iteration.each!(dls.tools.analysis_tool.AnalysisTool.scanAllWorkspaces().__lambda1).each!(dls.util.uri.Uri[]).each(dls.util.uri.Uri[]) [0x1060b4f32]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*) [0x1060cd039]
??:? void dls.protocol.handlers.pushHandler!(void function(std.json.JSONValue)*).pushHandler(const(immutable(char)[]), void function(std.json.JSONValue)*).__lambda3(std.typecons.Nullable!(std.json.JSONValue).Nullable) [0x106129f60]
??:? pure nothrow @safe void std.container.dlist.DList!(dls.util.disposable_fiber.DisposableFiber).DList.removeFront() [0x1060d265c]
??:? pure @safe ulong std.conv.to!(ulong).to!(immutable(char)[]).to(immutable(char)[]) [0x1060d1d1f]
??:? nothrow void core.thread.thread_scanAll(scope void delegate(void*, void*) nothrow).__lambda2!(core.thread.ScanType, void*, void*).__lambda2(core.thread.ScanType, void*, void*) [0x10663a913]
[Error - 1:18:00 PM] Connection to server got closed. Server will not be restarted.
LaurentTreguier commented 5 years ago

@patrickkh7788 this is probably another problem; I'm opening a separate issue for this: #20