Git Product home page Git Product logo

racerd's Introduction

racerd

JSON/HTTP Server based on racer for adding Rust support to editors and IDEs

Build Status Build status

racerd_ycm

YouCompleteMe in vim powered by racerd

Documentation

Features

  • Find definition & list completions support via racer
  • Searches rust standard library and dependency crates
  • HMAC authentication
  • Usable as both library and executable
  • Library API offers direct calls to avoid HTTP overhead

racerd's People

Contributors

anp avatar dpzmick avatar emilio avatar henriiik avatar juchiast avatar jwilm avatar kings-way avatar laurence6 avatar little-dude avatar micbou avatar mlalic avatar onur avatar rillian avatar senzaki avatar sfackler avatar valloric avatar yetanotherminion avatar zowens avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

racerd's Issues

src/http/mod.rs:94 on os X 10.11.6

chain.link_before(Write::::one(Box::new(engine)));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait persistent::PersistentInto<std::sync::Arc<std::sync::Mutex<std::boxed::Box<engine::SemanticEngine + std::marker::Sync + std::marker::Send + 'static>>>> is not implemented for std::boxed::Box<E>

expose context and kind in /find_definition

The API does not expose context and kind for the POST /find_definition endpoint, unlike the corresponding racer CLI command. Is this something that you would consider adding?

Background:

Yesterday i started to port my VSCode extension from racer CLI to racerd. VSCode allows you to display information when the user hovers over something as well as showing the function signature while entering function arguments.

Kind and context on hover (although it does not show up, the cursor is hovering over the hello function call):
racer-hover

Context as function signature (although it does not show up, the carret is between the parens of the hello function call):
racer-signature

Caching too aggressively

The source cache doesn't detect changes on disk. This is ok as long as files are editted within the same vim session, but, at least for me, that's not always the case. This leads to a stale cache where changes that are on disk aren't reflected in completions or when using find_definition.

Failing to compile

Fails to compile with:

Compiling libracerd v0.3.1 (file:///home/.../nvim/plugged/YouCompleteMe/third_party/ycmd/third_party/racerd)
error: type alias is never used: `ListCompletionsResponse`
   --> /home/.../nvim/plugged/YouCompleteMe/third_party/ycmd/third_party/racerd/target/release/build/libracerd-38cb6b871b76c55b/out/http/completion.rs:281:1
    |
281 | type ListCompletionsResponse = Vec<CompletionResponse>;
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
note: lint level defined here
   --> src/lib.rs:9:9
    |
9   | #![deny(warnings)]
    |         ^^^^^^^^

error: aborting due to previous error

error: Could not compile `libracerd`.

To learn more, run the command again with --verbose.

This is on

$ rustc -V
rustc 1.15.0-nightly (71c06a56a 2016-12-18)

Compilation error

I tried your PR ycm-core/ycmd#268 on Windows but I get the following error when compiling racerd:

Compiling syntex_syntax v0.20.0
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:774:29: 774:40 error: use of undeclared type name `libc::DWORD` [E0412]
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:774     const STD_ERROR_HANDLE: libc::DWORD = -12i32 as libc::DWORD;
                                                                                                                                                                 ^~~~~~~~~~~
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:774:29: 774:40 help: run `rustc --explain E0412` to see a detailed explanation
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:774:53: 774:64 error: use of undeclared type name `libc::DWORD` [E0412]
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:774     const STD_ERROR_HANDLE: libc::DWORD = -12i32 as libc::DWORD;
                                                                                                                                                                                         ^~~~~~~~~~~
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:774:53: 774:64 help: run `rustc --explain E0412` to see a detailed explanation
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:776:32: 776:43 error: use of undeclared type name `libc::DWORD` [E0412]
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:776         fn GetStdHandle(which: libc::DWORD) -> libc::HANDLE;
                                                                                                                                                                    ^~~~~~~~~~~
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:776:32: 776:43 help: run `rustc --explain E0412` to see a detailed explanation
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:776:48: 776:60 error: use of undeclared type name `libc::HANDLE` [E0412]
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:776         fn GetStdHandle(which: libc::DWORD) -> libc::HANDLE;
                                                                                                                                                                                    ^~~~~~~~~~~~
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:776:48: 776:60 help: run `rustc --explain E0412` to see a detailed explanation
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:777:43: 777:55 error: use of undeclared type name `libc::HANDLE` [E0412]
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:777         fn GetConsoleMode(hConsoleHandle: libc::HANDLE,
                                                                                                                                                                               ^~~~~~~~~~~~
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:777:43: 777:55 help: run `rustc --explain E0412` to see a detailed explanation
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:778:35: 778:48 error: use of undeclared type name `libc::LPDWORD` [E0412]
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:778                           lpMode: libc::LPDWORD) -> libc::BOOL;
                                                                                                                                                                       ^~~~~~~~~~~~~
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:778:35: 778:48 help: run `rustc --explain E0412` to see a detailed explanation
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:778:53: 778:63 error: use of undeclared type name `libc::BOOL` [E0412]
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:778                           lpMode: libc::LPDWORD) -> libc::BOOL;
                                                                                                                                                                                         ^~~~~~~~~~
C:/Users/micbou/.multirust/toolchains/beta/cargo\registry\src\github.com-0a35038f75765ae4\syntex_syntax-0.20.0\src\diagnostic.rs:778:53: 778:63 help: run `rustc --explain E0412` to see a detailed explanation
error: aborting due to 7 previous errors
Could not compile `syntex_syntax`.

I think you need to update the racer dependency because syntex_syntax compiles fine when using the official racer repository.

Idea: Adopt Common Language Service Protocol

This is just an idea, but wouldn't it speed up tool adoption to adopt the language service protocol that is now used by Visual Studio Code and Eclipse Ché?

There's already a few languages supported and after trying out the Java-Integration vor Visual Studio Code yesterday (see their implementation issue) I have to say the ergonomics from a user perspective are really good.

My assumption is that adopting this protocol could speed up adoption within all those editors and IDE's considerably making Rust a first-class citizen. Of course if this proves useful then this could be the lingua franca for racer directly further reducing the moving parts, dreaming here...

Handle PoisonError when locking mutex

In the case that a racer call panics, the racerd::engine::Racer mutex becomes poisoned. The mutex protects a data structure which shouldn't panic during mutation, and it should be safe to just handle the poison error.

The server presently just returns 500 Errors after the mutex has been poisoned. We need to either handle this error (which should be safe) or abort the process.

Server appears to still have lock poisoning issues

#9's closed, but it looks like the issue wasn't fully resolved. Here's the top chunk of stderr output. The PoisonError stack trace repeats from there. I'm running ea325c3

bogofile:3:1: 3:2 error: expected one of `;` or `as`, found `#`
bogofile:3 #[derive(Deserialize)]
           ^
bogofile:3:1: 3:2 error: expected one of `;` or `as`, found `#`
bogofile:3 #[derive(Deserialize)]
           ^
bogofile:1:13: 1:14 error: expected one of `::`, `;`, or `as`, found `{`
bogofile:1 use serde::d{Deserialize, Deserializer};
                       ^
bogofile:3:1: 3:2 error: expected one of `;` or `as`, found `#`
bogofile:3 #[derive(Deserialize)]
           ^
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
bogofile:0:1: 0:1 error: unexpected token: `<eof>`
thread '<unnamed>' panicked at 'called `Option::unwrap()` on a `None` value', ../src/libcore/option.rs:366
stack backtrace:
   1:     0x56006ae87b30 - sys::backtrace::tracing::imp::write::h1fe79f3711caca0eUnt
   2:     0x56006ae8a075 - panicking::log_panic::_<closure>::closure.39701
   3:     0x56006ae89ac1 - panicking::log_panic::hffc6d029fed602571nx
   4:     0x56006ae76203 - sys_common::unwind::begin_unwind_inner::h7045c1c64d9ab8edYgs
   5:     0x56006ae76878 - sys_common::unwind::begin_unwind_fmt::h40ee994bfe85f7a54fs
   6:     0x56006ae87201 - rust_begin_unwind
   7:     0x56006aeb802f - panicking::panic_fmt::h4c8d12e3c05f3b8cZEK
   8:     0x56006aeb3d68 - panicking::panic::hb8a57f0c8013c90awDK
   9:     0x56006ac5ffb9 - typeinf::get_type_of_match::h690bc0039f97ab31Jnd
  10:     0x56006ac55815 - ast::_<impl>::visit_expr::h2339d598ffc95851dbc
  11:     0x56006ac3e964 - ast::get_type_of::h63c35bfeb3ef3429xTc
  12:     0x56006ac3b211 - core::complete_from_file::hd3cf610ec43f9051pZa
  13:     0x56006ac32181 - engine::racer::_<impl>::list_completions::h480dbab7125a2668S3a
  14:     0x56006ac2c750 - http::completion::list::h29a4c4cc7aeb4fb1Ita
  15:     0x56006abfdd4b - middleware::_<impl>::handle::handle::h10661862516855150861
  16:     0x56006ae20ba0 - middleware::_<impl>::handle::h9f57b88dbf2e8eb4Coa
  17:     0x56006add23c5 - router::_<impl>::handle_method::h8633d57a725f79b1iia
  18:     0x56006add3993 - router::_<impl>::handle::ha4490428d338984flja
  19:     0x56006ae207e8 - middleware::_<impl>::continue_from_handler::hb66b53442808508drma
  20:     0x56006ae1e87a - middleware::_<impl>::handle::h82115d9a4fc77891yia
  21:     0x56006ac11dd9 - hyper::server::listener::spawn_with::_<closure>::closure.14072
  22:     0x56006ac1073a - sys_common::unwind::try::try_fn::try_fn::h6106811361401582808
  23:     0x56006ae87068 - __rust_try
  24:     0x56006ae83c6b - sys_common::unwind::try::inner_try::h0c3b0e63f018cc29wds
  25:     0x56006ac146d8 - boxed::_<impl>::call_box::call_box::h8677866214614970001
  26:     0x56006ae88b63 - sys::thread::_<impl>::new::thread_start::h85eb4d682b5d5d4ffGw
  27:     0x7f206d78a4a3 - start_thread
  28:     0x7f206df8b13c - clone
  29:                0x0 - <unknown>
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "PoisonError { inner: .. }"', ../src/libcore/result.rs:738
stack backtrace:
   1:     0x56006ae87b30 - sys::backtrace::tracing::imp::write::h1fe79f3711caca0eUnt
   2:     0x56006ae8a075 - panicking::log_panic::_<closure>::closure.39701
   3:     0x56006ae89ac1 - panicking::log_panic::hffc6d029fed602571nx
   4:     0x56006ae76203 - sys_common::unwind::begin_unwind_inner::h7045c1c64d9ab8edYgs
   5:     0x56006ae76878 - sys_common::unwind::begin_unwind_fmt::h40ee994bfe85f7a54fs
   6:     0x56006ae87201 - rust_begin_unwind
   7:     0x56006aeb802f - panicking::panic_fmt::h4c8d12e3c05f3b8cZEK
   8:     0x56006ac2edf6 - http::completion::list::h29a4c4cc7aeb4fb1Ita
   9:     0x56006abfdd4b - middleware::_<impl>::handle::handle::h10661862516855150861
  10:     0x56006ae20ba0 - middleware::_<impl>::handle::h9f57b88dbf2e8eb4Coa
  11:     0x56006add23c5 - router::_<impl>::handle_method::h8633d57a725f79b1iia
  12:     0x56006add3993 - router::_<impl>::handle::ha4490428d338984flja
  13:     0x56006ae207e8 - middleware::_<impl>::continue_from_handler::hb66b53442808508drma
  14:     0x56006ae1e87a - middleware::_<impl>::handle::h82115d9a4fc77891yia
  15:     0x56006ac11dd9 - hyper::server::listener::spawn_with::_<closure>::closure.14072
  16:     0x56006ac1073a - sys_common::unwind::try::try_fn::try_fn::h6106811361401582808
  17:     0x56006ae87068 - __rust_try
  18:     0x56006ae83c6b - sys_common::unwind::try::inner_try::h0c3b0e63f018cc29wds
  19:     0x56006ac146d8 - boxed::_<impl>::call_box::call_box::h8677866214614970001
  20:     0x56006ae88b63 - sys::thread::_<impl>::new::thread_start::h85eb4d682b5d5d4ffGw
  21:     0x7f206d78a4a3 - start_thread
  22:     0x7f206df8b13c - clone
  23:                0x0 - <unknown>

http handlers are hard coded to racer

Calls here, here, and here all assume that Racer is being used as the SemanticEngine. The http serve function should be refactored to accept a SemanticEngine, like so.

pub fn serve<T: SemanticEngine>(config: &Config, engine: T) -> Result<Server>

The engine should be initialized outside of the serve function. The engine must be available in the request handlers. This can probably be achieved using iron-framework's typemap middleware as seen in this examplehttps://github.com/iron/iron/blob/master/examples/time.rs). The bin/racerd.rs args should be updated to specify --engine with a default of racer. The tests would need to be updated as well.

some completion is wrong

I'm vim with YCM and racer-completer and I have a problem about completion.
see screenshots below and check out differences.

the version of 0.1.0
the correct result
expected
expected2

the version >= 0.2
wrong
wrong2
this result is surely wrong because std::process::Command structure (not object) cannot have member functions having self parameter. right?

I tried to change the version of racer and racerd respectively and I found the problem occurred on the version >= 0.2.
I hope it will be fixed.

v0.31 Compile failed

Compiling libracerd v0.3.1 (file:///home/matrix/.vim/bundle/YouCompleteMe/third_party/ycmd/third_party/racerd)
error: type alias is never used: ListCompletionsResponse
--> /home/matrix/.vim/bundle/YouCompleteMe/third_party/ycmd/third_party/racerd/target/release/build/libracerd-ccd438395932b4cf/out/http/completion.rs:281:1
|
281 | type ListCompletionsResponse = Vec;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
note: lint level defined here
--> src/lib.rs:9:9
|
9 | #![deny(warnings)]
| ^^^^^^^^

Secret file contents enforced to be UTF-8

I'm porting ycmd to be Python 2 & 3 compatible so I'm auditing the way we handle strings vs. bytes. Anyway, I noticed that racerd insists that the contents of the secret file it reads must be UTF-8 because it puts those contents into a rust String (which enforces UTF-8 contents).

That strikes me as wrong. The secret should be allowed to be any sequence of bytes.

All of this works in ycmd because the racerd completer generates a random set of bytes, but encodes them with base64. That shouldn't be necessary.

If racerd merely read the file bytes as a[u8], clients would have an easier time (no need to enforce UTF-8 key).

Refactor racer argument generation

There's a block of code copied here and here. It would be nice to have a function like

fn prepare_racer_args(ctx: &Context) ->  (::racer::core::Session, usize, path)

which wraps what the linked code does. I failed at refactoring this the first time due to some lifetime errors I couldn't figure out. The calls to session.cache_file_contents somehow result in an error

Session does not live long enough

Can not compile libracerd with latest version 1.15

Compiling libracerd v0.3.1 (file:///home/aoeuaoeu/.vim/bundle/YouCompleteMe/third_party/ycmd/third_party/racerd)
error: type alias is never used: ListCompletionsResponse
--> /home/aoeuaoeu/.vim/bundle/YouCompleteMe/third_party/ycmd/third_party/racerd/target/release/build/libracerd-fc0e4009cf876877/out/http/completion.rs:281:1
|
281 | type ListCompletionsResponse = Vec;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
note: lint level defined here
--> src/lib.rs:9:9
|
9 | #![deny(warnings)]
| ^^^^^^^^

error: aborting due to previous error

error: Could not compile libracerd.

Completions are returning 204 No Content for anything but "global" scope

I've just tried with a quite fresh (yesterday) install of YouCompleteMe + racer completion, and any time I trigger a completion with . or :: I get no results back (the stdout log of racerd shows 204 No Content).

If I however trigger a completion at a "global" scope (just hitting ctrl-space on an empty line), it returns 200 OK with actual completion suggestions

Update to url 1.x

With rust 1.11.0 (stable) cargo warns about deprecated Cargo.toml syntax in the url 0.5.9 crate.

warning: TOML file found which contains invalid syntax and will soon not parse
at `/home/giles/.cargo/registry/src/github.com-1ecc6299db9ec823/url-0.5.9/Cargo.toml`.

The TOML spec requires newlines after table definitions (e.g. `[a] b = 1` is
invalid), but this file has a table header which does not have a newline after
it. A newline needs to be added and this warning will soon become a hard error
in the future.

Racerd doesn't depend on the (now stable) url crate directly but it does through hyper and iron. Both have had minor revision bumps to update to the 1.x release of the crate, but other changes mean some code changes are necessary to complete the update.

Can't complete Vec like in gif with rust nigthly

I'm trying to complete a trivial sample, just following the gif of your release blog post, but I was unable to complete Vec. Do you know what it may be?

Also, this time, compilation was not successful with nightly and I had to apply this patch because warnings are being treated as errors, and there are unused symbols imported:

diff --git a/src/http/completion.rs b/src/http/completion.rs
index 6026674..6332319 100644
--- a/src/http/completion.rs
+++ b/src/http/completion.rs
@@ -4,7 +4,7 @@ use iron::mime::Mime;

 use rustc_serialize::json;

-use engine::{SemanticEngine, Completion, Context, CursorPosition, Buffer};
+use engine::{Completion, Context, CursorPosition, Buffer};
 use super::EngineProvider;

 /// Given a location, return a list of possible completions
diff --git a/src/http/definition.rs b/src/http/definition.rs
index 5468b84..71bbf1c 100644
--- a/src/http/definition.rs
+++ b/src/http/definition.rs
@@ -5,7 +5,7 @@ use iron::mime::Mime;

 use rustc_serialize::json;

-use engine::{SemanticEngine, Definition, Context, CursorPosition, Buffer};
+use engine::{Definition, Context, CursorPosition, Buffer};
 use super::EngineProvider;

 /// Given a location, return where the identifier is defined

test of http::find_defination failed

After getting an HTTP Error 500 when using YouCompleteMe, I tested this.

~/.../racerd $ rustc -V
rustc 1.9.0
~/.../racerd $ git rev-parse HEAD
0e18f334d81a180c29d96a98bc613c943cda3d8c (latest commit, Fri Jun  3 07:57:31 UTC 2016)
~/.../racerd $ RUST_BACKTRACE=1 RUST_SRC_PATH=~/src/rust/rust/src cargo test --release
     Running target/release/lib-e43803c4aca3fc6b

running 9 tests
POST http://127.0.0.1:0/find_definition -> 200 OK (0.437442 ms)
POST http://127.0.0.1:0/find_definition -> 200 OK (0.322529 ms)
test http::find_definition ... FAILED
test http::find_definition_multiple_dirty_buffers ... FAILED
GET http://127.0.0.1:0/ping -> 200 OK (0.022621 ms)
test http::ping_pong ... ok
GET http://127.0.0.1:0/ping -> 200 OK (0.085234 ms)
GET http://127.0.0.1:0/ping -> 403 Forbidden (0.029197 ms)
ERROR:iron::iron: Error handling:
Request {
    url: Url { scheme: "http", host: Ipv4(127.0.0.1), port: 0, path: ["ping"], username: None, password: None, query: None, fragment: None }
    method: Get
    remote_addr: V4(127.0.0.1:63120)
    local_addr: V4(127.0.0.1:0)
}
Error was: InvalidHmac
test http::ping_pong_hmac_with_correct_secret ... ok
POST http://127.0.0.1:0/find_definition -> 200 OK (9.832198 ms)
test http::ping_pong_hmac_wrong_secret ... ok
test http::find_definition_in_std_library ... ok
test panics_when_invalid_secret_given ... ok
test util::http::server_url_builder ... ok
POST http://127.0.0.1:0/list_completions -> 200 OK (12.538177 ms)
test http::list_path_completions_std_library ... ok

failures:

---- http::find_definition stdout ----
    url: http://127.0.0.1:63107/find_definition
thread 'http::find_definition' panicked at 'assertion failed: `(left == right)` (left: `Object({"column": U64(3), "context": String("fn foo()"), "file_path": String("src.rs"), "kind": String("Function"), "line": U64(1), "text": String("foo")})`, right: `Object({"column": U64(3), "context": String("fn foo() {}"), "file_path": String("src.rs"), "kind": String("Function"), "line": U64(1), "text": String("foo")})`)', tests/lib.rs:92
stack backtrace:
   1:        0x10ea1bd78 - std::sys::backtrace::tracing::imp::write::h4c73fcd3363076f5
   2:        0x10ea1e2f5 - std::panicking::default_hook::_$u7b$$u7b$closure$u7d$$u7d$::h0422dbb3077e6747
   3:        0x10ea1de7f - std::panicking::default_hook::haac48fa641db8fa2
   4:        0x10ea0bb36 - std::sys_common::unwind::begin_unwind_inner::h39d40f52add53ef7
   5:        0x10ea0c95e - std::sys_common::unwind::begin_unwind_fmt::h64c0ff793199cc1b
   6:        0x10e6e1e1e - lib::http::find_definition::h6d0d53e538022449
   7:        0x10e70669b - _<F as std..boxed..FnBox<A>>::call_box::h9ce7b2b9370a0c2b
   8:        0x10e708b6d - std::sys_common::unwind::try::try_fn::h5bcc2568709c345a
   9:        0x10ea1afdb - __rust_try
  10:        0x10ea1af63 - std::sys_common::unwind::inner_try::h9eebd8dc83f388a6
  11:        0x10e708f54 - _<F as std..boxed..FnBox<A>>::call_box::h40ea07beba9f5ecc
  12:        0x10ea1d548 - std::sys::thread::Thread::new::thread_start::h471ad90789353b5b
  13:     0x7fff87e0899c - _pthread_body
  14:     0x7fff87e08919 - _pthread_start

---- http::find_definition_multiple_dirty_buffers stdout ----
    url: http://127.0.0.1:63111/find_definition
thread 'http::find_definition_multiple_dirty_buffers' panicked at 'assertion failed: `(left == right)` (left: `Object({"column": U64(7), "context": String("pub fn myfn() pub fn foo()"), "file_path": String("src2.rs"), "kind": String("Function"), "line": U64(2), "text": String("myfn")})`, right: `Object({"column": U64(7), "context": String("pub fn myfn()"), "file_path": String("src2.rs"), "kind": String("Function"), "line": U64(2), "text": String("myfn")})`)', tests/lib.rs:137
stack backtrace:
   1:        0x10ea1bd78 - std::sys::backtrace::tracing::imp::write::h4c73fcd3363076f5
   2:        0x10ea1e2f5 - std::panicking::default_hook::_$u7b$$u7b$closure$u7d$$u7d$::h0422dbb3077e6747
   3:        0x10ea1de7f - std::panicking::default_hook::haac48fa641db8fa2
   4:        0x10ea0bb36 - std::sys_common::unwind::begin_unwind_inner::h39d40f52add53ef7
   5:        0x10ea0c95e - std::sys_common::unwind::begin_unwind_fmt::h64c0ff793199cc1b
   6:        0x10e6e3a51 - lib::http::find_definition_multiple_dirty_buffers::h75d9deeedbe994d3
   7:        0x10e70669b - _<F as std..boxed..FnBox<A>>::call_box::h9ce7b2b9370a0c2b
   8:        0x10e708b6d - std::sys_common::unwind::try::try_fn::h5bcc2568709c345a
   9:        0x10ea1afdb - __rust_try
  10:        0x10ea1af63 - std::sys_common::unwind::inner_try::h9eebd8dc83f388a6
  11:        0x10e708f54 - _<F as std..boxed..FnBox<A>>::call_box::h40ea07beba9f5ecc
  12:        0x10ea1d548 - std::sys::thread::Thread::new::thread_start::h471ad90789353b5b
  13:     0x7fff87e0899c - _pthread_body
  14:     0x7fff87e08919 - _pthread_start


failures:
    http::find_definition
    http::find_definition_multiple_dirty_buffers

test result: FAILED. 7 passed; 2 failed; 0 ignored; 0 measured

error: test failed

Any suggestion?

Requests fail with NotSupported, depending on $TERM

I can reproduce iron/logger#79, even with 007aa62:

$ TERM=dumb cargo test
     Running target/debug/lib-9e020053bfe738e2

running 9 tests
ERROR:iron::iron: Error handling:
Request {
    url: Url { scheme: "http", host: Ipv4(127.0.0.1), port: 0, path: ["find_definition"], username: None, password: None, query: None, fragment: None }
    method: Post
    remote_addr: V4(127.0.0.1:37440)
    local_addr: V4(127.0.0.1:0)
}
Error was: Error { repr: Custom(Custom { kind: Other, error: NotSupported }) }
ERROR:iron::iron: Error handling:
Request {
    url: Url { scheme: "http", host: Ipv4(127.0.0.1), port: 0, path: ["find_definition"], username: None, password: None, query: None, fragment: None }
    method: Post
    remote_addr: V4(127.0.0.1:49330)
    local_addr: V4(127.0.0.1:0)
}
Error was: Error { repr: Custom(Custom { kind: Other, error: NotSupported }) }
POSTPOSTtest http::find_definition ... FAILED
test http::find_definition_multiple_dirty_buffers ... FAILED
ERROR:iron::iron: Error handling:
Request {
    url: Url { scheme: "http", host: Ipv4(127.0.0.1), port: 0, path: ["ping"], username: None, password: None, query: None, fragment: None }
    method: Get
    remote_addr: V4(127.0.0.1:36404)
    local_addr: V4(127.0.0.1:0)
}
Error was: Error { repr: Custom(Custom { kind: Other, error: NotSupported }) }
GETtest http::ping_pong ... FAILED
ERROR:iron::iron: Error handling:
Request {
    url: Url { scheme: "http", host: Ipv4(127.0.0.1), port: 0, path: ["ping"], username: None, password: None, query: None, fragment: None }
    method: Get
    remote_addr: V4(127.0.0.1:33728)
    local_addr: V4(127.0.0.1:0)
}
Error was: Error { repr: Custom(Custom { kind: Other, error: NotSupported }) }
GETtest http::ping_pong_hmac_with_correct_secret ... FAILED
test panics_when_invalid_secret_given ... ok
test util::http::server_url_builder ... ok
ERROR:iron::iron: Error handling:
Request {
    url: Url { scheme: "http", host: Ipv4(127.0.0.1), port: 0, path: ["ping"], username: None, password: None, query: None, fragment: None }
    method: Get
    remote_addr: V4(127.0.0.1:45214)
    local_addr: V4(127.0.0.1:0)
}
Error was: Error { repr: Custom(Custom { kind: Other, error: NotSupported }) }
GETtest http::ping_pong_hmac_wrong_secret ... FAILED
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: NotPresent', ../src/libcore/result.rs:688
test http::list_path_completions_std_library ... FAILED
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: NotPresent', ../src/libcore/result.rs:688
test http::find_definition_in_std_library ... FAILED

failures:

---- http::find_definition stdout ----
    url: http://127.0.0.1:40652/find_definition
thread 'http::find_definition' panicked at 'called `Option::unwrap()` on a `None` value', ../src/libcore/option.rs:330

---- http::find_definition_multiple_dirty_buffers stdout ----
    url: http://127.0.0.1:38420/find_definition
thread 'http::find_definition_multiple_dirty_buffers' panicked at 'called `Option::unwrap()` on a `None` value', ../src/libcore/option.rs:330

---- http::ping_pong stdout ----
    url: http://127.0.0.1:33567/ping
thread 'http::ping_pong' panicked at 'called `Option::unwrap()` on a `None` value', ../src/libcore/option.rs:330

---- http::ping_pong_hmac_with_correct_secret stdout ----
    thread 'http::ping_pong_hmac_with_correct_secret' panicked at 'assertion failed: `(left == right)` (left: `InternalServerError`, right: `Ok`)', tests/lib.rs:248

---- http::ping_pong_hmac_wrong_secret stdout ----
    thread 'http::ping_pong_hmac_wrong_secret' panicked at 'assertion failed: `(left == right)` (left: `InternalServerError`, right: `Forbidden`)', tests/lib.rs:279

---- http::list_path_completions_std_library stdout ----
    url: http://127.0.0.1:36302/list_completions
thread 'http::list_path_completions_std_library' panicked at 'called `Option::unwrap()` on a `None` value', ../src/libcore/option.rs:330

---- http::find_definition_in_std_library stdout ----
    url: http://127.0.0.1:39332/find_definition
thread 'http::find_definition_in_std_library' panicked at 'called `Option::unwrap()` on a `None` value', ../src/libcore/option.rs:330


failures:
    http::find_definition
    http::find_definition_in_std_library
    http::find_definition_multiple_dirty_buffers
    http::list_path_completions_std_library
    http::ping_pong
    http::ping_pong_hmac_with_correct_secret
    http::ping_pong_hmac_wrong_secret

test result: FAILED. 2 passed; 7 failed; 0 ignored; 0 measured

Create tag for version 0.3.1

@jwilm Would it be possible to create a tag pointing to the master (4b8d3c7) for version 0.3.1. I am looking to submit a PR to update Valloric's ycmd, which includes this project as a submodule. Currently he is using a commit of racerd from 3 months ago. Having a tag would be cleaner way to suggest a change to Valloric than just suggesting updating to a random commit.

Please let me know if there is any further testing that needs to be done before creating a tag. I am happy to volunteer my time to get this code into a state for release.

I will build ycmd with this current master and use it with YCM as an integration test.

Completions stop working

Haven't looked into this at all, usually just restart YCM so I can keep working on the task at hand. Will post logs next time this comes up.

fails to compile

 Compiling libracerd v0.1.0 (file:///home/yannik/pkgbuilds/youcompleteme/src/YouCompleteMe/third_party/ycmd/third_party/racerd)
error: unused import
 --> src/http/definition.rs:8:14
8 |> use engine::{SemanticEngine, Definition, Context, CursorPosition, Buffer};
  |>              ^^^^^^^^^^^^^^
note: lint level defined here
 --> src/lib.rs:9:9
9 |> #![deny(warnings)]
  |>         ^^^^^^^^

error: unused import
 --> src/http/completion.rs:7:14
7 |> use engine::{SemanticEngine, Completion, Context, CursorPosition, Buffer};
  |>              ^^^^^^^^^^^^^^
note: lint level defined here
 --> src/lib.rs:9:9
9 |> #![deny(warnings)]
  |>         ^^^^^^^^

error: aborting due to 2 previous errors
error: Could not compile `libracerd`.

racerd fails to cargo build --release

According to the documentation for YouCompleteMe it says to navigate to the third_party/ycmd/third_party/racerd directory and run cargo build --release to get Rust support. I am also seeing the same error when I run ./install.py --racer-completer where the output is:

error: An unknown error occurred

To learn more, run the command again with --verbose.

Looks like the cargo build command is not finding the third_party/racerd directory for some reason.

See the attached screenshot.
screenshot 2017-06-12 01 02 36

Let me know if there's anything else I can provide.

Where is std::fmt?

I am currently doing my first steps in the rust.

I am using source from rust18 nightly and vim+ycm
with let g:ycm_rust_src_path = $HOME."/src/1st_level/rust_src18/rustc-nightly/src"

It works almost ok as far as I know, but with a strange issue:

When I try something like this:

[~] >> export RUST_SRC_PATH="/home/neg/src/1st_level/rust_src18/rustc-nightly/src"
[~] >> racer complete std::f
MATCH fmt,1,0,/home/neg/src/1st_level/rust_src18/rustc-nightly/src/libstd/../libcollections/fmt.rs,Module,/home/neg/src/1st_level/rust_src18/rustc-nightly/src/libstd/../libcollections/fmt.rs
MATCH ffi,1,0,/home/neg/src/1st_level/rust_src18/rustc-nightly/src/libstd/ffi/mod.rs,Module,/home/neg/src/1st_level/rust_src18/rustc-nightly/src/libstd/ffi/mod.rs
MATCH fs,1,0,/home/neg/src/1st_level/rust_src18/rustc-nightly/src/libstd/fs.rs,Module,/home/neg/src/1st_level/rust_src18/rustc-nightly/src/libstd/fs.rs

everyhing looks OK, std::fmt is here.

But when I am using vim+ycm there are only fs and ffi after "std::f<...>". Maybe you can explain why I've get this behaviour as far as you are racerd completer developer?

Not sure that it is a racerd bug, anyway.

Be gentle with OSX

About the OSX Issues in your README. Instead of overriding Openssl's version for the whole system you could do it for this project only. I personally use this with rustc:

export OPENSSL_LIB_DIR=/usr/local/opt/openssl/lib
export OPENSSL_INCLUDE_DIR=/usr/local/opt/openssl/include

It works well without forcing anything.

Fresh clone doesn't build from #![deny(warnings)] on nightly

racerd builds find for me on stable, but I accidentally had multirust's default set to nightly and got a nice little lint build error:

$ rustc --version
rustc 1.10.0-nightly (e0fd34bba 2016-05-09)
$ cargo build --release
   Compiling libracerd v0.2.0 (file:///home/adam/rust-projects/racerd)
/home/adam/rust-projects/racerd/target/release/build/libracerd-426767cf8a838e70/out/http/definition.rs:7:14: 7:28 error: unused import
/home/adam/rust-projects/racerd/target/release/build/libracerd-426767cf8a838e70/out/http/definition.rs:7 use engine::{SemanticEngine, Definition, Context, CursorPosition, Buffer};
                                                                                                                      ^~~~~~~~~~~~~~
/home/adam/rust-projects/racerd/target/release/build/libracerd-426767cf8a838e70/out/http/definition.rs:7:14: 7:28 note: in this expansion of include!
src/lib.rs:9:9: 9:17 note: lint level defined here
src/lib.rs:9 #![deny(warnings)]
                     ^~~~~~~~
/home/adam/rust-projects/racerd/target/release/build/libracerd-426767cf8a838e70/out/http/completion.rs:7:14: 7:28 error: unused import
/home/adam/rust-projects/racerd/target/release/build/libracerd-426767cf8a838e70/out/http/completion.rs:7 use engine::{SemanticEngine, Completion, Context, CursorPosition, Buffer};
                                                                                                                      ^~~~~~~~~~~~~~
/home/adam/rust-projects/racerd/target/release/build/libracerd-426767cf8a838e70/out/http/completion.rs:7:14: 7:28 note: in this expansion of include!
src/lib.rs:9:9: 9:17 note: lint level defined here
src/lib.rs:9 #![deny(warnings)]
                     ^~~~~~~~
error: aborting due to 2 previous errors
error: Could not compile `libracerd`.

I haven't investigated in depth, but I'm assuming that since the error is inside an include! it's due to differing behavior of syntex on nightly vs. stable. Might be good to add something to the README noting which compiler versions are supported?

Racerd does not compile

Tried to compile ycm with rust support and came across with this issue.

I think the problem is cause by the change in racer. They change struct Coordinate
from

racer::Coordinate{
line: rls
column: rls
}

to
racer::Coordinate{
row: rls
col: rls
}

guess this change will fix the problem, I didn't test it though.

[100%] Built target _regex
Compiling libracerd v0.3.3 (/home/stokhos/.local/share/dein/repos/github.com/Valloric/YouCompleteMe/third_party/ycmd/third_party/racerd)
error[E0560]: struct racer::Coordinate has no field named line
--> /home/stokhos/.local/share/dein/repos/github.com/Valloric/YouCompleteMe/third_party/ycmd/third_party/racerd/target/release/build/libracerd-bc44828170aeeab3/out/engine/mod.rs:119:55
|
119 | ::racer::Location::Coords(::racer::Coordinate{line: self.line,
| ^^^^ racer::Coordinate does not have this field
|
= note: available fields are: row, col

error[E0560]: struct racer::Coordinate has no field named column
--> /home/stokhos/.local/share/dein/repos/github.com/Valloric/YouCompleteMe/third_party/ycmd/third_party/racerd/target/release/build/libracerd-bc44828170aeeab3/out/engine/mod.rs:120:55
|
120 | column: self.col,})
| ^^^^^^ racer::Coordinate does not have this field
|
= note: available fields are: row, col

error[E0026]: struct racer::Coordinate does not have fields named line, column
--> /home/stokhos/.local/share/dein/repos/github.com/Valloric/YouCompleteMe/third_party/ycmd/third_party/racerd/target/release/build/libracerd-bc44828170aeeab3/out/engine/mod.rs:165:84
|
165 | line,
| ^^^^
166 | column: col
| ^^^^^^^^^^^ struct racer::Coordinate does not have these fields

error[E0027]: pattern does not mention fields row, col
--> /home/stokhos/.local/share/dein/repos/github.com/Valloric/YouCompleteMe/third_party/ycmd/third_party/racerd/target/release/build/libracerd-bc44828170aeeab3/out/engine/mod.rs:164:80
|
164 | m.coords.map(|Coordinate {
| ^
165 | | line,
166 | | column: col
167 | | }|
| |____^ missing fields row, col

error[E0026]: struct racer::Coordinate does not have fields named line, column
--> /home/stokhos/.local/share/dein/repos/github.com/Valloric/YouCompleteMe/third_party/ycmd/third_party/racerd/target/release/build/libracerd-bc44828170aeeab3/out/engine/mod.rs:213:88
|
213 | line,
| ^^^^
214 | column: col
| ^^^^^^^^^^^ struct racer::Coordinate does not have these fields

error[E0027]: pattern does not mention fields row, col
--> /home/stokhos/.local/share/dein/repos/github.com/Valloric/YouCompleteMe/third_party/ycmd/third_party/racerd/target/release/build/libracerd-bc44828170aeeab3/out/engine/mod.rs:212:84
|
212 | coords.map(|Coordinate {
| ^
213 | | line,
214 | | column: col
215 | | }|
| |____^ missing fields row, col

error: aborting due to 6 previous errors

Some errors occurred: E0026, E0027, E0560.
For more information about an error, try rustc --explain E0026.
error: Could not compile libracerd.

Newline chars in function signatures

Testcase code

struct foo {}

impl foo {
  fn format( &self )
    -> u32 {
  }
}

fn main() {
  let x = foo{};
  x.
}

Completion shown in Vim through YCM:

bug

One could consider this a bug in ycmd since it might make sense to remove the newline there, or possibly in YCM itself because the newline doesn't render sensibly in Vim so the Vim workaround should be there, but racerd (or racer itself) should probably not be returning a newline here either. I can't imagine an editor for which a newline should be displayed here.

I'd suggest replacing all whitespace char runs with a single space... somewhere.

(We're "turtles all the way down" on this bug...)

Return `401 Unauthorized` instead of `403 Forbidden` on HMAC auth failure

Racerd currently returns a 403 on HMAC failure instead of a 401. The 401 makes more sense; the request was unauthorized. 403 means the user has been authenticated but his level of access is not sufficient to access this resource.

Both ycmd and JediHTTP work use a 401.

Relevant SO answer which goes into more detail.

Put more simply, 401 is authentication failure whereas 403 is authorization failure.

Build fails on latest unstable Rust in Darwin (macOS)

Trying to build the racerd package in nix-pkgs, which depends on the latest unstable rust:

   Compiling iron v0.6.1
error[E0061]: this function takes 1 argument but 0 arguments were supplied
  --> /private/var/folders/kj/tzv099zx2yzgnkjtdhqbxbjh0000gn/T/nix-build-racerd-unstable-2019-09-02.drv-0/racerd-unstable-2019-09-02-vendor.tar.gz/rustc-ap-rustc_data_structures/box_region.rs:36:58
   |
36 |         let init = match Pin::new(&mut result.generator).resume() {
   |                                                          ^^^^^^- supplied 0 arguments
   |
help: expected the unit value `()`; create it with empty parentheses
   |
36 |         let init = match Pin::new(&mut result.generator).resume(()) {
   |                                                                 ^^

error[E0061]: this function takes 1 argument but 0 arguments were supplied
  --> /private/var/folders/kj/tzv099zx2yzgnkjtdhqbxbjh0000gn/T/nix-build-racerd-unstable-2019-09-02.drv-0/racerd-unstable-2019-09-02-vendor.tar.gz/rustc-ap-rustc_data_structures/box_region.rs:52:76
   |
52 |         if let GeneratorState::Complete(_) = Pin::new(&mut self.generator).resume() {
   |                                                                            ^^^^^^- supplied 0 arguments
   |
help: expected the unit value `()`; create it with empty parentheses
   |
52 |         if let GeneratorState::Complete(_) = Pin::new(&mut self.generator).resume(()) {
   |                                                                                   ^^

error[E0061]: this function takes 1 argument but 0 arguments were supplied
  --> /private/var/folders/kj/tzv099zx2yzgnkjtdhqbxbjh0000gn/T/nix-build-racerd-unstable-2019-09-02.drv-0/racerd-unstable-2019-09-02-vendor.tar.gz/rustc-ap-rustc_data_structures/box_region.rs:63:52
   |
63 |         let result = Pin::new(&mut self.generator).resume();
   |                                                    ^^^^^^- supplied 0 arguments
   |
help: expected the unit value `()`; create it with empty parentheses
   |
63 |         let result = Pin::new(&mut self.generator).resume(());
   |                                                           ^^

Unfortunately, this repo depends on features not in stable, attempts to build with stable fail.

Any help would be greatly appreciated.

Crashes for Servo with an updated racer

Opening document.rs in Servo after cargo update -p racer in the racerd directory gives the following error:

$ tail -f /tmp/ycm_temp/racerd_43924_stderr.log
bogofile:2:1: 2:4 error: expected identifier, found keyword `use`
bogofile:2 use devtools_traits::CSSError;
           ^~~
bogofile:2:5: 2:20 error: expected one of `::`, `;`, or `as`, found `devtools_traits`
bogofile:2 use devtools_traits::CSSError;
               ^~~~~~~~~~~~~~~
thread '<unnamed>' panicked at 'called `Option::unwrap()` on a `None` value', ../src/libcore/option.rs:330
stack backtrace:
   1:     0x7fa1dc4a06b0 - sys::backtrace::tracing::imp::write::h3be75c22d68e439dkju
   2:     0x7fa1dc4a2bd5 - panicking::default_handler::_<closure>::closure.42499
   3:     0x7fa1dc4a267f - panicking::default_handler::h778d598585cd05bamwy
   4:     0x7fa1dc48eba6 - sys_common::unwind::begin_unwind_inner::h28dde7e4a93f998fRbt
   5:     0x7fa1dc48f2c8 - sys_common::unwind::begin_unwind_fmt::h8325303cc05dc240Xat
   6:     0x7fa1dc49fcf1 - rust_begin_unwind
   7:     0x7fa1dc4d4c6f - panicking::panic_fmt::h141ead198f715924RZL
   8:     0x7fa1dc4d4f48 - panicking::panic::h941dcac71cd8feafoYL
   9:     0x7fa1dc2a232b - cargo::get_crate_file::hbe7a9e5d19d77337wii
  10:     0x7fa1dc2a023d - nameres::get_crate_file::h870708696b97ac12yte
  11:     0x7fa1dc2af1b7 - matchers::match_extern_crate::h40b5d9f32938d273fzg
  12:     0x7fa1dc2a4025 - matchers::match_types::hffaa35b0498a2c653gg
  13:     0x7fa1dc2a2c0b - nameres::run_matchers_on_blob::hf1fa50871a312f0bPIe
  14:     0x7fa1dc29f45e - nameres::search_scope::h270165dad7c45ebd2ye
  15:     0x7fa1dc2a9f98 - nameres::search_local_scopes::hbd10ef5dd517740e9Ke
  16:     0x7fa1dc29c717 - nameres::resolve_name::h2dcd4d1cd2449db0P2e
  17:     0x7fa1dc29b01b - nameres::search_crate_root::hf50fc79f54fa6003sne
  18:     0x7fa1dc29ca2d - nameres::resolve_name::h2dcd4d1cd2449db0P2e
  19:     0x7fa1dc2586c5 - nameres::resolve_path::h08a17d152c0b0b63Gcf
  20:     0x7fa1dc258b37 - nameres::resolve_path::h08a17d152c0b0b63Gcf
  21:     0x7fa1dc256820 - core::complete_from_file::h181406f80979f7c7H2a
  22:     0x7fa1dc24e051 - engine::racer::Racer<'a>.SemanticEngine::list_completions::h43462f672eb7040am7a
  23:     0x7fa1dc2485b7 - http::completion::list::hcda39ad919557730qua
  24:     0x7fa1dc21a67b - middleware::F.Handler::handle::h4402679360748095063
  25:     0x7fa1dc43a060 - middleware::Box<Handler>.Handler::handle::h5197bd449689d5d8Qoa
  26:     0x7fa1dc3ec382 - router::Router::handle_method::hbc7eba1de605229diia
  27:     0x7fa1dc3ed91e - router::Router.Handler::handle::h76c19d88b1859211lja
  28:     0x7fa1dc439ca8 - middleware::Chain::continue_from_handler::hc2fd1c16054ef71cFma
  29:     0x7fa1dc437d3a - middleware::Chain.Handler::handle::heda909bfd0e3c073Mia
  30:     0x7fa1dc22e569 - hyper::server::listener::spawn_with::_<closure>::closure.14347
  31:     0x7fa1dc22ced6 - sys_common::unwind::try::try_fn::h14170584884215212308
  32:     0x7fa1dc49fc88 - __rust_try
  33:     0x7fa1dc49c63b - sys_common::unwind::try::inner_try::h2d9318abe36c76cap8s
  34:     0x7fa1dc230e6b - boxed::F.FnBox<A>::call_box::h586351103777805204
  35:     0x7fa1dc4a15f3 - sys::thread::Thread::new::thread_start::haf863f2ba39455ffitx
  36:     0x7fa1db4cd6a9 - start_thread
  37:     0x7fa1dbcf6eec - clone
  38:                0x0 - <unknown>

This is when I type use url:: on line 4
This is in both vim and sublime.

racerd won't compile due to old iron/body-parser

iron/body-parser
bodyparser 0.0.5 (git+https://github.com/iron/body-parser?rev=f9929111bd2efe7c29b519a5aa2d7bc32fddfac0) won't compile

/Users/CC/.cargo/git/checkouts/body-parser-5959338430ff088f/f9929111bd2efe7c29b519a5aa2d7bc32fddfac0/src/lib.rs:76:18: 76:58 error: the trait `plugin::Plugin<iron::request::Request<'_, '_>>` is not implemented for the type `persistent::Read<MaxBodyLength>` [E0277]
/Users/CC/.cargo/git/checkouts/body-parser-5959338430ff088f/f9929111bd2efe7c29b519a5aa2d7bc32fddfac0/src/lib.rs:76                 .get::<persistent::Read<MaxBodyLength>>()
                                                                                                                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

There are some other components depending on an old bodyparser.

~/.../racerd $ ag body Cargo.lock
5: "bodyparser 0.3.0 (git+https://github.com/iron/body-parser)",
40:name = "bodyparser"
42:source = "git+https://github.com/iron/body-parser?rev=f9929111bd2efe7c29b519a5aa2d7bc32fddfac0#f9929111bd2efe7c29b519a5aa2d7bc32fddfac0"
51:name = "bodyparser"
53:source = "git+https://github.com/iron/body-parser#46ae6c68adb2459cdf96e8f7f05b957938b1fb37"
220: "bodyparser 0.0.5 (git+https://github.com/iron/body-parser?rev=f9929111bd2efe7c29b519a5aa2d7bc32fddfac0)",

Platform information:

OS: Mac OS X 10.11
Rust 1.7.0 stable

In additiona, body-parser 0.3.0 compiles.
I also find that you are the author of iron/iron-hmac; Could you please update to and test the new bodyparser?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.