Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: no more futures crate #73

Merged
merged 3 commits into from
Apr 24, 2024
Merged

refactor: no more futures crate #73

merged 3 commits into from
Apr 24, 2024

Conversation

dignifiedquire
Copy link
Contributor

No description provided.

@rklaehn rklaehn merged commit 403fab0 into main Apr 24, 2024
15 checks passed
@rklaehn rklaehn deleted the no-future branch April 24, 2024 14:45
github-merge-queue bot pushed a commit to n0-computer/iroh that referenced this pull request Apr 29, 2024
Due to the low maintenance and absurd high amount of `unsafe` code in
parts of the `futures` crate, we are trying to avoid usage of it.

Usages are replaced with

- `futures-lite` : general `Future` and `Stream` tooling
- `futures-sink`: `Sink` trait
- `futures-buffered`: faster and safer version of `Futures{Un}Ordered`
- If must be `futures-util` for sink specific things that are missing

## Breaking Changes

- `iroh::node::Node` does not implement `Future` anymore
- `iroh::node::Node::shutdown()` is now `async` and can be awaited upon
to wait for the node to exit
- `iroh_net::util::AbortingJoinHandle`s inner field is not public
anymore, use the `From<JoinHandle>` implementation to contruct it


## Followups

- [x] Apply this to `bao-tree`:
n0-computer/bao-tree#49
- [x] Apply this to `iroh-io`:
n0-computer/iroh-io#6
- [x] Apply this to `quic-rpc`:
n0-computer/quic-rpc#73

---------

Co-authored-by: Ruediger Klaehn <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants