Skip to content

op-node,op-e2e: update libp2p libs, update libp2p gossip settings#3875

Merged
mslipper merged 4 commits intodevelopfrom
p2p-updates
Nov 7, 2022
Merged

op-node,op-e2e: update libp2p libs, update libp2p gossip settings#3875
mslipper merged 4 commits intodevelopfrom
p2p-updates

Conversation

@protolambda
Copy link
Copy Markdown
Contributor

@protolambda protolambda commented Nov 4, 2022

Description

PR changes:

  • update github.com/libp2p/go-libp2p
  • remove github.com/libp2p/go-libp2p-core since it was deprecated and moved into github.com/libp2p/go-libp2p/core
  • remove https://github.com/libp2p/go-libp2p-peerstore since it was deprecated and moved into github.com/libp2p/go-libp2p/peerstore
  • update gossip params to deduplicate a constant, and match the L1 value
  • update gossip params to use the WithSeenMessagesTTL I upstreamed a few months ago, to not have to configure it with a global anymore
  • update the libp2p crypto dependencies
  • go mod tidy to fix the dependencies
  • add a no-op use for chainhash.HashSize for the op-node go.mod to not automatically remove the chainhash dependency, since it's an ambiguous indirect dependency due to it having the same path in the legacy btcd and the isolated module. This resolves go mod tidy issues.
  • use the underlying decred public key types, instead of the btcd one, avoiding the btcd import.

Metadata

Fix ENG-2708

@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Nov 4, 2022

⚠️ No Changeset found

Latest commit: a598276

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link
Copy Markdown
Contributor

@trianglesphere trianglesphere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm. Thanks for taking care of all of the updates.

@tynes
Copy link
Copy Markdown
Contributor

tynes commented Nov 4, 2022

Looks good to me, will approve when the deps are fixed

@protolambda
Copy link
Copy Markdown
Contributor Author

go mod tidy is reverting a crypto lib update, since geth (and maybe the mnemonics lib too?) use the older version and they get priority somehow, even though it compiles fine with the new version. We're starting to update both of those today though, so then I'll update this PR with a rebase + new go mod tidy to get it sorted out.

@tynes
Copy link
Copy Markdown
Contributor

tynes commented Nov 4, 2022

This should help: #3880

@trianglesphere
Copy link
Copy Markdown
Contributor

Go prefers using the oldest rather than newest version: https://go.dev/ref/mod#minimal-version-selection

@mergify
Copy link
Copy Markdown
Contributor

mergify bot commented Nov 5, 2022

Hey @protolambda! This PR has merge conflicts. Please fix them before continuing review.

@mergify mergify bot added the conflict label Nov 5, 2022
@protolambda
Copy link
Copy Markdown
Contributor Author

Will resolve merge conflicts once the op-geth PR lands (#3892 )

@trianglesphere
Copy link
Copy Markdown
Contributor

Will resolve merge conflicts once the op-geth PR lands (#3892 )

#3892 has just landed @protolambda

@tynes
Copy link
Copy Markdown
Contributor

tynes commented Nov 7, 2022

Hopefully the build issues are fixed now, feels good to be on modern geth as a dep

@protolambda
Copy link
Copy Markdown
Contributor Author

Rebased on develop and cleaned up the dependency issues. We can remove the replace statements in op-e2e/go.mod only after we make releases of our own modules, to get rid of the stale dependency of the old github.com/miguelmota/go-ethereum-hdwallet which still uses an older github.com/btcsuite/btcd/btcec version.

@protolambda protolambda requested review from mslipper and tynes November 7, 2022 22:58
// force to use the new chainhash module, and not the legacy chainhash package btcd module
const _ = chainhash.HashSize

// force to use the btcd module, while the keycard dependency in geth still depends on it,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mslipper mslipper merged commit c6f06ee into develop Nov 7, 2022
@mslipper mslipper deleted the p2p-updates branch November 7, 2022 23:25
@mslipper mslipper mentioned this pull request Nov 10, 2022
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.

4 participants