The best rust crates, according to hackers
8 rust crates recommended in Hacker News comments over the past year, ranked by how many separate people recommend each one.
All rust crates
- anyhow (Rust crate)Recommended for easy error propagation and added context in Rust application code. Critics note it should not appear in library public APIs.34recommend
- RayonPeople recommend it for adding multicore parallelism to Rust code with very little effort, and for its safe, simple parallel iterators. Critics say its abstractions are sometimes not flexible enough.18recommend
- thiserrorRust crate that removes the boilerplate of defining strongly-typed error types for libraries, and stays transparent to downstream users. Common caveat: it makes forwarding errors too easy and macro expansions hard to debug.16recommend
- rand crateTrusted standard random number library for Rust that people treat as a core dependency. Critics say it sets habits and that its non-secure RNGs get misused.9recommend
- Facet (Rust reflection library)A Rust derive macro library that adds runtime type information and reflection to code. Critics say it has not delivered on its promise of faster compile times.6recommend
- SurelockA Rust mutex library that enforces a total lock ordering to prevent deadlocks, praised for clear, explicit design without macros. Critics note it doesn't detect locking the same mutex twice.6recommend
- windows-rsMicrosoft's Rust crates for calling Windows APIs; people find them pleasant to use, though critics call the API design confusing and worry about the crate's future.5recommend
- parking_lotRecommended as a small, fast mutex with no lock poisoning, making fine-grained locking practical. Critics say its performance gains are small and it lacks priority-inversion support.5recommend