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

fix: allow passing cid encoded ipns keys #117

Merged
merged 3 commits into from
Oct 23, 2024
Merged

fix: allow passing cid encoded ipns keys #117

merged 3 commits into from
Oct 23, 2024

Conversation

2color
Copy link
Member

@2color 2color commented Oct 17, 2024

Description

  • Fixes a bug whereby passing a base36 encoded IPNS key, e.g. ipns://k51qzi5uqu5dhp48cti0590jyvwgxssrii0zdf19pyfsxwoqomqvfg6bg8qj3s, throws an error: helia:verified-fetch:parse-url-string:error could not parse PeerId string "k51qzi5uqu5dhp48cti0590jyvwgxssrii0zdf19pyfsxwoqomqvfg6bg8qj3s" +0ms InvalidParametersError: Please pass a multibase decoder for strings that do not start with "1" or "Q"

Depends on

libp2p/js-libp2p#2773

Change checklist

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation if necessary (this includes comments as well)
  • I have added tests that prove my fix is effective or that my feature works

@2color 2color requested a review from a team as a code owner October 17, 2024 14:03
@2color
Copy link
Member Author

2color commented Oct 23, 2024

Based on libp2p/js-libp2p#2772 (comment), I've implemented the handling of CID enocded PeerIDs in here.

@2color 2color merged commit 1836e40 into main Oct 23, 2024
20 checks passed
@2color 2color deleted the readd-base36 branch October 23, 2024 14:49
github-actions bot pushed a commit that referenced this pull request Oct 23, 2024
Copy link

🎉 This PR is included in version @helia/verified-fetch-v2.0.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

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.

2 participants