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

Update libp2p-core #197

Merged
merged 5 commits into from
Jul 4, 2023
Merged

Update libp2p-core #197

merged 5 commits into from
Jul 4, 2023

Conversation

ackintosh
Copy link
Member

@ackintosh ackintosh commented Jun 28, 2023

Description

Update libp2p-core to the latest version so that we can remove the protoc dependency.

https://github.com/libp2p/rust-libp2p/blob/master/core/CHANGELOG.md

Notes & open questions

Notable changes of dependencies related this PR:

  • libp2p_core
    • identity moved from libp2p_core::identity to libp2p_identity since 0.40.0
  • multiaddr
    • Protocol::P2p contain a PeerId instead of a Multihash since 0.18.0
  • libp2p_identity
    • PublicKey::from_protobuf_encoding has been renamed to PublicKey::try_decode_protobuf in 0.1.2
    • PublicKey::encode_uncompressed has been renamed to PublicKey::to_bytes_uncompressed in 0.1.2
    • PublicKey::encode has been renamed to PublicKey::to_bytes in 0.1.2
    • PublicKey has been made opaque since 0.2.0

I have tested this change with the request_enr example:

$ cargo run --all-features --example request_enr /ip4/168.119.142.133/udp/9000/p2p/16Uiu2HAm6zDun1JBzHVcX7XDPxh3sPqkhfyN7dew4J5UNWAfDEdH
ENR Found:
Base64:enr:-L64QON1kt-4lAFXbqHRn6QLaNxgplXV658zfbKuOi2WNBXiOXeX7FulKi-9IXxUPnLioTlTMuTAlmIh0R-0TDX0U5qChiSHYXR0bmV0c4gAgAEAAAAAAIRldGgykGKJQe8DABAg__________-CaWSCdjSCaXCEqHeOhYlzZWNwMjU2azGhAqvHPwzUgfAmpEikOp1Vb9TU96LExblJ-cEP7yJ1ghCsiHN5bmNuZXRzD4N0Y3CCIyiDdWRwgiMo
enr:-L64QON1kt-4lAFXbqHRn6QLaNxgplXV658zfbKuOi2WNBXiOXeX7FulKi-9IXxUPnLioTlTMuTAlmIh0R-0TDX0U5qChiSHYXR0bmV0c4gAgAEAAAAAAIRldGgykGKJQe8DABAg__________-CaWSCdjSCaXCEqHeOhYlzZWNwMjU2azGhAqvHPwzUgfAmpEikOp1Vb9TU96LExblJ-cEP7yJ1ghCsiHN5bmNuZXRzD4N0Y3CCIyiDdWRwgiMo

Change checklist

  • Self-review
  • Documentation updates if relevant
  • Tests if relevant

@ackintosh ackintosh marked this pull request as ready for review July 1, 2023 07:22
@AgeManning AgeManning merged commit f78d538 into sigp:master Jul 4, 2023
@ackintosh ackintosh deleted the upgrade-libp2pcore branch July 4, 2023 22:45
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