Skip to content
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.

feat: add support for ipns and recursive to ipfs resolve #2297

Merged
merged 8 commits into from
Sep 4, 2019

Conversation

hugomrdias
Copy link
Member

@hugomrdias hugomrdias commented Jul 24, 2019

This PR adds IPNS support to resolve, makes the recursive option true by default and reworks the tests.

Jsdocs were added to the resolve method.

Two interface-core config profile tests needed to be skipped because js-ipfs doesn't support them yet

ref:
#2000

@hugomrdias hugomrdias mentioned this pull request Jul 24, 2019
15 tasks
@hugomrdias hugomrdias requested a review from lidel July 24, 2019 14:07
@hugomrdias hugomrdias self-assigned this Jul 24, 2019
src/core/components/resolve.js Show resolved Hide resolved
src/core/components/resolve.js Show resolved Hide resolved
src/core/components/resolve.js Show resolved Hide resolved
src/http/api/resources/resolve.js Outdated Show resolved Hide resolved
@@ -74,7 +74,6 @@
"bs58": "^4.0.1",
"buffer-peek-stream": "^1.0.1",
"byteman": "^1.3.5",
"callbackify": "^1.1.0",
Copy link
Member

@alanshaw alanshaw Aug 2, 2019

Choose a reason for hiding this comment

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

callbackify is used here https://github.com/ipfs/js-ipfs/blob/813048ffb32a11cfefc51c2ec8634faaff2a924e/src/core/components/files-mfs.js so will need to be migrated to promise-nodeify. Would be rad if you also migrated libp2p-kad-dht 😉🙏:

ipfs@0.37.0-rc.0 /Users/alan/Code/pl/ipfs/js-ipfs
├── callbackify@1.1.0 
└─┬ libp2p-kad-dht@0.15.3
  └── callbackify@1.1.0  deduped

@alanshaw
Copy link
Member

alanshaw commented Aug 2, 2019

BREAKING CHANGE: recursive is now true by default in ipfs resolve

@alanshaw
Copy link
Member

@hugomrdias 🙏 please can we have this one fixed up?

@alanshaw alanshaw mentioned this pull request Aug 27, 2019
66 tasks
@hugomrdias hugomrdias force-pushed the feat/resolve-ipns-recursive branch 2 times, most recently from 57db3aa to 41d2749 Compare September 3, 2019 09:36
Copy link
Member

@alanshaw alanshaw left a comment

Choose a reason for hiding this comment

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

Can you please unskip the resolve with IPNS interface tests?

{
name: 'should resolve an IPNS DNS link',
reason: 'TODO: IPNS resolve not yet implemented https://github.com/ipfs/js-ipfs/issues/1918'
},
{
name: 'should resolve IPNS link recursively',
reason: 'TODO: IPNS resolve not yet implemented https://github.com/ipfs/js-ipfs/issues/1918'
},

@alanshaw alanshaw added the status/blocked Unable to be worked further until needs are met label Sep 3, 2019
@alanshaw
Copy link
Member

alanshaw commented Sep 3, 2019

blocked by #2416

@alanshaw alanshaw removed the status/blocked Unable to be worked further until needs are met label Sep 4, 2019
@alanshaw
Copy link
Member

alanshaw commented Sep 4, 2019

Ok, DNS on ipfs.io has been fixed - @hugomrdias can you fix up the other test failures please? 🙏

This PR add IPNS support to resolve, makes the recursive option true by default and reworks the tests.

Jsdocs were add to the resolve methods.

Two interface-core config profile tests needed to be skipped because js-ipfs doesn't support them yet

needs:
ipfs-inactive/interface-js-ipfs-core#504
the api docs doesn't have this options so it's best to remove and simplify the logic
@hugomrdias
Copy link
Member Author

ready

@alanshaw alanshaw merged commit 039675e into master Sep 4, 2019
@alanshaw alanshaw deleted the feat/resolve-ipns-recursive branch September 4, 2019 17:17
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants