-
-
Notifications
You must be signed in to change notification settings - Fork 47
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
Code completion stops working #7
Comments
Thanks, that's the stack trace I've never got to occur in developer mode |
after half an hour of coding it did not crash, so probably this is fixed now |
Not working for me, started coding and it promptly failed within a few minutes. Too update do I just need to do a git pull, npm install and the .node compile thing? The developer tools doesn't look super useful, I just see this:
Anything I can do to troubleshoot let me know. |
Have a look at this link (microsoft/vscode#160) and search for oncancel, there is a post by DerTolleEmil that describes exactly what I am experiencing, maybe the issue is with vscode rather then code-d? |
Hmm actually I dont know if thats really the issue. Im gonna add some debug logs to the console so its easier to find the problem |
OK I've added some debug logs now. I also fixed some rejects which might actually fix the issue. Can you try them? |
assuming fixed |
Sorry for the delay, I'm in a different timezone and only code in D as a hobby so evening is when I typically can test things. I'm still having issues, the code completion stops working at some point. Here is what I see in the log:
|
So is just completion using DCD broken or does it hang up at "Loading..." in the auto complete? If its the former check if dcd-server is running (the process). If its the latter check if workspace-d and dcd-server are running. If both are running correctly there should actually be no problem. So that would be very weird |
Both workspace-d and dcd-server are running, however I wonder if dcd-server is hanging. When I try to run dcd-client manually I get the following:
|
oh thats weird. Maybe its DCD's fault then? Try |
Same exception when I try your line, looks to be an issue with dcd-server. I'll try doing a pull from dcd-server and rebuilding it to see if anything changes with the latest. |
We should also put an issue on their github page if its still there. However we need to find out a way to reproduce it |
If I kill dcd-server manually and restart it, will workspace-d still work with the version I started? This way I can at least see what it is outputting. Or alternatively, is there a way to have workspace-d capture it's output? |
workspace-d uses stdout to pass around information. However it logs the stderr. So I can add debug messages there |
ok it's not DCD's fault. That error message happens when the server is not running. So the process was running but the server on it was dead. I have no idea why that happens |
I'm confused, isn't it DCD's responsibility to manage the server unless workspace-d is doing something weird with dcd-server as a child process? Anything I can do to help debug this feel free to let me know. |
Im gonna add redirecting stderr output from dcd to workspace-d, so the console shows what the server complains about |
Somehow I can't build workspace-d with dmd 2.069.2 anymore
|
I did a pull on workspace-d and it is compiling fine for me using the dmd 2.069.2-2 Arch linux package. Is there anything I can test for you? |
So when I started vscode, I noticed that code completion wasn't working. I see the following in the Developer Tools output:
|
looks like it loaded properly. Can you confirm that int foo;
void bar()
{
fo| |
The directory /home/gnunn/.dub/packages/gtk-d-3.2.1/src/ exists, everything except gtk stuff works fine, I see completion on my project classes and structs. |
did you use renamed selective imports? Thats only fixed in the very most recent commit of DCD |
Correction, only the classes and structs in the current file resolve, classes in other files do not resolve. Anything gx. is my stuff. I do use selective imports but it doesn't cause everything to fail, just the items that are selectively imported.
|
What does your folder structure in your project look like? |
I follow Java conventions, so each module is in the path of the module name, i.e. gx.gtk.utils is in the folder gx/gtk/utils |
Discussed and fixed in IRC |
I'm noticing that from time to time code completion stops working and I have to restart vscode to get it working again. Not sure if this is related to issue #5 or not, but I also see this exception in the developer tools.
TypeError: Cannot read property 'length' of undefined: TypeError: Cannot read property 'length' of undefined
at t.e.validatePosition (/opt/visual-studio-code/resources/app/out/vs/workbench/node/pluginHostProcess.js:17:915)
at t.e.getWordRangeAtPosition (/opt/visual-studio-code/resources/app/out/vs/workbench/node/pluginHostProcess.js:17:1029)
at /home/gnunn/.vscode/extensions/code-d/out/src/workspace-d.js:214:42
at Array.forEach (native)
at /home/gnunn/.vscode/extensions/code-d/out/src/workspace-d.js:213:24
at process._tickCallback (node.js:368:9)
The text was updated successfully, but these errors were encountered: