meilisearch / milli

Search engine library for Meilisearch ⚡️
MIT License
464 stars 81 forks source link

Test database for bench isn't in the repo #130

Closed shekhirin closed 3 years ago

shekhirin commented 3 years ago

Problem

Let's run cargo bench locally

➜ milli (main) ✗ cargo bench 
    Blocking waiting for file lock on package cache
    Blocking waiting for file lock on package cache
   Compiling milli v0.1.0 (/Users/shekhirin/Projects/milli/milli)
    Finished bench [optimized + debuginfo] target(s) in 3m 14s
     Running target/release/deps/milli-ea87a0ce432f49ba

running 57 tests

...

test result: ok. 0 passed; 0 failed; 57 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running target/release/deps/search-cff73d24bb30ba0a
WARNING: HTML report generation will become a non-default optional feature in Criterion.rs 0.4.0.
This feature is being moved to cargo-criterion (https://github.com/bheisler/cargo-criterion) and will be optional in a future version of Criterion.rs. To silence this warning, either switch to cargo-criterion or enable the 'html_reports' feature in your Cargo.toml.

Gnuplot not found, using plotters backend
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: No such file or directory (os error 2)', milli/benches/search.rs:17:47
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
error: bench failed

It crashes :(

thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: No such file or directory (os error 2)', milli/benches/search.rs:17:47

Solution

Include books-4cpu.mmdb file in the repo https://github.com/meilisearch/milli/blob/9ad8b74111be114fed1ff3c9638293c1d31536a8/milli/benches/search.rs#L8

Kerollmops commented 3 years ago

Hey @shekhirin,

Thank you for your issue, I just created an issue about the set of benchmarks that we plan to add to the repository. @irevoire will work on that for the next days/weeks.

Thank you very much for your help and curiosity about the project, A first version of this engine will be out in not much time 😺

irevoire commented 3 years ago

Now that #207 have been merged we can close this issue. Feel free to reopen if I missed something 😄