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

feat(kad): derive Copy for kbucket::key::Key #5317

Merged
merged 6 commits into from
Apr 19, 2024

Conversation

drHuangMHT
Copy link
Contributor

@drHuangMHT drHuangMHT commented Apr 17, 2024

Description

Derive Copy for kbucket::key::Key and kbucket::key::KeyBytes because Key is almost always used with PeerId, which is Copy.
This will make it easier to iterate over kbuckets.

Notes & open questions

Quality of life feature.

Change checklist

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • A changelog entry has been made in the appropriate crates

@drHuangMHT drHuangMHT changed the title feat(kad): derive Copy for kbucket::Key feat(kad): derive Copy for kbucket::key::Key Apr 17, 2024
Copy link
Member

@jxs jxs 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! @drHuangMHT 🚀 this is ready to be merged right?

@drHuangMHT drHuangMHT marked this pull request as ready for review April 19, 2024 00:00
@drHuangMHT drHuangMHT marked this pull request as draft April 19, 2024 00:06
@drHuangMHT
Copy link
Contributor Author

LGTM, thanks! @drHuangMHT 🚀 this is ready to be merged right?

Not yet, still need to address clippy lints.

@drHuangMHT drHuangMHT marked this pull request as ready for review April 19, 2024 01:23
@drHuangMHT
Copy link
Contributor Author

@jxs Staged, need a re-approval.

Copy link
Contributor

@guillaumemichel guillaumemichel left a comment

Choose a reason for hiding this comment

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

👍🏻

@jxs jxs added the send-it label Apr 19, 2024
@mergify mergify bot merged commit 31457f6 into libp2p:master Apr 19, 2024
71 of 72 checks passed
@drHuangMHT drHuangMHT deleted the kad-key-copy branch April 22, 2024 00:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants