From a634915fb6d68f65ba3bb2d224ee007b8e5fdef4 Mon Sep 17 00:00:00 2001 From: Hugo Dias Date: Fri, 26 Oct 2018 10:29:03 +0100 Subject: [PATCH 1/3] fix: add missing deps --- package.json | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 6a214ca42..8066405a3 100644 --- a/package.json +++ b/package.json @@ -23,17 +23,19 @@ "release-minor": "aegir release --type minor ", "release-major": "aegir release --type major ", "coverage": "aegir coverage --timeout 100000", - "coverage-publish": "aegir coverage --provider coveralls --timeout 100000" + "coverage-publish": "aegir coverage --provider coveralls --timeout 100000", + "dep-check": "npx dependency-check package.json './test/**/*.js' './src/**/*.js'" }, "dependencies": { "async": "^2.6.1", "big.js": "^5.1.2", - "bl": "^2.0.1", + "bl": "^2.1.1", "bs58": "^4.0.1", "cids": "~0.5.3", "concat-stream": "^1.6.2", "debug": "^3.1.0", "detect-node": "^2.0.3", + "end-of-stream": "^1.4.1", "flatmap": "0.0.3", "glob": "^7.1.2", "ipfs-block": "~0.7.1", @@ -63,7 +65,8 @@ "stream-http": "^3.0.0", "stream-to-pull-stream": "^1.7.2", "streamifier": "~0.1.1", - "tar-stream": "^1.6.1" + "tar-stream": "^1.6.1", + "through2": "^2.0.3" }, "engines": { "node": ">=8.0.0", From 46bbef251590c31e3da0ddf4497c4fd8dfe67029 Mon Sep 17 00:00:00 2001 From: Hugo Dias Date: Tue, 30 Oct 2018 12:16:53 +0000 Subject: [PATCH 2/3] fix: remove unused deps (#880) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * chore: remove ipld formats re-export (#872) Prior to this change the `ipld-dag-cbor` and `ipld-dag-pb` modules are re-exported so that can be accessed within the Browser bundle. Those modules normally don't need to be used directly, they are kind of implementation details of IPLD. Hence remove them. BREAKING CHANGE: remove `types.dagCBOR` and `types.dagPB` from public API If you need the `ipld-dag-cbor` or `ipld-dag-pb` module in the Browser, you need to bundle them yourself. * chore: update to ipld-dag-cbor 0.13 No further changes are needed as js-ipfs-api is getting the raw blocks from IPFS and does the whole parsing client-sided in JavaScript. BREAKING CHANGE: dag-cbor nodes now represent links as CID objects The API for [dag-cbor](https://github.com/ipld/js-ipld-dag-cbor) changed. Links are no longer represented as JSON objects (`{"/": "base-encoded-cid"}`, but as [CID objects](https://github.com/ipld/js-cid). `ipfs.dag.get()` and now always return links as CID objects. `ipfs.dag.put()` also expects links to be represented as CID objects. The old-style JSON objects representation is still supported, but deprecated. Prior to this change: ```js const cid = new CID('QmXed8RihWcWFXRRmfSRG9yFjEbXNxu1bDwgCFAN8Dxcq5') // Link as JSON object representation const putCid = await ipfs.dag.put({link: {'/': cid.toBaseEncodedString()}}) const result = await ipfs.dag.get(putCid) console.log(result.value) ``` Output: ```js { link: { '/': } } ``` Now: ```js const cid = new CID('QmXed8RihWcWFXRRmfSRG9yFjEbXNxu1bDwgCFAN8Dxcq5') // Link as CID object const putCid = await ipfs.dag.put({link: cid}) const result = await ipfs.dag.get(putCid) console.log(result.value) ``` Output: ```js { link: CID { codec: 'dag-pb', version: 0, multihash: } } ``` See https://github.com/ipld/ipld/issues/44 for more information on why this change was made. * chore: update deps * fix: remove unused deps * chore: remove socket.io, not used anymore --- package.json | 46 ++++++++++++++++++++++------------------------ 1 file changed, 22 insertions(+), 24 deletions(-) diff --git a/package.json b/package.json index 8066405a3..628e84b5c 100644 --- a/package.json +++ b/package.json @@ -28,44 +28,44 @@ }, "dependencies": { "async": "^2.6.1", - "big.js": "^5.1.2", - "bl": "^2.1.1", + "big.js": "^5.2.2", + "bl": "^2.1.2", "bs58": "^4.0.1", - "cids": "~0.5.3", + "cids": "~0.5.5", "concat-stream": "^1.6.2", - "debug": "^3.1.0", - "detect-node": "^2.0.3", + "debug": "^4.1.0", + "detect-node": "^2.0.4", "end-of-stream": "^1.4.1", "flatmap": "0.0.3", - "glob": "^7.1.2", - "ipfs-block": "~0.7.1", - "ipfs-unixfs": "~0.1.15", + "glob": "^7.1.3", + "ipfs-block": "~0.8.0", + "ipfs-unixfs": "~0.1.16", "ipld-dag-cbor": "~0.13.0", - "ipld-dag-pb": "~0.14.6", - "is-ipfs": "~0.4.2", + "ipld-dag-pb": "~0.14.11", + "is-ipfs": "~0.4.7", "is-pull-stream": "0.0.0", "is-stream": "^1.1.0", - "libp2p-crypto": "~0.13.0", + "libp2p-crypto": "~0.14.0", "lodash": "^4.17.11", "lru-cache": "^4.1.3", "multiaddr": "^5.0.0", - "multibase": "~0.4.0", - "multihashes": "~0.4.13", + "multibase": "~0.5.0", + "multihashes": "~0.4.14", "ndjson": "^1.5.0", "once": "^1.4.0", - "peer-id": "~0.11.0", + "peer-id": "~0.12.0", "peer-info": "~0.14.1", "promisify-es6": "^1.0.3", - "pull-defer": "~0.2.2", + "pull-defer": "~0.2.3", "pull-pushable": "^2.2.0", "pull-stream-to-stream": "^1.3.4", "pump": "^3.0.0", "qs": "^6.5.2", - "readable-stream": "^2.3.6", + "readable-stream": "^3.0.6", "stream-http": "^3.0.0", "stream-to-pull-stream": "^1.7.2", "streamifier": "~0.1.1", - "tar-stream": "^1.6.1", + "tar-stream": "^1.6.2", "through2": "^2.0.3" }, "engines": { @@ -77,19 +77,17 @@ "url": "https://github.com/ipfs/js-ipfs-api" }, "devDependencies": { - "aegir": "^15.1.0", + "aegir": "^17.0.1", "browser-process-platform": "~0.1.1", - "chai": "^4.1.2", + "chai": "^4.2.0", "cross-env": "^5.2.0", "dirty-chai": "^2.0.1", - "eslint-plugin-react": "^7.10.0", + "eslint-plugin-react": "^7.11.1", "go-ipfs-dep": "~0.4.17", "gulp": "^3.9.1", "interface-ipfs-core": "~0.81.0", - "ipfsd-ctl": "~0.39.0", - "pull-stream": "^3.6.8", - "socket.io": "^2.1.1", - "socket.io-client": "^2.1.1", + "ipfsd-ctl": "~0.39.5", + "pull-stream": "^3.6.9", "stream-equal": "^1.1.1" }, "keywords": [ From e7b5f8808289221e25abae60ea9f329c95bc9741 Mon Sep 17 00:00:00 2001 From: David Dias Date: Tue, 30 Oct 2018 12:36:53 +0000 Subject: [PATCH 3/3] chore: update interface-ipfs-core --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 628e84b5c..db0ac5cb6 100644 --- a/package.json +++ b/package.json @@ -85,7 +85,7 @@ "eslint-plugin-react": "^7.11.1", "go-ipfs-dep": "~0.4.17", "gulp": "^3.9.1", - "interface-ipfs-core": "~0.81.0", + "interface-ipfs-core": "~0.83.0", "ipfsd-ctl": "~0.39.5", "pull-stream": "^3.6.9", "stream-equal": "^1.1.1"