RustAutoComplete
RustAutoComplete copied to clipboard
Creates 20+ temp files and doesn't delete them.
I noticed all of these temp files (tmp[random chars]) being created beside my source files. They were multiplying pretty fast. I can see it starting when the autocomplete popup is shown, and the more you type, the more it creates. They aren't being deleted though. If I close Sublime Text (version 3065) they are still there. Disabling 'RustAutoComplete' stops them from being created.
Any ideas on how to remedy this? I do like RustAutoComplete. It works fine except for the this one thing.
What platform are you running on?
I'm running on linux (specifically Kubuntu 14.04.1), but I figured out the problem. I should've paid more attention to the Sublime Text console messages. It couldn't find the racer executable. Even though racer is in my $PATH, I had set the config to {"racer": "racer"}, which I thought would point to my symlink ~/.local/bin/racer, but it wasn't finding it. I gave it a full path to my symlinked racer executable (/home/cj/.local/bin/racer) and it now works and deletes the tmp* files. I don't see them being created either though, but that could be because it's too fast.
So, no racer meant it was creating a bunch of temporary files and not deleting them. I haven't looked into the internal workings of RustAutoComplete to see why that is.
Had the same thing happen on OS X. Also had racer in my $PATH but ended up with a lot of tmp files. Did as @welbornprod described, changed the settings file so it had the full path and now everything seems to work.
Specifying the full path to racer fixes the issue for me.
This also happens to me on Gentoo GNU/Linux when I don't specify the full path to racer, but racer is in my PATH. This problem goes away when I use the full path to racer.
Since this is figured out, this issue should be closed, maybe with a PR that updates the README file?
+1 it should be made clearer in the README file
+1 I've had this issue too
Specifying the full path to racer fixes the issue for me too on Windows.
{
// racer.exe
"racer": "C:/Windows/System32/racer.exe",
// rust
"search_paths": [ "C:/Rust/src/src"
]
}
I'm on Mac here, can confirm that the plugin fails to find find racer in $PATH, but when given a absolute path to a symlink to racer, it will work. +1 to not changing the README, but to fix the way, $PATH get's evaluated
It is a pain.

+1
Unfortunately I don't have time to maintain this project right now. If anyone else is interested, I'd be happy to transfer the project to a new maintainer?
@glennw I sent you a private message on Reddit.
Is this project still maintained, @defuz? The temp files should not be needed when your run racer in daemon mode.
@sanmai-NL
Sorry for late response. I have implemented the use of daemon mode in separate branch:
https://github.com/defuz/RustAutoComplete/blob/daemon-mode/RustAutoComplete.py
It works well on OS X (and, I think, on Linux). I have not tested it on Windows yet.
Unfortunately, the ability to pass content via stdin was merged to Racer repository only three days ago, and it has not been published yet.
https://github.com/phildawes/racer/pull/467
I want to wait until it is published in the cargo and then update the plugin. Once again, sorry it took so long to answer.
Sorry, cannot understand from the thread how to resolve the issue. Have RustAutoComplete plugin installed in Sublime 3 and it creates a lot of temp files in src folder. What should I do to get rid of those?
@kirhgoff Ensuring that your path to racer is a fully explicit path seems to resolve it.
Thank you, had to read README more thoroughly, it does work for me now