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

Awesome IPLD endeavour #532

Merged
merged 10 commits into from
Nov 1, 2016
Merged

Awesome IPLD endeavour #532

merged 10 commits into from
Nov 1, 2016

Conversation

daviddias
Copy link
Member

@daviddias daviddias commented Oct 21, 2016

This makes js-ipfs understand how to use IPLD.

As a compromise, had to turn off bitswap as its migration to IPLD is not trivial. We have a focused milestone for it (Bitswap complete).

The last thing to add to this PR is the new dag API.

if (typeof hash === 'string') {
return multihash.fromB58String(hash)
function cleanCid (cid) {
if (cid.constructor.name === 'CID') {
Copy link
Member

Choose a reason for hiding this comment

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

please use require('cids').isCID instead

@daviddias
Copy link
Member Author

daviddias commented Oct 26, 2016

PR Table from: ipld/js-ipld#60 (comment)

PR CR RFM M
ipld/js-ipld#60 ✔️ ✔️ ✔️
ipld/js-ipld-dag-pb#1 ✔️ ✔️ ✔️
ipld/js-ipld-dag-cbor#25 ✔️ ✔️ ✔️
multiformats/js-cid#4 ✔️ ✔️ ✔️
multiformats/multicodec#16
ipld/js-ipld-block#5 ✔️ ✔️ ✔️
ipfs/js-ipfs-block-service#27 ✔️ ✔️ ✔️
ipfs/js-ipfs-repo#89 ✔️ ✔️ ✔️
ipfs-inactive/interface-js-ipfs-core#78 ✔️ ✔️ ✔️
ipfs-inactive/js-ipfs-http-client#398 ✔️ ✔️ ✔️
ipfs-inactive/js-ipfs-unixfs-engine#74 ✔️ ✔️ ✔️
#532 ✔️ ✔️

@daviddias
Copy link
Member Author

Can I get some CR ? :)

@daviddias
Copy link
Member Author

Also added as a bonus, a refreshed readme :)

@dignifiedquire
Copy link
Member

@diasdavid why the red CI?

@daviddias
Copy link
Member Author

daviddias commented Oct 30, 2016

@dignifiedquire it is that 'tmpdir' thing, I was grepping through to find where it was coming from, but with no luck, any idea?

Copy link
Member

@dignifiedquire dignifiedquire left a comment

Choose a reason for hiding this comment

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

Just two small things

@@ -22,7 +22,7 @@ function addBlock (buf) {
throw err
}

console.log(bs58.encode(block.key).toString())
console.log(bs58.encode(block.key()).toString())
Copy link
Member

Choose a reason for hiding this comment

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

Why doesn't this throw, shouldn't block.key() be async?

Copy link
Member Author

Choose a reason for hiding this comment

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

Not the released version apparently https://github.com/ipfs/js-ipfs-block

const link = new DAGLink(argv.name, size, multihash)

ipfs.object.patch.addLink(argv.root, link, {enc: 'base58'})
.then((node) => {
Copy link
Member

Choose a reason for hiding this comment

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

let's not use promises mixed with callback

@@ -10,7 +10,7 @@ const createTempNode = require('../utils/temp-node')
const repoPath = require('./index').repoPath
const ipfs = require('../utils/ipfs-exec')(repoPath)

describe('bitswap', () => {
describe.skip('bitswap', () => {
Copy link
Member

Choose a reason for hiding this comment

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

😿

Copy link
Member Author

Choose a reason for hiding this comment

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

Just for a little bit :)

@daviddias daviddias force-pushed the awesome-ipld branch 3 times, most recently from ce53361 to ffdf640 Compare November 1, 2016 08:13
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants