Skip to content

Commit

Permalink
Merge branch 'master' of github.com:libp2p/rust-libp2p into protocols…
Browse files Browse the repository at this point in the history
…/autonat
  • Loading branch information
elenaf9 committed Oct 22, 2021
2 parents 8650b97 + 9750951 commit 9f63141
Show file tree
Hide file tree
Showing 96 changed files with 2,772 additions and 2,581 deletions.
60 changes: 30 additions & 30 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,29 +10,37 @@ jobs:
test-desktop:
name: Build and test
runs-on: ubuntu-latest
strategy:
matrix:
args: [
"--no-default-features",
"--all-features",
"--benches --all-features",
]
steps:

- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.9.1
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v2.3.4
- uses: actions/checkout@v2.3.5

- uses: Swatinem/rust-cache@v1.3.0
with:
key: ${{ matrix.args }}

- name: Run tests, with no feature
run: cargo test --workspace --no-default-features

- name: Run tests, with all features
run: cargo test --workspace --all-features

- name: Run benches, with all features
run: cargo test --workspace --benches --all-features
- run: cargo test --workspace ${{ matrix.args }}

test-wasm:
name: Build on WASM
runs-on: ubuntu-latest
strategy:
matrix:
toolchain: [
wasm32-unknown-emscripten,
wasm32-wasi
]
container:
image: rust
env:
Expand All @@ -44,20 +52,13 @@ jobs:
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v2.3.4

- name: Install Rust wasm32-unknown-emscripten
uses: actions-rs/toolchain@v1.0.7
with:
toolchain: stable
target: wasm32-unknown-emscripten
override: true
- uses: actions/checkout@v2.3.5

- name: Install Rust wasm32-wasi
- name: Install Rust ${{ matrix.toolchain }}
uses: actions-rs/toolchain@v1.0.7
with:
toolchain: stable
target: wasm32-wasi
target: ${{ matrix.toolchain }}
override: true

- name: Install a recent version of clang
Expand All @@ -69,16 +70,13 @@ jobs:
run: apt-get install -y cmake

- uses: Swatinem/rust-cache@v1.3.0
with:
key: ${{ matrix.toolchain }}

- name: Build on wasm32-unknown-emscripten
# TODO: also run `cargo test`
# TODO: ideally we would build `--workspace`, but not all crates compile for WASM
run: cargo build --target=wasm32-unknown-emscripten

- name: Build on wasm32-wasi
- name: Build on ${{ matrix.toolchain }}
# TODO: also run `cargo test`
# TODO: ideally we would build `--workspace`, but not all crates compile for WASM
run: cargo build --target=wasm32-wasi
run: cargo build --target=${{ matrix.toolchain }}

check-rustdoc-links:
name: Check rustdoc intra-doc links
Expand All @@ -92,7 +90,9 @@ jobs:
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v2.3.4
- uses: actions/checkout@v2.3.5

- uses: Swatinem/rust-cache@v1.3.0

- name: Check rustdoc links
run: RUSTDOCFLAGS="--deny broken_intra_doc_links" cargo doc --verbose --workspace --no-deps --document-private-items
Expand All @@ -106,7 +106,7 @@ jobs:
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v2.3.4
- uses: actions/checkout@v2.3.5

- uses: actions-rs/toolchain@v1.0.7
with:
Expand Down Expand Up @@ -134,7 +134,7 @@ jobs:
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v2.3.4
- uses: actions/checkout@v2.3.5

- uses: Swatinem/rust-cache@v1.3.0

Expand All @@ -150,7 +150,7 @@ jobs:
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v2.3.4
- uses: actions/checkout@v2.3.5

- uses: actions-rs/toolchain@v1.0.7
with:
Expand Down
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,13 @@

# `libp2p` facade crate

## Version 0.40.0 [unreleased]

## Version 0.40.0-rc.2 [2021-10-15]

- Update individual crates.
- `libp2p-kad`

## Version 0.40.0-rc.1 [2021-10-15]

- Update individual crates.
- `libp2p-core`
Expand Down
52 changes: 26 additions & 26 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name = "libp2p"
edition = "2018"
description = "Peer-to-peer networking library"
version = "0.40.0"
version = "0.40.0-rc.2"
authors = ["Parity Technologies <admin@parity.io>"]
license = "MIT"
repository = "https://github.com/libp2p/rust-libp2p"
Expand Down Expand Up @@ -71,37 +71,37 @@ bytes = "1"
futures = "0.3.1"
lazy_static = "1.2"
libp2p-autonat = { version = "0.20.0", path = "protocols/autonat", optional = true }
libp2p-core = { version = "0.30.0", path = "core", default-features = false }
libp2p-floodsub = { version = "0.31.0", path = "protocols/floodsub", optional = true }
libp2p-gossipsub = { version = "0.33.0", path = "./protocols/gossipsub", optional = true }
libp2p-identify = { version = "0.31.0", path = "protocols/identify", optional = true }
libp2p-kad = { version = "0.32.0", path = "protocols/kad", optional = true }
libp2p-metrics = { version = "0.1.0", path = "misc/metrics", optional = true }
libp2p-mplex = { version = "0.30.0", path = "muxers/mplex", optional = true }
libp2p-noise = { version = "0.33.0", path = "transports/noise", optional = true }
libp2p-ping = { version = "0.31.0", path = "protocols/ping", optional = true }
libp2p-plaintext = { version = "0.30.0", path = "transports/plaintext", optional = true }
libp2p-pnet = { version = "0.22.0", path = "transports/pnet", optional = true }
libp2p-relay = { version = "0.4.0", path = "protocols/relay", optional = true }
libp2p-rendezvous = { version = "0.1.0", path = "protocols/rendezvous", optional = true }
libp2p-request-response = { version = "0.13.0", path = "protocols/request-response", optional = true }
libp2p-swarm = { version = "0.31.0", path = "swarm" }
libp2p-swarm-derive = { version = "0.25.0", path = "swarm-derive" }
libp2p-uds = { version = "0.30.0", path = "transports/uds", optional = true }
libp2p-wasm-ext = { version = "0.30.0", path = "transports/wasm-ext", default-features = false, optional = true }
libp2p-yamux = { version = "0.34.0", path = "muxers/yamux", optional = true }
multiaddr = { version = "0.13.0" }
libp2p-core = { version = "0.30.0-rc.1", path = "core", default-features = false }
libp2p-floodsub = { version = "0.31.0-rc.1", path = "protocols/floodsub", optional = true }
libp2p-gossipsub = { version = "0.33.0-rc.1", path = "./protocols/gossipsub", optional = true }
libp2p-identify = { version = "0.31.0-rc.1", path = "protocols/identify", optional = true }
libp2p-kad = { version = "0.32.0-rc.2", path = "protocols/kad", optional = true }
libp2p-metrics = { version = "0.1.0-rc.1", path = "misc/metrics", optional = true }
libp2p-mplex = { version = "0.30.0-rc.1", path = "muxers/mplex", optional = true }
libp2p-noise = { version = "0.33.0-rc.1", path = "transports/noise", optional = true }
libp2p-ping = { version = "0.31.0-rc.1", path = "protocols/ping", optional = true }
libp2p-plaintext = { version = "0.30.0-rc.1", path = "transports/plaintext", optional = true }
libp2p-pnet = { version = "0.22.0-rc.1", path = "transports/pnet", optional = true }
libp2p-relay = { version = "0.4.0-rc.1", path = "protocols/relay", optional = true }
libp2p-rendezvous = { version = "0.1.0-rc.1", path = "protocols/rendezvous", optional = true }
libp2p-request-response = { version = "0.13.0-rc.1", path = "protocols/request-response", optional = true }
libp2p-swarm = { version = "0.31.0-rc.1", path = "swarm" }
libp2p-swarm-derive = { version = "0.25.0-rc.1", path = "swarm-derive" }
libp2p-uds = { version = "0.30.0-rc.1", path = "transports/uds", optional = true }
libp2p-wasm-ext = { version = "0.30.0-rc.1", path = "transports/wasm-ext", default-features = false, optional = true }
libp2p-yamux = { version = "0.34.0-rc.1", path = "muxers/yamux", optional = true }
multiaddr = { version = "0.13.0-rc.1" }
parking_lot = "0.11.0"
pin-project = "1.0.0"
smallvec = "1.6.1"
wasm-timer = "0.2.4"

[target.'cfg(not(any(target_os = "emscripten", target_os = "wasi", target_os = "unknown")))'.dependencies]
libp2p-deflate = { version = "0.30.0", path = "transports/deflate", optional = true }
libp2p-dns = { version = "0.30.0", path = "transports/dns", optional = true, default-features = false }
libp2p-mdns = { version = "0.32.0", path = "protocols/mdns", optional = true }
libp2p-tcp = { version = "0.30.0", path = "transports/tcp", default-features = false, optional = true }
libp2p-websocket = { version = "0.31.0", path = "transports/websocket", optional = true }
libp2p-deflate = { version = "0.30.0-rc.1", path = "transports/deflate", optional = true }
libp2p-dns = { version = "0.30.0-rc.1", path = "transports/dns", optional = true, default-features = false }
libp2p-mdns = { version = "0.32.0-rc.1", path = "protocols/mdns", optional = true }
libp2p-tcp = { version = "0.30.0-rc.1", path = "transports/tcp", default-features = false, optional = true }
libp2p-websocket = { version = "0.31.0-rc.1", path = "transports/websocket", optional = true }

[dev-dependencies]
async-std = { version = "1.6.2", features = ["attributes"] }
Expand Down
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,11 @@ Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).
> - "Too long, didn't read" is not a valid excuse for not knowing what is in
> this document.
## Maintainers

- Max Inden ([@mxinden](https://github.com/mxinden/))
- Thomas Eizinger ([@thomaseizinger](https://github.com/thomaseizinger))

## Notable users

(open a pull request if you want your project to be added here)
Expand Down
15 changes: 14 additions & 1 deletion core/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# 0.30.0 [unreleased]
# 0.30.0-rc.1 [2021-10-15]

- Add `ConnectionLimit::with_max_established` (see [PR 2137]).

Expand Down Expand Up @@ -36,6 +36,17 @@
- Add `SignedEnvelope` and `PeerRecord` according to [RFC0002] and [RFC0003]
(see [PR 2107]).

- Report `ListenersEvent::Closed` when dropping a listener in `ListenersStream::remove_listener`,
return `bool` instead of `Result<(), ()>` (see [PR 2261]).

- Concurrently dial address candidates within a single dial attempt (see [PR 2248]) configured
via `Network::with_dial_concurrency_factor`.

- On success of a single address, provide errors of the thus far failed dials via
`NetworkEvent::ConnectionEstablished::outgoing`.

- On failure of all addresses, provide the errors via `NetworkEvent::DialError`.

[PR 2145]: https://github.com/libp2p/rust-libp2p/pull/2145
[PR 2213]: https://github.com/libp2p/rust-libp2p/pull/2213
[PR 2142]: https://github.com/libp2p/rust-libp2p/pull/2142
Expand All @@ -44,6 +55,8 @@
[PR 2191]: https://github.com/libp2p/rust-libp2p/pull/2191
[PR 2195]: https://github.com/libp2p/rust-libp2p/pull/2195
[PR 2107]: https://github.com/libp2p/rust-libp2p/pull/2107
[PR 2248]: https://github.com/libp2p/rust-libp2p/pull/2248
[PR 2261]: https://github.com/libp2p/rust-libp2p/pull/2261
[RFC0002]: https://github.com/libp2p/specs/blob/master/RFC/0002-signed-envelopes.md
[RFC0003]: https://github.com/libp2p/specs/blob/master/RFC/0003-routing-records.md

Expand Down
11 changes: 6 additions & 5 deletions core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name = "libp2p-core"
edition = "2018"
description = "Core traits and structs of libp2p"
version = "0.30.0"
version = "0.30.0-rc.1"
authors = ["Parity Technologies <admin@parity.io>"]
license = "MIT"
repository = "https://github.com/libp2p/rust-libp2p"
Expand All @@ -18,15 +18,15 @@ fnv = "1.0"
futures = { version = "0.3.1", features = ["executor", "thread-pool"] }
futures-timer = "3"
lazy_static = "1.2"
libsecp256k1 = { version = "0.6.0", optional = true }
libsecp256k1 = { version = "0.7.0", optional = true }
log = "0.4"
multiaddr = { version = "0.13.0" }
multihash = { version = "0.14", default-features = false, features = ["std", "multihash-impl", "identity", "sha2"] }
multistream-select = { version = "0.10", path = "../misc/multistream-select" }
parking_lot = "0.11.0"
pin-project = "1.0.0"
prost = "0.8"
rand = "0.7"
prost = "0.9"
rand = "0.8"
rw-stream-sink = "0.2.0"
sha2 = "0.9.1"
smallvec = "1.6.1"
Expand All @@ -47,10 +47,11 @@ libp2p-noise = { path = "../transports/noise" }
libp2p-tcp = { path = "../transports/tcp" }
multihash = { version = "0.14", default-features = false, features = ["arb"] }
quickcheck = "0.9.0"
rand07 = { package = "rand", version = "0.7" }
wasm-timer = "0.2"

[build-dependencies]
prost-build = "0.8"
prost-build = "0.9"

[features]
default = ["secp256k1"]
Expand Down
Loading

0 comments on commit 9f63141

Please sign in to comment.