-
Notifications
You must be signed in to change notification settings - Fork 46
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
Let's support Windows #104
Comments
It sounds like you're experiencing two independent problems (though I may be wrong.) First, the perpetual parsing problem... One possibility is that It's also possible, of course, that |
For the It's also possible that all of the If you check everything and it still look like you should be getting load requests, the next thing to check is the HTTP traffic to |
But just to be clear, it's |
Hi, I found that on Windows emacs will freeze when opening any cpp file... I added the following lines into my config: (custom-set-variables It seems that the python process is started and listening to a local port but the ycmd server is not started correctly(If it started correctly I will get a 404 when hitting localhost:port but I can't hit it when it's stared by emacs). I already put the pyd and libclang.dll files into the ycmd folder, do you know what's happening here? |
Interesting. If you run that command (i.e. |
Sorry I just check the behavior again, the ycmd server does started correctly by emacs(I must have seen the wrong port yesterday), however the emacs window freezes... I did some experiments yesterday and it seems that the buffer is always empty so I guess there might be the problem with the buffer? |
OK, thanks for following up on that. I don't have a windows machine available for testing, so I'll have to work through you a bit to try to get this sorted out. First, when you say that "the buffer is always empty", do you mean the Second, when you say that emacs freezes, do you mean that it it becomes completely unresponsive and that you have to kill it? Or are you able to use If you're able to terminate the ycmd command, then we might be able to debug this. One simple thing you can do is to print out information to the message buffer. (You mentioned that you're not familiar with elisp, so the command for printing like that is |
@r4nt Have any of your users tried running this on windows? |
Hi, thanks for your help. The buffer I mean is the "proc-buff" in line 806: I followed your instructions to add (message ...) to those 2 functions, and also print the
As you can see the "serving on..." line is missing. I also did a search in ymcd source code, and found that the "DEBUG" line is printed by log.debug, but the "serving" line is printed by the print function, so I think they may be printed to different places on Windows. |
@abingham - the only people I know who develop on Windows use VS. |
@Syndim Yes, Since the I'm grasping at straws a bit here, but one thing you could try is to take the last argument off of the call to
I'm just guessing here, but perhaps there's some windows magic happening here. In any event, I'll keep thinking about this. Without a windows machine this is quite hard to debug, so thanks for working with me on this! |
@abingham Sorry I didn't make it clearly, the
) Now I know why emacs window is freezing(since it tries to read the non-exist output for 3000 times). I think the problem is in reading the output from ycmd server. I changed code as you mentioned but it still not working :( I will have more investigation today when I'm off work. Thanks a lot to create the plugin, this plugin is the reason I want to use emace(again), I'd like to do everything I can to help resolve this problem:) |
Ah ha! I think I might see a problem :) The "serving on" line in your
but
i.e. without the colon after "on". We can try testing this by updating
to
If that fixes things, then we need to figure out why there's an extra colon in your ycmd output! |
I was typing the message by hand so I accidentally added the colon... Sorry that I mislead you... Let me summarize the problem here: when ycmd is started by hand, it works fine and prints the following lines:
However when it's started by emacs, the So ycmd.el keeps trying to read the buffer and search for that string for 3000 times, and so the emacs window is freezing for a long time and then prints the "Time out" error message. The And the I'll do some more experimentation today, hopefully I can find some useful information... |
I just did a quick experimentation, I changed the code from using the print function to use logging.debug, and the ycmd.el can read the |
You mean that you changed the code in ycmd's I wonder: if you put |
After adding |
We might be able to work around this for the short term. According to this stackoverflow answer, you might be able to make Python flush more quickly with this elisp code:
I think if you put that near the front of your emacs configuration, the problem might go away. Or you might just be able to set that in your outer environment. |
@Valloric To bring you up to speed: We're facing a problem on Windows where waitress is not printing it's "serving on http://host:port" in a timely manner. This appears to be related to flushing of |
I found that I can also add Thank you again for creating this tool! |
Ah, brilliant! I should make that the default behavior, I suppose. I'll also add note to the README. Does this get you to a state where you can use the tool then? |
Yes, the tool is working fine after I provided the global config file. But I found that the company mode is slower than vim + ycm :( |
I don't have a clue. I only boot into Windows to play Steam games. :D |
I finally had time to test everything on Windows. First of all, in Vim YCM works just fine here, so the following problems are most likely related only to your package and not YCM on Windows in general.
I use
company-ycmd
and I keep getting:Do you have any ideas why?
ycmd-extra-conf-handler
documentation says that it will by default ask whether to load.ycm_extra_conf.py
, but it never does like if it cannot find it. In Vim it searches for it bottom-up starting from the directory of the currently edited source file. Is the same true in your case? If yes, then why is it not locating.ycm_extra_conf.py
?The text was updated successfully, but these errors were encountered: