libp2p / libp2p/rust-libp2p

Reduce dependency tree

Open
#3,515 13 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

tracking-issue
Dominant language
Rust
Stars
5.6k
Forks
1.3k
Avg merge
8h 47m
Merged PRs (30d)
19

Description

I'll record various efforts in here to reduce the size of our dependency tree where possible.

- [ ] https://github.com/libp2p/rust-libp2p/pull/3514
- [ ] https://github.com/libp2p/rust-libp2p/pull/3513
- [ ] https://github.com/libp2p/rust-libp2p/pull/3512
- [ ] https://github.com/libp2p/rust-libp2p/pull/3510
- [ ] https://github.com/webrtc-rs/webrtc/pull/411
- [ ] https://github.com/libp2p/rust-libp2p/pull/3312
- [ ] `combine` is only brought in by `redis` through `interop-test`
- [ ] https://github.com/libp2p/rust-libp2p/issues/3659
- [ ] https://github.com/libp2p/rust-libp2p/issues/4449

More suggestions welcome, a good place to start is a timings report by cargo of the entire workspace (minus dev-dependencies): cargo build --workspace --all-features --timings. Once you have identified a (ideally heavy) dependency that we might not need, investigate with cargo tree -i -p <dependency> where it comes from.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the workspace timings report using cargo build --workspace --all-features --timings, then trace a potentially heavy dependency with cargo tree -i -p <dependency>. Review the listed pull requests and issues before selecting a dependency; done means reducing the dependency tree without breaking the workspace.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
build-system
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.