From 51da0a5c92a6c236be9c4a5e66bc6549650d1bc0 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Mon, 16 Jul 2018 18:38:13 +0200 Subject: [PATCH 01/31] feat: add libdweb-build target This is a first step on the road to native protocol handler and more. mozilla/libdweb is included as a git submodule, which enables us to develop against latest API prototypes with as little overhead as possible. `libdweb-build` will produce extension bundle with access to experimental APIs `firefox:libdweb` will start Firefox Nightly with mentioned bundle. Make sure firefox-nightly is on your PATH --- .gitmodules | 3 +++ add-on/manifest.firefox-libdweb.json | 23 +++++++++++++++++++++++ libdweb | 1 + package.json | 3 +++ 4 files changed, 30 insertions(+) create mode 100644 .gitmodules create mode 100644 add-on/manifest.firefox-libdweb.json create mode 160000 libdweb diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 000000000..dcc708702 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "libdweb"] + path = libdweb + url = https://github.com/mozilla/libdweb.git diff --git a/add-on/manifest.firefox-libdweb.json b/add-on/manifest.firefox-libdweb.json new file mode 100644 index 000000000..ccb6bfa52 --- /dev/null +++ b/add-on/manifest.firefox-libdweb.json @@ -0,0 +1,23 @@ +{ + "applications": { + "gecko": { + "id": "ipfs-companion-libdweb-build@ci.ipfs.team" + } + }, + "experiment_apis": { + "protocol": { + "schema": "../libdweb/src/protocol/protocol.json", + "child": { + "scopes": ["addon_child"], + "paths": [["protocol"]], + "script": "../libdweb/src/protocol/client.js" + }, + "parent": { + "events": ["startup"], + "scopes": ["addon_parent"], + "paths": [["protocol"]], + "script": "../libdweb/src/protocol/host.js" + } + } + } +} diff --git a/libdweb b/libdweb new file mode 160000 index 000000000..c36533ec7 --- /dev/null +++ b/libdweb @@ -0,0 +1 @@ +Subproject commit c36533ec7aa22dfae8cf7ff4e33eafaafb133ed1 diff --git a/package.json b/package.json index 0e3ec5e02..50548ee4b 100644 --- a/package.json +++ b/package.json @@ -29,6 +29,7 @@ "bundle:generic": "shx cp add-on/manifest.common.json add-on/manifest.json && web-ext build -a build/generic", "bundle:firefox": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/", "bundle:firefox:beta": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-beta.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/beta/", + "bundle:firefox:libdweb": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-libdweb.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/libdweb/", "watch": "npm-run-all build:copy --parallel watch:*", "watch:js": "run-p watch:js:*", "watch:js:webpack": "webpack --watch --progress -d --devtool inline-source-map", @@ -42,6 +43,7 @@ "precommit": "run-s lint:standard", "prepush": "run-s clean build lint test", "firefox": "web-ext run --browser-console", + "firefox:libdweb": "cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=nightly --browser-console --url about:debugging", "ci": "run-s ci:*", "ci:install": "npx yarn@1.7.0 install --frozen-lockfile || npx yarn@1.7.0 install --frozen-lockfile", "ci:test": "npx yarn@1.7.0 test", @@ -49,6 +51,7 @@ "beta-build": "docker build -t ipfs-companion . && docker run -it -e RELEASE_CHANNEL=beta -v $(pwd)/build:/usr/src/app/build ipfs-companion yarn ci:build", "release-build": "docker build -t ipfs-companion . && docker run -it -e RELEASE_CHANNEL=stable -v $(pwd)/build:/usr/src/app/build ipfs-companion yarn ci:build", "dev-build": "npx yarn@1.7.0 && npx yarn@1.7.0 build", + "libdweb-build": "git submodule update --init --checkout --depth 1 libdweb && npx run-s dev-build bundle:firefox:libdweb", "yarn-build": "run-s dev-build" }, "private": true, From 43bdb5f774c6af2c062e02f480101b6b0e37df37 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Tue, 17 Jul 2018 17:25:56 +0200 Subject: [PATCH 02/31] feat: PoC for browser.protocol.registerProtocol Just a basic handler that reads images and returns them to the browser. TODO: - support directory listing - support streaming - support mime-sniffing --- .babelrc | 18 ++++ add-on/manifest.firefox-libdweb.json | 1 + add-on/src/lib/ipfs-companion.js | 11 +- add-on/src/lib/ipfs-protocol-libdweb.js | 36 +++++++ ...rotocol.js => ipfs-protocol-muon-brave.js} | 1 + add-on/src/lib/runtime-checks.js | 2 +- package.json | 6 ++ yarn.lock | 101 +++++++++++++++++- 8 files changed, 169 insertions(+), 7 deletions(-) create mode 100644 .babelrc create mode 100644 add-on/src/lib/ipfs-protocol-libdweb.js rename add-on/src/lib/{ipfs-protocol.js => ipfs-protocol-muon-brave.js} (98%) diff --git a/.babelrc b/.babelrc new file mode 100644 index 000000000..1a9b2db00 --- /dev/null +++ b/.babelrc @@ -0,0 +1,18 @@ +{ + "plugins": [ + "syntax-async-generators" + ], + "presets": [ + [ + "env", + { + "targets": { + "browsers": [ + "firefox >= 59", + "chrome >= 67" + ] + } + } + ] + ] +} diff --git a/add-on/manifest.firefox-libdweb.json b/add-on/manifest.firefox-libdweb.json index ccb6bfa52..c2668a874 100644 --- a/add-on/manifest.firefox-libdweb.json +++ b/add-on/manifest.firefox-libdweb.json @@ -4,6 +4,7 @@ "id": "ipfs-companion-libdweb-build@ci.ipfs.team" } }, + "protocol_handlers": [], "experiment_apis": { "protocol": { "schema": "../libdweb/src/protocol/protocol.json", diff --git a/add-on/src/lib/ipfs-companion.js b/add-on/src/lib/ipfs-companion.js index e8866083d..612e8fc18 100644 --- a/add-on/src/lib/ipfs-companion.js +++ b/add-on/src/lib/ipfs-companion.js @@ -8,7 +8,6 @@ const { createIpfsPathValidator, urlAtPublicGw } = require('./ipfs-path') const createDnsLink = require('./dns-link') const { createRequestModifier, redirectOptOutHint } = require('./ipfs-request') const { initIpfsClient, destroyIpfsClient } = require('./ipfs-client') -const { createIpfsUrlProtocolHandler } = require('./ipfs-protocol') const createNotifier = require('./notifier') const createCopier = require('./copier') const createRuntimeChecks = require('./runtime-checks') @@ -100,12 +99,18 @@ module.exports = async function init () { browser.runtime.onMessage.addListener(onRuntimeMessage) browser.runtime.onConnect.addListener(onRuntimeConnect) - if (runtime.hasNativeProtocolHandler) { - console.log('[ipfs-companion] registerStringProtocol available. Adding ipfs:// handler') + if (runtime.hasNativeProtocolHandler && browser.protocol.registerStringProtocol) { + console.log('[ipfs-companion] registerStringProtocol from Muon-Brave is available. Adding ipfs:// handler') + const { createIpfsUrlProtocolHandler } = require('./ipfs-protocol-muon-brave') browser.protocol.registerStringProtocol('ipfs', createIpfsUrlProtocolHandler(() => ipfs)) + } else if (runtime.hasNativeProtocolHandler && browser.protocol.registerProtocol) { + console.log('[ipfs-companion] registerProtocol from mozilla/libdweb is available. Adding ipfs:// handler') + const { createIpfsUrlProtocolHandler } = require('./ipfs-protocol-libdweb') + browser.protocol.registerProtocol('ipfs', createIpfsUrlProtocolHandler(() => ipfs)) } else { console.log('[ipfs-companion] browser.protocol.registerStringProtocol not available, native protocol will not be registered') } + console.log(`[ipfs-companion] registerProtocol: ${browser.protocol.registerProtocol}`, browser.protocol.registerProtocol) } // Register Content Script responsible for loading window.ipfs (ipfsProxy) diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js new file mode 100644 index 000000000..1fe6e13c8 --- /dev/null +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -0,0 +1,36 @@ +const { mimeSniff } = require('./mime-sniff') +const toArrayBuffer = require('to-arraybuffer') + +/* protocol handler for mozilla/libdweb */ + +exports.createIpfsUrlProtocolHandler = (getIpfs) => { + return request => { + console.time('[ipfs-companion] IpfsUrlProtocolHandler') + console.log(`[ipfs-companion] handling ${request.url}`) + + let path = request.url.replace('ipfs://', '/') + path = path.startsWith('/ipfs') ? path : `/ipfs${path}` + const ipfs = getIpfs() + + try { + return { + // TODO: + // - support directory listing + // - support streaming + // - either support mime-sniffing of read data, + // or fix crash when contentType is omited (https://github.com/mozilla/libdweb/issues/20) + contentType: 'image/jpeg', + content: (async function * () { + const data = await ipfs.files.cat(path) + const mimeType = mimeSniff(data, path) || 'text/plain' + console.log(`[ipfs-companion] ipfs:// content generator read ${path} and mime-sniffed ${mimeType}`) + yield toArrayBuffer(data) + })() + } + } catch (err) { + console.error('[ipfs-companion] failed to get data', err) + } + + console.timeEnd('[ipfs-companion] IpfsUrlProtocolHandler') + } +} diff --git a/add-on/src/lib/ipfs-protocol.js b/add-on/src/lib/ipfs-protocol-muon-brave.js similarity index 98% rename from add-on/src/lib/ipfs-protocol.js rename to add-on/src/lib/ipfs-protocol-muon-brave.js index b49fb1d4d..e2b6ddf78 100644 --- a/add-on/src/lib/ipfs-protocol.js +++ b/add-on/src/lib/ipfs-protocol-muon-brave.js @@ -1,3 +1,4 @@ +/* this file requires Muon-Brave */ const { mimeSniff } = require('./mime-sniff') const dirView = require('./dir-view') const PathUtils = require('ipfs/src/http/gateway/utils/path') diff --git a/add-on/src/lib/runtime-checks.js b/add-on/src/lib/runtime-checks.js index a3c6ca85e..2e212220a 100644 --- a/add-on/src/lib/runtime-checks.js +++ b/add-on/src/lib/runtime-checks.js @@ -20,7 +20,7 @@ async function createRuntimeChecks (browser) { const browserInfo = await getBrowserInfo(browser) const runtimeBrowserName = browserInfo ? browserInfo.name : 'unknown' const runtimeIsFirefox = !!runtimeBrowserName.match('Firefox') - const runtimeHasNativeProtocol = !!(browser && browser.protocol && browser.protocol.registerStringProtocol) + const runtimeHasNativeProtocol = !!(browser && browser.protocol && (browser.protocol.registerProtocol || browser.protocol.registerStringProtocol)) // platform const platformInfo = await getPlatformInfo(browser) const runtimeIsAndroid = platformInfo ? platformInfo.os === 'android' : false diff --git a/package.json b/package.json index 50548ee4b..77dcd7a2b 100644 --- a/package.json +++ b/package.json @@ -56,9 +56,14 @@ }, "private": true, "preferGlobal": false, + "standard": { + "parser": "babel-eslint" + }, "devDependencies": { "babel-core": "6.26.3", + "babel-eslint": "8.2.6", "babel-loader": "7.1.4", + "babel-plugin-syntax-async-generators": "6.13.0", "babel-preset-env": "1.7.0", "chai": "4.1.2", "cross-env": "5.2.0", @@ -104,6 +109,7 @@ "path-browserify": "0.0.1", "piggybacker": "2.0.0", "tachyons": "4.9.1", + "to-arraybuffer": "1.0.1", "webextension-polyfill": "0.1.2" } } diff --git a/yarn.lock b/yarn.lock index aa9205cb0..dbf3362da 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,12 +2,28 @@ # yarn lockfile v1 +"@babel/code-frame@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0-beta.44.tgz#2a02643368de80916162be70865c97774f3adbd9" + dependencies: + "@babel/highlight" "7.0.0-beta.44" + "@babel/code-frame@7.0.0-beta.51": version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0-beta.51.tgz#bd71d9b192af978df915829d39d4094456439a0c" dependencies: "@babel/highlight" "7.0.0-beta.51" +"@babel/generator@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.0.0-beta.44.tgz#c7e67b9b5284afcf69b309b50d7d37f3e5033d42" + dependencies: + "@babel/types" "7.0.0-beta.44" + jsesc "^2.5.1" + lodash "^4.2.0" + source-map "^0.5.0" + trim-right "^1.0.1" + "@babel/generator@7.0.0-beta.51": version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.0.0-beta.51.tgz#6c7575ffde761d07485e04baedc0392c6d9e30f6" @@ -18,6 +34,14 @@ source-map "^0.5.0" trim-right "^1.0.1" +"@babel/helper-function-name@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.0.0-beta.44.tgz#e18552aaae2231100a6e485e03854bc3532d44dd" + dependencies: + "@babel/helper-get-function-arity" "7.0.0-beta.44" + "@babel/template" "7.0.0-beta.44" + "@babel/types" "7.0.0-beta.44" + "@babel/helper-function-name@7.0.0-beta.51": version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.0.0-beta.51.tgz#21b4874a227cf99ecafcc30a90302da5a2640561" @@ -26,18 +50,38 @@ "@babel/template" "7.0.0-beta.51" "@babel/types" "7.0.0-beta.51" +"@babel/helper-get-function-arity@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0-beta.44.tgz#d03ca6dd2b9f7b0b1e6b32c56c72836140db3a15" + dependencies: + "@babel/types" "7.0.0-beta.44" + "@babel/helper-get-function-arity@7.0.0-beta.51": version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0-beta.51.tgz#3281b2d045af95c172ce91b20825d85ea4676411" dependencies: "@babel/types" "7.0.0-beta.51" +"@babel/helper-split-export-declaration@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.0.0-beta.44.tgz#c0b351735e0fbcb3822c8ad8db4e583b05ebd9dc" + dependencies: + "@babel/types" "7.0.0-beta.44" + "@babel/helper-split-export-declaration@7.0.0-beta.51": version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.0.0-beta.51.tgz#8a6c3f66c4d265352fc077484f9f6e80a51ab978" dependencies: "@babel/types" "7.0.0-beta.51" +"@babel/highlight@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0-beta.44.tgz#18c94ce543916a80553edcdcf681890b200747d5" + dependencies: + chalk "^2.0.0" + esutils "^2.0.2" + js-tokens "^3.0.0" + "@babel/highlight@7.0.0-beta.51": version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0-beta.51.tgz#e8844ae25a1595ccfd42b89623b4376ca06d225d" @@ -50,6 +94,15 @@ version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.0.0-beta.51.tgz#27cec2df409df60af58270ed8f6aa55409ea86f6" +"@babel/template@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.0.0-beta.44.tgz#f8832f4fdcee5d59bf515e595fc5106c529b394f" + dependencies: + "@babel/code-frame" "7.0.0-beta.44" + "@babel/types" "7.0.0-beta.44" + babylon "7.0.0-beta.44" + lodash "^4.2.0" + "@babel/template@7.0.0-beta.51": version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.0.0-beta.51.tgz#9602a40aebcf357ae9677e2532ef5fc810f5fbff" @@ -59,6 +112,21 @@ "@babel/types" "7.0.0-beta.51" lodash "^4.17.5" +"@babel/traverse@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.0.0-beta.44.tgz#a970a2c45477ad18017e2e465a0606feee0d2966" + dependencies: + "@babel/code-frame" "7.0.0-beta.44" + "@babel/generator" "7.0.0-beta.44" + "@babel/helper-function-name" "7.0.0-beta.44" + "@babel/helper-split-export-declaration" "7.0.0-beta.44" + "@babel/types" "7.0.0-beta.44" + babylon "7.0.0-beta.44" + debug "^3.1.0" + globals "^11.1.0" + invariant "^2.2.0" + lodash "^4.2.0" + "@babel/traverse@7.0.0-beta.51": version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.0.0-beta.51.tgz#981daf2cec347a6231d3aa1d9e1803b03aaaa4a8" @@ -74,6 +142,14 @@ invariant "^2.2.0" lodash "^4.17.5" +"@babel/types@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.0.0-beta.44.tgz#6b1b164591f77dec0a0342aca995f2d046b3a757" + dependencies: + esutils "^2.0.2" + lodash "^4.2.0" + to-fast-properties "^2.0.0" + "@babel/types@7.0.0-beta.51": version "7.0.0-beta.51" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.0.0-beta.51.tgz#d802b7b543b5836c778aa691797abf00f3d97ea9" @@ -794,6 +870,17 @@ babel-core@6.26.3, babel-core@^6.26.0: slash "^1.0.0" source-map "^0.5.7" +babel-eslint@8.2.6: + version "8.2.6" + resolved "https://registry.yarnpkg.com/babel-eslint/-/babel-eslint-8.2.6.tgz#6270d0c73205628067c0f7ae1693a9e797acefd9" + dependencies: + "@babel/code-frame" "7.0.0-beta.44" + "@babel/traverse" "7.0.0-beta.44" + "@babel/types" "7.0.0-beta.44" + babylon "7.0.0-beta.44" + eslint-scope "3.7.1" + eslint-visitor-keys "^1.0.0" + babel-generator@^6.26.0: version "6.26.1" resolved "https://registry.yarnpkg.com/babel-generator/-/babel-generator-6.26.1.tgz#1844408d3b8f0d35a404ea7ac180f087a601bd90" @@ -932,6 +1019,10 @@ babel-plugin-syntax-async-functions@^6.8.0: version "6.13.0" resolved "https://registry.yarnpkg.com/babel-plugin-syntax-async-functions/-/babel-plugin-syntax-async-functions-6.13.0.tgz#cad9cad1191b5ad634bf30ae0872391e0647be95" +babel-plugin-syntax-async-generators@6.13.0: + version "6.13.0" + resolved "https://registry.yarnpkg.com/babel-plugin-syntax-async-generators/-/babel-plugin-syntax-async-generators-6.13.0.tgz#6bc963ebb16eccbae6b92b596eb7f35c342a8b9a" + babel-plugin-syntax-exponentiation-operator@^6.8.0: version "6.13.0" resolved "https://registry.yarnpkg.com/babel-plugin-syntax-exponentiation-operator/-/babel-plugin-syntax-exponentiation-operator-6.13.0.tgz#9ee7e8337290da95288201a6a57f4170317830de" @@ -1240,6 +1331,10 @@ babel-types@^6.19.0, babel-types@^6.24.1, babel-types@^6.26.0: lodash "^4.17.4" to-fast-properties "^1.0.3" +babylon@7.0.0-beta.44: + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/babylon/-/babylon-7.0.0-beta.44.tgz#89159e15e6e30c5096e22d738d8c0af8a0e8ca1d" + babylon@^6.18.0: version "6.18.0" resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.18.0.tgz#af2f3b88fa6f5c1e4c634d1a0f8eac4f55b395e3" @@ -3209,7 +3304,7 @@ eslint-plugin-standard@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/eslint-plugin-standard/-/eslint-plugin-standard-3.0.1.tgz#34d0c915b45edc6f010393c7eef3823b08565cf2" -eslint-scope@^3.7.1: +eslint-scope@3.7.1, eslint-scope@^3.7.1: version "3.7.1" resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.1.tgz#3d63c3edfda02e06e01a452ad88caacc7cdcb6e8" dependencies: @@ -6539,7 +6634,7 @@ lodash.values@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/lodash.values/-/lodash.values-4.3.0.tgz#a3a6c2b0ebecc5c2cba1c17e6e620fe81b53d347" -lodash@4.17.10, lodash@^4.17.10: +lodash@4.17.10, lodash@^4.17.10, lodash@^4.2.0: version "4.17.10" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.10.tgz#1b7793cf7259ea38fb3661d4d38b3260af8ae4e7" @@ -10303,7 +10398,7 @@ to-array@0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/to-array/-/to-array-0.1.4.tgz#17e6c11f73dd4f3d74cda7a4ff3238e9ad9bf890" -to-arraybuffer@^1.0.0: +to-arraybuffer@1.0.1, to-arraybuffer@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/to-arraybuffer/-/to-arraybuffer-1.0.1.tgz#7d229b1fcc637e466ca081180836a7aabff83f43" From 08ef6f3866eb26e8340bb32249a8ccc8ca89c536 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Tue, 17 Jul 2018 18:59:53 +0200 Subject: [PATCH 03/31] docs: notes on eveloping with libdweb --- add-on/src/lib/ipfs-protocol-libdweb.js | 2 +- docs/developer-notes.md | 5 ++ docs/libdweb.md | 81 +++++++++++++++++++++++++ package.json | 2 +- 4 files changed, 88 insertions(+), 2 deletions(-) create mode 100644 docs/libdweb.md diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 1fe6e13c8..e9c811c0e 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -17,7 +17,7 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { // TODO: // - support directory listing // - support streaming - // - either support mime-sniffing of read data, + // - either support mime-sniffing of read data in userland, // or fix crash when contentType is omited (https://github.com/mozilla/libdweb/issues/20) contentType: 'image/jpeg', content: (async function * () { diff --git a/docs/developer-notes.md b/docs/developer-notes.md index d2ec21a9b..bca67003e 100644 --- a/docs/developer-notes.md +++ b/docs/developer-notes.md @@ -7,6 +7,7 @@ * [Build and Run in Firefox](#build-and-run-in-firefox) * [Build and Manual Install in Chromium](#build-and-manual-install-in-chromium) * [Firefox for Android](#firefox-for-android) + * [Libdweb with Firefox Nightly](#libdweb) * [Useful Tasks](#useful-tasks) * [Tips](#tips) @@ -62,6 +63,10 @@ Then open up `chrome://extensions` in Chromium-based browser, enable "Developer See [`docs/firefox-for-android.md`](firefox-for-android.md) +### libdweb + +See [`docs/libdweb.md`](libdweb.md) + ## Useful Tasks Each `npm` task can be run separately, but for most of time `dev-build`, `test` and `fix:lint` are all you need. diff --git a/docs/libdweb.md b/docs/libdweb.md new file mode 100644 index 000000000..9659967fe --- /dev/null +++ b/docs/libdweb.md @@ -0,0 +1,81 @@ +# Notes on Developing with `libdweb` + +> [`mozilla/libdweb`](https://github.com/mozilla/libdweb) hosts a community +effort to implement experimental APIs for Firefox WebExtensions with a goal of +enabling dweb protocols in Firefox through browser add-ons. The long term goal +of this project is to integrate these APIs into the WebExtensions ecosystem. + +See also: +- [#343](https://github.com/ipfs-shipyard/ipfs-companion/issues/343): _Create WebExtensions Experiments to Prototype Missing APIs_ + + +## TL;DR + +1. Having `firefox-nightly` in `$PATH`, execute commands below to build and run Companion extension in libdweb-enabled context: + ``` + yarn libdweb-build + yarn firefox:libdweb + ``` + +2. Optional Smoke-Test: + - Open `ipfs://bafkreickb4yq3sr3q2xqn3z3wzimilsa4wkbx25azqbvcnihq65moyjcvi` + - Confirm `ipfs://` protocol remains in Location Bar ([example](https://ipfs.io/ipfs/bafybeie5gq4jxvzmsym6hjlwxej4rwdoxt7wadqvmmwbqi7r27fclha2va)) + +## Developer Notes + + +### Install Firefox Nightly + +- Get latest Nightly from http://nightly.mozilla.org/ + - libdweb won't run in regular release, it has to be nightly or developer edition + +### Build libdweb-enabled bundle + +``` +git submodule update --init --checkout --depth 1 libdweb +yarn +yarn build +yarn bundle:firefox:libdweb +``` + +or use all-in-one alias: +``` +yarn libdweb-build +``` + + +### Deploy in Firefox with libdweb APIs ✂️ + +To run your extension in libdweb context: + +``` +export MOZ_DISABLE_CONTENT_SANDBOX=1 +web-ext run --firefox=/path/to/nightly/firefox-bin --browser-console --url about:debugging +``` + +or use alias: + +``` +yarn firefox:libdweb +``` + + +Additional notes: + +- If you want `firefox:libdweb` to work, ensure `firefox-nightly` is on your `$PATH` + - if `firefox-nightly` is missing, create it in unpacked directory via `ln -s firefox firefox-nightly` +- After calling `libdweb-build` it is ok to use `yarn watch` – it will work as expected + +## Appendix: Smoke-Testing libdweb APIs + +#### Protocol Handler API + +1. Open `ipfs://bafkreickb4yq3sr3q2xqn3z3wzimilsa4wkbx25azqbvcnihq65moyjcvi` +1. Confirm `ipfs://` protocol remains in Location Bar ([example](https://ipfs.io/ipfs/bafybeie5gq4jxvzmsym6hjlwxej4rwdoxt7wadqvmmwbqi7r27fclha2va)) + +## References + +- [ipfs-companion/issues/#343](https://github.com/ipfs-shipyard/ipfs-companion/issues/343) – Create WebExtensions Experiments to Prototype Missing APIs +- https://github.com/mozilla/libdweb/ – Extension context containing an experimental libdweb APIs +- https://github.com/orgs/libdweb – API adapters for seamless libdweb integration +- `#dweb` @ [irc.mozilla.org](https://wiki.mozilla.org/IRC#Connect_to_the_Mozilla_IRC_server) diff --git a/package.json b/package.json index 77dcd7a2b..72db93975 100644 --- a/package.json +++ b/package.json @@ -43,7 +43,7 @@ "precommit": "run-s lint:standard", "prepush": "run-s clean build lint test", "firefox": "web-ext run --browser-console", - "firefox:libdweb": "cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=nightly --browser-console --url about:debugging", + "firefox:libdweb": "run-s bundle:firefox:libdweb && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=nightly --browser-console --url about:debugging", "ci": "run-s ci:*", "ci:install": "npx yarn@1.7.0 install --frozen-lockfile || npx yarn@1.7.0 install --frozen-lockfile", "ci:test": "npx yarn@1.7.0 test", From a9f2b4d50539e086f15d2bfec5f9bfdd5fc8b382 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Tue, 17 Jul 2018 20:00:14 +0200 Subject: [PATCH 04/31] fix: crashes caused by omitted contentType in protocol handler + cleanup of libdweb scripts --- add-on/src/lib/ipfs-protocol-libdweb.js | 8 ++++---- docs/libdweb.md | 13 ++++++------- libdweb | 2 +- package.json | 7 ++++--- 4 files changed, 15 insertions(+), 15 deletions(-) diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index e9c811c0e..0b183aa7d 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -14,16 +14,16 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { try { return { + // Notes: + // - omitted contentType on purpose to enable mime-sniffing by browser + // // TODO: // - support directory listing // - support streaming - // - either support mime-sniffing of read data in userland, - // or fix crash when contentType is omited (https://github.com/mozilla/libdweb/issues/20) - contentType: 'image/jpeg', content: (async function * () { const data = await ipfs.files.cat(path) const mimeType = mimeSniff(data, path) || 'text/plain' - console.log(`[ipfs-companion] ipfs:// content generator read ${path} and mime-sniffed ${mimeType}`) + console.log(`[ipfs-companion] [ipfs://] content generator read ${path} and internally mime-sniffed ${mimeType}`) yield toArrayBuffer(data) })() } diff --git a/docs/libdweb.md b/docs/libdweb.md index 9659967fe..36ad3e16e 100644 --- a/docs/libdweb.md +++ b/docs/libdweb.md @@ -13,8 +13,7 @@ See also: 1. Having `firefox-nightly` in `$PATH`, execute commands below to build and run Companion extension in libdweb-enabled context: ``` - yarn libdweb-build - yarn firefox:libdweb + yarn libdweb ``` 2. Optional Smoke-Test: @@ -35,12 +34,12 @@ See also: git submodule update --init --checkout --depth 1 libdweb yarn yarn build -yarn bundle:firefox:libdweb +yarn libdweb:bundle ``` or use all-in-one alias: ``` -yarn libdweb-build +yarn libdweb:build ``` @@ -56,15 +55,15 @@ web-ext run --firefox=/path/to/nightly/firefox-bin --browser-console --url about or use alias: ``` -yarn firefox:libdweb +yarn libdweb:firefox ``` Additional notes: -- If you want `firefox:libdweb` to work, ensure `firefox-nightly` is on your `$PATH` +- If you want `libdweb:firefox` to work, ensure `firefox-nightly` is on your `$PATH` - if `firefox-nightly` is missing, create it in unpacked directory via `ln -s firefox firefox-nightly` -- After calling `libdweb-build` it is ok to use `yarn watch` – it will work as expected +- After initially running `libdweb:build` it is ok to use `yarn watch` – it will work as expected ## Appendix: Smoke-Testing libdweb APIs diff --git a/libdweb b/libdweb index c36533ec7..fbff435b3 160000 --- a/libdweb +++ b/libdweb @@ -1 +1 @@ -Subproject commit c36533ec7aa22dfae8cf7ff4e33eafaafb133ed1 +Subproject commit fbff435b33542b02bc35c0bb8c27bc203e6d4e6e diff --git a/package.json b/package.json index 72db93975..d3ea1205f 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,6 @@ "bundle:generic": "shx cp add-on/manifest.common.json add-on/manifest.json && web-ext build -a build/generic", "bundle:firefox": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/", "bundle:firefox:beta": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-beta.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/beta/", - "bundle:firefox:libdweb": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-libdweb.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/libdweb/", "watch": "npm-run-all build:copy --parallel watch:*", "watch:js": "run-p watch:js:*", "watch:js:webpack": "webpack --watch --progress -d --devtool inline-source-map", @@ -43,7 +42,10 @@ "precommit": "run-s lint:standard", "prepush": "run-s clean build lint test", "firefox": "web-ext run --browser-console", - "firefox:libdweb": "run-s bundle:firefox:libdweb && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=nightly --browser-console --url about:debugging", + "libdweb": "run-s libdweb:build libdweb:firefox ", + "libdweb:build": "git submodule update --init --checkout --depth 1 libdweb && npx run-s dev-build libdweb:bundle", + "libdweb:bundle": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-libdweb.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/libdweb/", + "libdweb:firefox": "run-s libdweb:bundle && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=nightly --browser-console --url about:debugging", "ci": "run-s ci:*", "ci:install": "npx yarn@1.7.0 install --frozen-lockfile || npx yarn@1.7.0 install --frozen-lockfile", "ci:test": "npx yarn@1.7.0 test", @@ -51,7 +53,6 @@ "beta-build": "docker build -t ipfs-companion . && docker run -it -e RELEASE_CHANNEL=beta -v $(pwd)/build:/usr/src/app/build ipfs-companion yarn ci:build", "release-build": "docker build -t ipfs-companion . && docker run -it -e RELEASE_CHANNEL=stable -v $(pwd)/build:/usr/src/app/build ipfs-companion yarn ci:build", "dev-build": "npx yarn@1.7.0 && npx yarn@1.7.0 build", - "libdweb-build": "git submodule update --init --checkout --depth 1 libdweb && npx run-s dev-build bundle:firefox:libdweb", "yarn-build": "run-s dev-build" }, "private": true, From 33cf21047b9b2e80e47a9c2ad75fdd337bc44edb Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Tue, 17 Jul 2018 21:24:51 +0200 Subject: [PATCH 05/31] feat: PoC of browser.protocol with directory listing --- add-on/src/lib/ipfs-protocol-libdweb.js | 47 +++++++++++++++++++++---- 1 file changed, 40 insertions(+), 7 deletions(-) diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 0b183aa7d..976db643e 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -1,5 +1,10 @@ -const { mimeSniff } = require('./mime-sniff') +'use strict' +/* eslint-env browser, webextensions */ + +// const { mimeSniff } = require('./mime-sniff') const toArrayBuffer = require('to-arraybuffer') +const dirView = require('./dir-view') +const PathUtils = require('ipfs/src/http/gateway/utils/path') /* protocol handler for mozilla/libdweb */ @@ -18,19 +23,47 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { // - omitted contentType on purpose to enable mime-sniffing by browser // // TODO: - // - support directory listing + // - detect invalid addrs and display error page // - support streaming content: (async function * () { - const data = await ipfs.files.cat(path) - const mimeType = mimeSniff(data, path) || 'text/plain' - console.log(`[ipfs-companion] [ipfs://] content generator read ${path} and internally mime-sniffed ${mimeType}`) - yield toArrayBuffer(data) + const data = await getIpfsData(ipfs, path) + // uncomment below for additional mime-sniffing in userland + // const mimeType = mimeSniff(data, path) || 'text/plain' + // console.log(`[ipfs-companion] [ipfs://] content generator read ${path} and internally mime-sniffed ${mimeType}`) + // + yield data })() } } catch (err) { - console.error('[ipfs-companion] failed to get data', err) + console.error('[ipfs-companion] failed to get data for ' + request.url, err) } console.timeEnd('[ipfs-companion] IpfsUrlProtocolHandler') } } + +async function getIpfsData (ipfs, path) { + let data + try { + data = await ipfs.files.cat(path) + } catch (err) { + if (err.message.toLowerCase() === 'this dag node is a directory') { + return getDirectoryListingOrIndexData(ipfs, path) + } + throw err + } + return toArrayBuffer(data) +} + +async function getDirectoryListingOrIndexData (ipfs, path) { + const listing = await ipfs.ls(path) + const index = listing.find((l) => ['index', 'index.html', 'index.htm'].includes(l.name)) + + if (index) { + return getIpfsData(ipfs, PathUtils.joinURLParts(path, index.name)) + } + + const response = dirView.render(path.replace(/^\/ipfs\//, 'ipfs://'), listing) + const encoder = new TextEncoder('utf-8') + return encoder.encode(response).buffer +} From 101966ea798c3fbc9449106175bd2afadda1778f Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 20 Jul 2018 19:13:13 +0200 Subject: [PATCH 06/31] feat: streaming in ipfs:// - port directory detection from streaming branch in Muon-Brave - detect streaming responses and return them as async iterator - trivia: switch from uglify-es to terser to support for-await --- .babelrc | 6 +- add-on/manifest.firefox.json | 2 +- add-on/src/lib/ipfs-companion.js | 1 - add-on/src/lib/ipfs-protocol-libdweb.js | 112 +- package.json | 15 +- webpack.config.js | 1 + yarn.lock | 1243 +++++++++++------------ 7 files changed, 683 insertions(+), 697 deletions(-) diff --git a/.babelrc b/.babelrc index 1a9b2db00..4427cd7be 100644 --- a/.babelrc +++ b/.babelrc @@ -7,10 +7,8 @@ "env", { "targets": { - "browsers": [ - "firefox >= 59", - "chrome >= 67" - ] + "firefox": 61, + "chrome": 67 } } ] diff --git a/add-on/manifest.firefox.json b/add-on/manifest.firefox.json index e053be1af..68641ef23 100644 --- a/add-on/manifest.firefox.json +++ b/add-on/manifest.firefox.json @@ -8,7 +8,7 @@ "applications": { "gecko": { "id": "ipfs-firefox-addon@lidel.org", - "strict_min_version": "59.0" + "strict_min_version": "63" } }, "page_action": { diff --git a/add-on/src/lib/ipfs-companion.js b/add-on/src/lib/ipfs-companion.js index 612e8fc18..ae1c0ac5a 100644 --- a/add-on/src/lib/ipfs-companion.js +++ b/add-on/src/lib/ipfs-companion.js @@ -110,7 +110,6 @@ module.exports = async function init () { } else { console.log('[ipfs-companion] browser.protocol.registerStringProtocol not available, native protocol will not be registered') } - console.log(`[ipfs-companion] registerProtocol: ${browser.protocol.registerProtocol}`, browser.protocol.registerProtocol) } // Register Content Script responsible for loading window.ipfs (ipfsProxy) diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 976db643e..97ec7e60c 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -1,10 +1,14 @@ 'use strict' /* eslint-env browser, webextensions */ -// const { mimeSniff } = require('./mime-sniff') +import {asyncIterateStream} from 'async-iterate-stream/asyncIterateStream' + +const { mimeSniff } = require('./mime-sniff') const toArrayBuffer = require('to-arraybuffer') +const peek = require('buffer-peek-stream') const dirView = require('./dir-view') const PathUtils = require('ipfs/src/http/gateway/utils/path') +const isStream = require('is-stream') /* protocol handler for mozilla/libdweb */ @@ -25,14 +29,7 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { // TODO: // - detect invalid addrs and display error page // - support streaming - content: (async function * () { - const data = await getIpfsData(ipfs, path) - // uncomment below for additional mime-sniffing in userland - // const mimeType = mimeSniff(data, path) || 'text/plain' - // console.log(`[ipfs-companion] [ipfs://] content generator read ${path} and internally mime-sniffed ${mimeType}`) - // - yield data - })() + content: streamRespond(ipfs, path) } } catch (err) { console.error('[ipfs-companion] failed to get data for ' + request.url, err) @@ -42,28 +39,99 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { } } -async function getIpfsData (ipfs, path) { - let data +async function * streamRespond (ipfs, path) { + const response = await getResponse(ipfs, path) + if (isStream(response)) { + for await (const chunk of asyncIterateStream(response, false)) { + // for await (const chunk of new S2A(response)) { + // Buffer to ArrayBuffer + yield toArrayBuffer(chunk) + } + } else { + // just a buffer + yield response + } +} + +/* +function toAsyncIterator(stream) { + // console.log('toAsyncIterator.stream', stream) + //const s2a = new S2A(stream) + const s2a = asyncIterateStream(stream, false) + // console.log('toAsyncIterator.s2a', s2a) + return s2a +} +*/ + +async function getResponse (ipfs, path) { + let listing + + // We're using ipfs.ls to figure out if a path is a file or a directory. + // + // If the listing is empty then it's (likely) a file + // If the listing has 1 entry then it's a directory + // If the listing has > 1 entry && all the paths are the same then directory + // else file + // + // It's not pretty, but the alternative is to use the object or dag API's + // and inspect the data returned by them to see if it's a file or dir. + // + // Right now we can't use either of these because: + // 1. js-ipfs object API does not take paths (only cid) + // 2. js-ipfs-api does not support dag API at all + // + // The second alternative would be to resolve the path ourselves using the + // object API, but that could take a while for long paths. try { - data = await ipfs.files.cat(path) + listing = await ipfs.ls(path) } catch (err) { - if (err.message.toLowerCase() === 'this dag node is a directory') { - return getDirectoryListingOrIndexData(ipfs, path) + if (err.message === 'file does not exist') { + // eg. when trying to access a non-existing file in a directory + return new TextEncoder('utf-8').encode('Not found').buffer } throw err } - return toArrayBuffer(data) + + if (isDirectory(listing)) { + return getDirectoryListingOrIndexResponse(ipfs, path, listing) + } + + // Efficient mime-sniff over initial bytes + // TODO: rignt now it is only logged, use contentType somehow + const { stream, contentType } = await new Promise((resolve, reject) => { + peek(ipfs.files.catReadableStream(path), 512, (err, data, stream) => { + if (err) return reject(err) + const contentType = mimeSniff(data, path) || 'text/plain' + resolve({ stream, contentType }) + }) + }) + console.log(`[ipfs-companion] [ipfs://] handler read ${path} and internally mime-sniffed it as ${contentType}`) + // + return stream } -async function getDirectoryListingOrIndexData (ipfs, path) { - const listing = await ipfs.ls(path) - const index = listing.find((l) => ['index', 'index.html', 'index.htm'].includes(l.name)) +function isDirectory (listing) { + if (!listing.length) return false + if (listing.length === 1) return true + // If every path in the listing is the same, IPFS has listed blocks for a file + // if not then it is a directory listing. + const path = listing[0].path + return !listing.every(f => f.path === path) +} + +function getDirectoryListingOrIndexResponse (ipfs, path, listing) { + const indexFileNames = ['index', 'index.html', 'index.htm'] + const index = listing.find((l) => indexFileNames.includes(l.name)) if (index) { - return getIpfsData(ipfs, PathUtils.joinURLParts(path, index.name)) + /* TODO: pass mime-type to libdweb somehow? + let contentType = 'text/plain' + if (index.name.endsWith('.html') || index.name.endsWith('.htm')) { + contentType = 'text/html' + } + */ + return ipfs.files.catReadableStream(PathUtils.joinURLParts(path, index.name)) } - const response = dirView.render(path.replace(/^\/ipfs\//, 'ipfs://'), listing) - const encoder = new TextEncoder('utf-8') - return encoder.encode(response).buffer + return new TextEncoder('utf-8').encode(response).buffer } diff --git a/package.json b/package.json index d3ea1205f..cec49ae29 100644 --- a/package.json +++ b/package.json @@ -43,7 +43,7 @@ "prepush": "run-s clean build lint test", "firefox": "web-ext run --browser-console", "libdweb": "run-s libdweb:build libdweb:firefox ", - "libdweb:build": "git submodule update --init --checkout --depth 1 libdweb && npx run-s dev-build libdweb:bundle", + "libdweb:build": "git submodule update --init --checkout --depth 1 libdweb && npm run dev-build && npm run libdweb:bundle", "libdweb:bundle": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-libdweb.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/libdweb/", "libdweb:firefox": "run-s libdweb:bundle && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=nightly --browser-console --url about:debugging", "ci": "run-s ci:*", @@ -60,10 +60,13 @@ "standard": { "parser": "babel-eslint" }, + "resolutions": { + "uglify-es": "npm:terser" + }, "devDependencies": { "babel-core": "6.26.3", "babel-eslint": "8.2.6", - "babel-loader": "7.1.4", + "babel-loader": "7.1.5", "babel-plugin-syntax-async-generators": "6.13.0", "babel-preset-env": "1.7.0", "chai": "4.1.2", @@ -84,14 +87,17 @@ "sinon": "6.1.0", "sinon-chrome": "2.3.2", "standard": "10.0.3", + "terser": "3.8.0", "transform-loader": "0.2.4", "web-ext": "2.7.0", - "webpack": "4.14.0", + "webpack": "4.16.1", "webpack-bundle-analyzer": "2.13.1", - "webpack-cli": "3.0.8", + "webpack-cli": "3.1.0", "webpack-merge": "4.1.3" }, "dependencies": { + "async-iterate-stream": "1.0.3", + "buffer-peek-stream": "1.0.1", "choo": "6.12.1", "doc-sniff": "1.0.1", "file-type": "8.0.0", @@ -103,6 +109,7 @@ "ipfs-http-response": "0.1.2", "ipfs-postmsg-proxy": "3.0.0", "is-ipfs": "0.3.2", + "is-stream": "1.1.0", "is-svg": "3.0.0", "lru_map": "0.3.3", "mime-types": "2.1.18", diff --git a/webpack.config.js b/webpack.config.js index b7a58ed2e..aa20f6327 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -14,6 +14,7 @@ const commonConfig = { publicPath: '/dist/bundles/', filename: '[name].bundle.js' }, + devtool: 'source-map', optimization: { minimizer: [ // Default flags break js-ipfs: https://github.com/ipfs-shipyard/ipfs-companion/issues/521 diff --git a/yarn.lock b/yarn.lock index dbf3362da..c796929e2 100644 --- a/yarn.lock +++ b/yarn.lock @@ -185,143 +185,143 @@ samsam "1.3.0" "@types/node@*": - version "10.3.0" - resolved "https://registry.yarnpkg.com/@types/node/-/node-10.3.0.tgz#078516315a84d56216b5d4fed8f75d59d3b16cac" + version "10.5.2" + resolved "https://registry.yarnpkg.com/@types/node/-/node-10.5.2.tgz#f19f05314d5421fe37e74153254201a7bf00a707" -"@webassemblyjs/ast@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/ast/-/ast-1.5.12.tgz#a9acbcb3f25333c4edfa1fdf3186b1ccf64e6664" +"@webassemblyjs/ast@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/ast/-/ast-1.5.13.tgz#81155a570bd5803a30ec31436bc2c9c0ede38f25" dependencies: - "@webassemblyjs/helper-module-context" "1.5.12" - "@webassemblyjs/helper-wasm-bytecode" "1.5.12" - "@webassemblyjs/wast-parser" "1.5.12" + "@webassemblyjs/helper-module-context" "1.5.13" + "@webassemblyjs/helper-wasm-bytecode" "1.5.13" + "@webassemblyjs/wast-parser" "1.5.13" debug "^3.1.0" mamacro "^0.0.3" -"@webassemblyjs/floating-point-hex-parser@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.5.12.tgz#0f36044ffe9652468ce7ae5a08716a4eeff9cd9c" +"@webassemblyjs/floating-point-hex-parser@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.5.13.tgz#29ce0baa97411f70e8cce68ce9c0f9d819a4e298" -"@webassemblyjs/helper-api-error@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-api-error/-/helper-api-error-1.5.12.tgz#05466833ff2f9d8953a1a327746e1d112ea62aaf" +"@webassemblyjs/helper-api-error@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-api-error/-/helper-api-error-1.5.13.tgz#e49b051d67ee19a56e29b9aa8bd949b5b4442a59" -"@webassemblyjs/helper-buffer@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-buffer/-/helper-buffer-1.5.12.tgz#1f0de5aaabefef89aec314f7f970009cd159c73d" +"@webassemblyjs/helper-buffer@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-buffer/-/helper-buffer-1.5.13.tgz#873bb0a1b46449231137c1262ddfd05695195a1e" dependencies: debug "^3.1.0" -"@webassemblyjs/helper-code-frame@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-code-frame/-/helper-code-frame-1.5.12.tgz#3cdc1953093760d1c0f0caf745ccd62bdb6627c7" +"@webassemblyjs/helper-code-frame@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-code-frame/-/helper-code-frame-1.5.13.tgz#1bd2181b6a0be14e004f0fe9f5a660d265362b58" dependencies: - "@webassemblyjs/wast-printer" "1.5.12" + "@webassemblyjs/wast-printer" "1.5.13" -"@webassemblyjs/helper-fsm@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-fsm/-/helper-fsm-1.5.12.tgz#6bc1442b037f8e30f2e57b987cee5c806dd15027" +"@webassemblyjs/helper-fsm@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-fsm/-/helper-fsm-1.5.13.tgz#cdf3d9d33005d543a5c5e5adaabf679ffa8db924" -"@webassemblyjs/helper-module-context@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-module-context/-/helper-module-context-1.5.12.tgz#b5588ca78b33b8a0da75f9ab8c769a3707baa861" +"@webassemblyjs/helper-module-context@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-module-context/-/helper-module-context-1.5.13.tgz#dc29ddfb51ed657655286f94a5d72d8a489147c5" dependencies: debug "^3.1.0" mamacro "^0.0.3" -"@webassemblyjs/helper-wasm-bytecode@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.5.12.tgz#d12a3859db882a448891a866a05d0be63785b616" +"@webassemblyjs/helper-wasm-bytecode@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.5.13.tgz#03245817f0a762382e61733146f5773def15a747" -"@webassemblyjs/helper-wasm-section@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.5.12.tgz#ff9fe1507d368ad437e7969d25e8c1693dac1884" +"@webassemblyjs/helper-wasm-section@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.5.13.tgz#efc76f44a10d3073b584b43c38a179df173d5c7d" dependencies: - "@webassemblyjs/ast" "1.5.12" - "@webassemblyjs/helper-buffer" "1.5.12" - "@webassemblyjs/helper-wasm-bytecode" "1.5.12" - "@webassemblyjs/wasm-gen" "1.5.12" + "@webassemblyjs/ast" "1.5.13" + "@webassemblyjs/helper-buffer" "1.5.13" + "@webassemblyjs/helper-wasm-bytecode" "1.5.13" + "@webassemblyjs/wasm-gen" "1.5.13" debug "^3.1.0" -"@webassemblyjs/ieee754@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/ieee754/-/ieee754-1.5.12.tgz#ee9574bc558888f13097ce3e7900dff234ea19a4" +"@webassemblyjs/ieee754@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/ieee754/-/ieee754-1.5.13.tgz#573e97c8c12e4eebb316ca5fde0203ddd90b0364" dependencies: ieee754 "^1.1.11" -"@webassemblyjs/leb128@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/leb128/-/leb128-1.5.12.tgz#0308eec652765ee567d8a5fa108b4f0b25b458e1" +"@webassemblyjs/leb128@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/leb128/-/leb128-1.5.13.tgz#ab52ebab9cec283c1c1897ac1da833a04a3f4cee" dependencies: - leb "^0.3.0" + long "4.0.0" -"@webassemblyjs/utf8@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/utf8/-/utf8-1.5.12.tgz#d5916222ef314bf60d6806ed5ac045989bfd92ce" +"@webassemblyjs/utf8@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/utf8/-/utf8-1.5.13.tgz#6b53d2cd861cf94fa99c1f12779dde692fbc2469" -"@webassemblyjs/wasm-edit@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-edit/-/wasm-edit-1.5.12.tgz#821c9358e644a166f2c910e5af1b46ce795a17aa" +"@webassemblyjs/wasm-edit@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-edit/-/wasm-edit-1.5.13.tgz#c9cef5664c245cf11b3b3a73110c9155831724a8" dependencies: - "@webassemblyjs/ast" "1.5.12" - "@webassemblyjs/helper-buffer" "1.5.12" - "@webassemblyjs/helper-wasm-bytecode" "1.5.12" - "@webassemblyjs/helper-wasm-section" "1.5.12" - "@webassemblyjs/wasm-gen" "1.5.12" - "@webassemblyjs/wasm-opt" "1.5.12" - "@webassemblyjs/wasm-parser" "1.5.12" - "@webassemblyjs/wast-printer" "1.5.12" + "@webassemblyjs/ast" "1.5.13" + "@webassemblyjs/helper-buffer" "1.5.13" + "@webassemblyjs/helper-wasm-bytecode" "1.5.13" + "@webassemblyjs/helper-wasm-section" "1.5.13" + "@webassemblyjs/wasm-gen" "1.5.13" + "@webassemblyjs/wasm-opt" "1.5.13" + "@webassemblyjs/wasm-parser" "1.5.13" + "@webassemblyjs/wast-printer" "1.5.13" debug "^3.1.0" -"@webassemblyjs/wasm-gen@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-gen/-/wasm-gen-1.5.12.tgz#0b7ccfdb93dab902cc0251014e2e18bae3139bcb" +"@webassemblyjs/wasm-gen@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-gen/-/wasm-gen-1.5.13.tgz#8e6ea113c4b432fa66540189e79b16d7a140700e" dependencies: - "@webassemblyjs/ast" "1.5.12" - "@webassemblyjs/helper-wasm-bytecode" "1.5.12" - "@webassemblyjs/ieee754" "1.5.12" - "@webassemblyjs/leb128" "1.5.12" - "@webassemblyjs/utf8" "1.5.12" + "@webassemblyjs/ast" "1.5.13" + "@webassemblyjs/helper-wasm-bytecode" "1.5.13" + "@webassemblyjs/ieee754" "1.5.13" + "@webassemblyjs/leb128" "1.5.13" + "@webassemblyjs/utf8" "1.5.13" -"@webassemblyjs/wasm-opt@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-opt/-/wasm-opt-1.5.12.tgz#bd758a8bc670f585ff1ae85f84095a9e0229cbc9" +"@webassemblyjs/wasm-opt@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-opt/-/wasm-opt-1.5.13.tgz#147aad7717a7ee4211c36b21a5f4c30dddf33138" dependencies: - "@webassemblyjs/ast" "1.5.12" - "@webassemblyjs/helper-buffer" "1.5.12" - "@webassemblyjs/wasm-gen" "1.5.12" - "@webassemblyjs/wasm-parser" "1.5.12" + "@webassemblyjs/ast" "1.5.13" + "@webassemblyjs/helper-buffer" "1.5.13" + "@webassemblyjs/wasm-gen" "1.5.13" + "@webassemblyjs/wasm-parser" "1.5.13" debug "^3.1.0" -"@webassemblyjs/wasm-parser@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-parser/-/wasm-parser-1.5.12.tgz#7b10b4388ecf98bd7a22e702aa62ec2f46d0c75e" - dependencies: - "@webassemblyjs/ast" "1.5.12" - "@webassemblyjs/helper-api-error" "1.5.12" - "@webassemblyjs/helper-wasm-bytecode" "1.5.12" - "@webassemblyjs/ieee754" "1.5.12" - "@webassemblyjs/leb128" "1.5.12" - "@webassemblyjs/utf8" "1.5.12" - -"@webassemblyjs/wast-parser@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wast-parser/-/wast-parser-1.5.12.tgz#9cf5ae600ecae0640437b5d4de5dd6b6088d0d8b" - dependencies: - "@webassemblyjs/ast" "1.5.12" - "@webassemblyjs/floating-point-hex-parser" "1.5.12" - "@webassemblyjs/helper-api-error" "1.5.12" - "@webassemblyjs/helper-code-frame" "1.5.12" - "@webassemblyjs/helper-fsm" "1.5.12" +"@webassemblyjs/wasm-parser@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-parser/-/wasm-parser-1.5.13.tgz#6f46516c5bb23904fbdf58009233c2dd8a54c72f" + dependencies: + "@webassemblyjs/ast" "1.5.13" + "@webassemblyjs/helper-api-error" "1.5.13" + "@webassemblyjs/helper-wasm-bytecode" "1.5.13" + "@webassemblyjs/ieee754" "1.5.13" + "@webassemblyjs/leb128" "1.5.13" + "@webassemblyjs/utf8" "1.5.13" + +"@webassemblyjs/wast-parser@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wast-parser/-/wast-parser-1.5.13.tgz#5727a705d397ae6a3ae99d7f5460acf2ec646eea" + dependencies: + "@webassemblyjs/ast" "1.5.13" + "@webassemblyjs/floating-point-hex-parser" "1.5.13" + "@webassemblyjs/helper-api-error" "1.5.13" + "@webassemblyjs/helper-code-frame" "1.5.13" + "@webassemblyjs/helper-fsm" "1.5.13" long "^3.2.0" mamacro "^0.0.3" -"@webassemblyjs/wast-printer@1.5.12": - version "1.5.12" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wast-printer/-/wast-printer-1.5.12.tgz#563ca4d01b22d21640b2463dc5e3d7f7d9dac520" +"@webassemblyjs/wast-printer@1.5.13": + version "1.5.13" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wast-printer/-/wast-printer-1.5.13.tgz#bb34d528c14b4f579e7ec11e793ec50ad7cd7c95" dependencies: - "@webassemblyjs/ast" "1.5.12" - "@webassemblyjs/wast-parser" "1.5.12" + "@webassemblyjs/ast" "1.5.13" + "@webassemblyjs/wast-parser" "1.5.13" long "^3.2.0" "File@>= 0.10.0", File@^0.10.2: @@ -399,31 +399,20 @@ acorn-jsx@^3.0.0: acorn "^3.0.4" acorn-node@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/acorn-node/-/acorn-node-1.3.0.tgz#5f86d73346743810ef1269b901dbcbded020861b" + version "1.5.2" + resolved "https://registry.yarnpkg.com/acorn-node/-/acorn-node-1.5.2.tgz#2ca723df19d997b05824b69f6c7fb091fc42c322" dependencies: - acorn "^5.4.1" + acorn "^5.7.1" + acorn-dynamic-import "^3.0.0" xtend "^4.0.1" acorn@^3.0.4: version "3.3.0" resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" -acorn@^5.0.0, acorn@^5.4.1: - version "5.4.1" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.4.1.tgz#fdc58d9d17f4a4e98d102ded826a9b9759125102" - -acorn@^5.2.1: - version "5.3.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.3.0.tgz#7446d39459c54fb49a80e6ee6478149b940ec822" - -acorn@^5.3.0, acorn@^5.6.2: - version "5.6.2" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.6.2.tgz#b1da1d7be2ac1b4a327fb9eab851702c5045b4e7" - -acorn@^5.5.0: - version "5.5.3" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.5.3.tgz#f473dd47e0277a08e28e9bec5aeeb04751f0b8c9" +acorn@^5.0.0, acorn@^5.2.1, acorn@^5.3.0, acorn@^5.5.0, acorn@^5.6.2, acorn@^5.7.1: + version "5.7.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.1.tgz#f095829297706a7c9776958c0afc8930a9b9d9d8" adbkit-logcat@^1.1.0: version "1.1.0" @@ -498,8 +487,8 @@ after@0.8.2: resolved "https://registry.yarnpkg.com/after/-/after-0.8.2.tgz#fedb394f9f0e02aa9768e702bda23b505fae7e1f" agent-base@4, agent-base@^4.1.0, agent-base@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-4.2.0.tgz#9838b5c3392b962bad031e6a4c5e1024abec45ce" + version "4.2.1" + resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-4.2.1.tgz#d89e5999f797875674c07d87f260fc41e83e8ca9" dependencies: es6-promisify "^5.0.0" @@ -522,7 +511,7 @@ ajv-merge-patch@3.0.0: fast-json-patch "^1.0.0" json-merge-patch "^0.2.3" -ajv@6.5.0, ajv@^6.1.0: +ajv@6.5.0: version "6.5.0" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.5.0.tgz#4c8affdf80887d8f132c9c52ab8a2dc4d0b7b24c" dependencies: @@ -547,6 +536,15 @@ ajv@^5.1.0, ajv@^5.2.3, ajv@^5.3.0: fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.3.0" +ajv@^6.1.0: + version "6.5.2" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.5.2.tgz#678495f9b82f7cca6be248dd92f59bff5e1f4360" + dependencies: + fast-deep-equal "^2.0.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.1" + align-text@^0.1.1, align-text@^0.1.3: version "0.1.4" resolved "https://registry.yarnpkg.com/align-text/-/align-text-0.1.4.tgz#0cd90a561093f35d0a99256c22b7069433fad117" @@ -794,10 +792,48 @@ async-each@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.1.tgz#19d386a1d9edc6e7c1c85d388aedbcc56d33602d" +async-iterate-stream@1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/async-iterate-stream/-/async-iterate-stream-1.0.3.tgz#a1c752c0ed724ed30d53bf9fa72e3b3cbe7ce083" + dependencies: + async.forever "^0.5.2" + core-js "^2.5.1" + async-limiter@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/async-limiter/-/async-limiter-1.0.0.tgz#78faed8c3d074ab81f22b4e985d79e8738f720f8" +async.forever@^0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/async.forever/-/async.forever-0.5.2.tgz#a6f79dbf583787bdba5cbf23c75b55c9d97faaea" + dependencies: + async.util.ensureasync "0.5.2" + async.util.noop "0.5.2" + async.util.onlyonce "0.5.2" + +async.util.ensureasync@0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/async.util.ensureasync/-/async.util.ensureasync-0.5.2.tgz#10907f2cbd067a061f99ae6d22e08ced30db0d68" + dependencies: + async.util.restparam "0.5.2" + async.util.setimmediate "0.5.2" + +async.util.noop@0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/async.util.noop/-/async.util.noop-0.5.2.tgz#bdd62b97cb0aa3f60b586ad148468698975e58b9" + +async.util.onlyonce@0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/async.util.onlyonce/-/async.util.onlyonce-0.5.2.tgz#b8e6fc004adc923164d79e32f2813ee465c24ff2" + +async.util.restparam@0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/async.util.restparam/-/async.util.restparam-0.5.2.tgz#03efebf3c0277b97220e525aba750f5e04fc80cd" + +async.util.setimmediate@0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/async.util.setimmediate/-/async.util.setimmediate-0.5.2.tgz#2812ebabf2a58027758d4bc7793d1ccfaf10255f" + async@^1.4.0, async@^1.4.2, async@^1.5.2, async@~1.5: version "1.5.2" resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" @@ -995,9 +1031,9 @@ babel-helpers@^6.24.1: babel-runtime "^6.22.0" babel-template "^6.24.1" -babel-loader@7.1.4: - version "7.1.4" - resolved "https://registry.yarnpkg.com/babel-loader/-/babel-loader-7.1.4.tgz#e3463938bd4e6d55d1c174c5485d406a188ed015" +babel-loader@7.1.5: + version "7.1.5" + resolved "https://registry.yarnpkg.com/babel-loader/-/babel-loader-7.1.5.tgz#e3ee0cd7394aa557e013b02d3e492bfd07aa6d68" dependencies: find-cache-dir "^1.0.0" loader-utils "^1.0.2" @@ -1357,7 +1393,7 @@ base-x@3.0.4, base-x@^3.0.2: dependencies: safe-buffer "^5.0.1" -base32.js@^0.1.0, base32.js@~0.1.0: +base32.js@~0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/base32.js/-/base32.js-0.1.0.tgz#b582dec693c2f11e893cf064ee6ac5b6131a2202" @@ -1390,8 +1426,8 @@ base@^0.11.1: pascalcase "^0.1.1" bcrypt-pbkdf@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.1.tgz#63bc5dcb61331b92bc05fd528953c33462a06f8d" + version "1.0.2" + resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" dependencies: tweetnacl "^0.14.3" @@ -1417,11 +1453,7 @@ big.js@^3.1.3: version "3.2.0" resolved "https://registry.yarnpkg.com/big.js/-/big.js-3.2.0.tgz#a5fc298b81b9e0dca2e458824784b65c52ba588e" -big.js@^5.0.3: - version "5.0.3" - resolved "https://registry.yarnpkg.com/big.js/-/big.js-5.0.3.tgz#9679fb0a3599a7d3df397f855e89c4dba016960e" - -big.js@^5.1.2: +big.js@^5.0.3, big.js@^5.1.2: version "5.1.2" resolved "https://registry.yarnpkg.com/big.js/-/big.js-5.1.2.tgz#946c634f3efd9c8dcd98f953e96a5f389dac3fec" @@ -1501,12 +1533,6 @@ blob@0.0.4, blob@~0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/blob/-/blob-0.0.4.tgz#bcf13052ca54463f30f9fc7e95b9a47630a94921" -block-stream@*: - version "0.0.9" - resolved "https://registry.yarnpkg.com/block-stream/-/block-stream-0.0.9.tgz#13ebfe778a03205cfe03751481ebb4b3300c126a" - dependencies: - inherits "~2.0.0" - bluebird@^3.5.1: version "3.5.1" resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.5.1.tgz#d9551f9de98f1fcda1e683d17ee91a0602ee2eb9" @@ -1658,12 +1684,13 @@ browserify-cipher@^1.0.0: evp_bytestokey "^1.0.0" browserify-des@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/browserify-des/-/browserify-des-1.0.1.tgz#3343124db6d7ad53e26a8826318712bdc8450f9c" + version "1.0.2" + resolved "https://registry.yarnpkg.com/browserify-des/-/browserify-des-1.0.2.tgz#3af4f1f59839403572f1c66204375f7a7f703e9c" dependencies: cipher-base "^1.0.1" des.js "^1.0.0" inherits "^2.0.1" + safe-buffer "^5.1.2" browserify-rsa@^4.0.0: version "4.0.1" @@ -1753,6 +1780,10 @@ buffer-loader@~0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/buffer-loader/-/buffer-loader-0.0.1.tgz#4d677ca92dd889310878b02a2fbcfab712024cf2" +buffer-peek-stream@1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/buffer-peek-stream/-/buffer-peek-stream-1.0.1.tgz#53b47570a1347787c5bad4ca2ca3021f9d8b3cfd" + buffer-split@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/buffer-split/-/buffer-split-1.0.0.tgz#4427dbff53731b61d7a71aba47f503396613784a" @@ -1771,6 +1802,13 @@ buffer@^4.3.0: ieee754 "^1.1.4" isarray "^1.0.0" +buffer@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.1.0.tgz#c913e43678c7cb7c8bd16afbcddb6c5505e8f9fe" + dependencies: + base64-js "^1.0.2" + ieee754 "^1.1.4" + "bufferjs@> 0.2.0": version "3.0.1" resolved "https://registry.yarnpkg.com/bufferjs/-/bufferjs-3.0.1.tgz#0692e829cb10a10550e647390b035eb06c38e8ef" @@ -1893,8 +1931,8 @@ camelcase@^3.0.0: resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" caniuse-lite@^1.0.30000844: - version "1.0.30000851" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000851.tgz#3b498aebf9f92cf6cff4ab54d13b557c0b590533" + version "1.0.30000865" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000865.tgz#70026616e8afe6e1442f8bb4e1092987d81a2f25" capture-stack-trace@^1.0.0: version "1.0.0" @@ -1940,7 +1978,7 @@ chai@4.1.2: pathval "^1.0.0" type-detect "^4.0.0" -chalk@2.3.x, chalk@^2.3.1, chalk@^2.3.2: +chalk@2.3.x: version "2.3.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.2.tgz#250dc96b07491bfd601e648d66ddf5f60c7a5c65" dependencies: @@ -1966,15 +2004,7 @@ chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" -chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0: - version "2.3.1" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.1.tgz#523fe2678aec7b04e8041909292fe8b17059b796" - dependencies: - ansi-styles "^3.2.0" - escape-string-regexp "^1.0.5" - supports-color "^5.2.0" - -chalk@^2.3.0, chalk@^2.4.1: +chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.0, chalk@^2.3.1, chalk@^2.3.2, chalk@^2.4.1: version "2.4.1" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e" dependencies: @@ -2034,8 +2064,8 @@ cheerio@1.0.0-rc.2: parse5 "^3.0.1" chokidar@^2.0.2: - version "2.0.3" - resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.0.3.tgz#dcbd4f6cbb2a55b4799ba8a840ac527e5f4b1176" + version "2.0.4" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.0.4.tgz#356ff4e2b0e8e43e322d18a372460bbcf3accd26" dependencies: anymatch "^2.0.0" async-each "^1.0.0" @@ -2044,12 +2074,13 @@ chokidar@^2.0.2: inherits "^2.0.1" is-binary-path "^1.0.0" is-glob "^4.0.0" + lodash.debounce "^4.0.8" normalize-path "^2.1.1" path-is-absolute "^1.0.0" readdirp "^2.0.0" - upath "^1.0.0" + upath "^1.0.5" optionalDependencies: - fsevents "^1.1.2" + fsevents "^1.2.2" choo@6.12.1: version "6.12.1" @@ -2198,14 +2229,14 @@ collection-visit@^1.0.0: object-visit "^1.0.0" color-convert@^1.9.0: - version "1.9.1" - resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.1.tgz#c1261107aeb2f294ebffec9ed9ecad529a6097ed" + version "1.9.2" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.2.tgz#49881b8fba67df12a96bdf3f56c0aab9e7913147" dependencies: - color-name "^1.1.1" + color-name "1.1.1" -color-name@^1.1.1: - version "1.1.3" - resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" +color-name@1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.1.tgz#4b1415304cf50028ea81643643bd82ea05803689" colors@0.5.x: version "0.5.1" @@ -2224,7 +2255,7 @@ combined-stream@1.0.6, combined-stream@~1.0.5: dependencies: delayed-stream "~1.0.0" -commander@2.15.1, commander@^2.11.0, commander@^2.13.0, commander@^2.15.0, commander@^2.3.0, commander@^2.6.0: +commander@2.15.1: version "2.15.1" resolved "https://registry.yarnpkg.com/commander/-/commander-2.15.1.tgz#df46e867d0fc2aec66a34662b406a9ccafff5b0f" @@ -2234,9 +2265,9 @@ commander@2.9.0: dependencies: graceful-readlink ">= 1.0.0" -commander@~2.13.0: - version "2.13.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.13.0.tgz#6964bca67685df7c1f1430c584f07d7597885b9c" +commander@^2.11.0, commander@^2.13.0, commander@^2.15.0, commander@^2.3.0, commander@^2.6.0, commander@~2.16.0: + version "2.16.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.16.0.tgz#f16390593996ceb4f3eeb020b31d78528f7f8a50" common-tags@1.7.2: version "1.7.2" @@ -2273,15 +2304,7 @@ concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" -concat-stream@^1.4.7, concat-stream@^1.5.2, concat-stream@^1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.0.tgz#0aac662fd52be78964d5532f694784e70110acf7" - dependencies: - inherits "^2.0.3" - readable-stream "^2.2.2" - typedarray "^0.0.6" - -concat-stream@^1.5.0, concat-stream@^1.6.2: +concat-stream@^1.4.7, concat-stream@^1.5.0, concat-stream@^1.5.2, concat-stream@^1.6.0, concat-stream@^1.6.2: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" dependencies: @@ -2290,18 +2313,7 @@ concat-stream@^1.5.0, concat-stream@^1.6.2: readable-stream "^2.2.2" typedarray "^0.0.6" -configstore@^3.0.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/configstore/-/configstore-3.1.1.tgz#094ee662ab83fad9917678de114faaea8fcdca90" - dependencies: - dot-prop "^4.1.0" - graceful-fs "^4.1.2" - make-dir "^1.0.0" - unique-string "^1.0.0" - write-file-atomic "^2.0.0" - xdg-basedir "^3.0.0" - -configstore@^3.1.2: +configstore@^3.0.0, configstore@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/configstore/-/configstore-3.1.2.tgz#c6f25defaeef26df12dd33414b001fe81a543f8f" dependencies: @@ -2371,7 +2383,7 @@ copy-descriptor@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" -core-js@^2.4.0, core-js@^2.5.0: +core-js@^2.4.0, core-js@^2.5.0, core-js@^2.5.1: version "2.5.7" resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.7.tgz#f972608ff0cead68b841a16a932d0b183791814e" @@ -2387,8 +2399,10 @@ crc32-stream@^2.0.0: readable-stream "^2.0.0" crc@^3.4.4: - version "3.5.0" - resolved "https://registry.yarnpkg.com/crc/-/crc-3.5.0.tgz#98b8ba7d489665ba3979f59b21381374101a1964" + version "3.7.0" + resolved "https://registry.yarnpkg.com/crc/-/crc-3.7.0.tgz#58b7083e32ba4b276e1f4cbce1a78b39a6ab63f9" + dependencies: + buffer "^5.1.0" create-ecdh@^4.0.0: version "4.0.3" @@ -2705,8 +2719,8 @@ degenerator@^1.0.4: esprima "3.x.x" deglob@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/deglob/-/deglob-2.1.0.tgz#4d44abe16ef32c779b4972bd141a80325029a14a" + version "2.1.1" + resolved "https://registry.yarnpkg.com/deglob/-/deglob-2.1.1.tgz#d268e168727799862e8eac07042e165957c1f3be" dependencies: find-root "^1.0.0" glob "^7.0.5" @@ -2964,8 +2978,8 @@ ejs@^2.5.7: resolved "https://registry.yarnpkg.com/ejs/-/ejs-2.6.1.tgz#498ec0d495655abc6f23cd61868d926464071aa0" electron-to-chromium@^1.3.47: - version "1.3.48" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.48.tgz#d3b0d8593814044e092ece2108fc3ac9aea4b900" + version "1.3.52" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.52.tgz#d2d9f1270ba4a3b967b831c40ef71fb4d9ab5ce0" elliptic@=3.0.3: version "3.0.3" @@ -3005,8 +3019,8 @@ encodeurl@~1.0.2: resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59" encoding-down@^5.0.2: - version "5.0.3" - resolved "https://registry.yarnpkg.com/encoding-down/-/encoding-down-5.0.3.tgz#b2b2305b2b810ff6d0bda85583bfc71bda56dc49" + version "5.0.4" + resolved "https://registry.yarnpkg.com/encoding-down/-/encoding-down-5.0.4.tgz#1e477da8e9e9d0f7c8293d320044f8b2cd8e9614" dependencies: abstract-leveldown "^5.0.0" inherits "^2.0.3" @@ -3069,15 +3083,7 @@ engine.io@~3.2.0: engine.io-parser "~2.1.0" ws "~3.3.1" -enhanced-resolve@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-4.0.0.tgz#e34a6eaa790f62fccd71d93959f56b2b432db10a" - dependencies: - graceful-fs "^4.1.2" - memory-fs "^0.4.0" - tapable "^1.0.0" - -enhanced-resolve@^4.1.0: +enhanced-resolve@^4.0.0, enhanced-resolve@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-4.1.0.tgz#41c7e0bfdfe74ac1ffe1e57ad6a5c6c9f3742a7f" dependencies: @@ -3102,8 +3108,8 @@ errno@^0.1.3, errno@~0.1.1, errno@~0.1.7: prr "~1.0.1" error-ex@^1.2.0, error-ex@^1.3.1: - version "1.3.1" - resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.1.tgz#f855a86ce61adc4e8621c3cda21e7a7612c3a8dc" + version "1.3.2" + resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" dependencies: is-arrayish "^0.2.1" @@ -3213,8 +3219,8 @@ escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1 resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" escodegen@1.x.x: - version "1.9.1" - resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.9.1.tgz#dbae17ef96c8e4bedb1356f4504fa4cc2f7cb7e2" + version "1.11.0" + resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.11.0.tgz#b27a9389481d5bfd5bec76f7bb1eb3f8f4556589" dependencies: esprima "^3.1.3" estraverse "^4.2.0" @@ -3304,13 +3310,27 @@ eslint-plugin-standard@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/eslint-plugin-standard/-/eslint-plugin-standard-3.0.1.tgz#34d0c915b45edc6f010393c7eef3823b08565cf2" -eslint-scope@3.7.1, eslint-scope@^3.7.1: +eslint-scope@3.7.1: version "3.7.1" resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.1.tgz#3d63c3edfda02e06e01a452ad88caacc7cdcb6e8" dependencies: esrecurse "^4.1.0" estraverse "^4.1.1" +eslint-scope@^3.7.1: + version "3.7.3" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.3.tgz#bb507200d3d17f60247636160b4826284b108535" + dependencies: + esrecurse "^4.1.0" + estraverse "^4.1.1" + +eslint-scope@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-4.0.0.tgz#50bf3071e9338bcdc43331794a0cb533f0136172" + dependencies: + esrecurse "^4.1.0" + estraverse "^4.1.1" + eslint-visitor-keys@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" @@ -3410,8 +3430,8 @@ esprima@3.1.3, esprima@3.x.x, esprima@^3.1.3: resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633" esprima@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804" + version "4.0.1" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" esquery@^1.0.0: version "1.0.1" @@ -3437,13 +3457,6 @@ etag@~1.8.1: version "1.8.1" resolved "https://registry.yarnpkg.com/etag/-/etag-1.8.1.tgz#41ae2eeb65efa62268aebfea83ac7d79299b0887" -eth-hash-to-cid@~0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/eth-hash-to-cid/-/eth-hash-to-cid-0.1.1.tgz#b44c9e656b02d0af5d05c8bc9fa6b0c0407616c3" - dependencies: - cids "^0.5.3" - multihashes "^0.4.13" - ethereum-common@0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/ethereum-common/-/ethereum-common-0.2.0.tgz#13bf966131cce1eeade62a1b434249bb4cb120ca" @@ -3460,7 +3473,7 @@ ethereumjs-account@^2.0.4: rlp "^2.0.0" safe-buffer "^5.1.1" -ethereumjs-block@^1.7.0: +ethereumjs-block@^1.7.1: version "1.7.1" resolved "https://registry.yarnpkg.com/ethereumjs-block/-/ethereumjs-block-1.7.1.tgz#78b88e6cc56de29a6b4884ee75379b6860333c3f" dependencies: @@ -3471,8 +3484,8 @@ ethereumjs-block@^1.7.0: merkle-patricia-tree "^2.1.2" ethereumjs-tx@^1.2.2, ethereumjs-tx@^1.3.3: - version "1.3.4" - resolved "https://registry.yarnpkg.com/ethereumjs-tx/-/ethereumjs-tx-1.3.4.tgz#c2304912f6c07af03237ad8675ac036e290dad48" + version "1.3.6" + resolved "https://registry.yarnpkg.com/ethereumjs-tx/-/ethereumjs-tx-1.3.6.tgz#d581c1703b7b250b2e54892031626534d53e0a79" dependencies: ethereum-common "^0.0.18" ethereumjs-util "^5.0.0" @@ -3490,8 +3503,8 @@ ethereumjs-util@^5.0.0: secp256k1 "^3.0.1" ethjs-util@^0.1.3: - version "0.1.4" - resolved "https://registry.yarnpkg.com/ethjs-util/-/ethjs-util-0.1.4.tgz#1c8b6879257444ef4d3f3fbbac2ded12cd997d93" + version "0.1.6" + resolved "https://registry.yarnpkg.com/ethjs-util/-/ethjs-util-0.1.6.tgz#f308b62f185f9fe6237132fb2a9818866a5cd536" dependencies: is-hex-prefixed "1.0.0" strip-hex-prefix "1.0.0" @@ -3611,8 +3624,8 @@ extend-shallow@^3.0.0, extend-shallow@^3.0.2: is-extendable "^1.0.1" extend@3, extend@^3.0.0, extend@~3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" + version "3.0.2" + resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" external-editor@^2.0.4: version "2.2.0" @@ -3969,10 +3982,10 @@ fs-constants@^1.0.0: resolved "https://registry.yarnpkg.com/fs-constants/-/fs-constants-1.0.0.tgz#6be0de9be998ce16af8afc24497b9ee9b7ccd9ad" "fs-ext@github:baudehlo/node-fs-ext#master": - version "1.0.0" - resolved "https://codeload.github.com/baudehlo/node-fs-ext/tar.gz/f5c9c9ec584937f8b216335d0c36d238b5d187c9" + version "1.2.1" + resolved "https://codeload.github.com/baudehlo/node-fs-ext/tar.gz/7c9824f3dc330e795aa13359d96252860bd3a684" dependencies: - nan "^2.0" + nan "^2.10.0" fs-extra@0.26.5: version "0.26.5" @@ -3991,6 +4004,14 @@ fs-extra@^2.0.0: graceful-fs "^4.1.2" jsonfile "^2.1.0" +fs-extra@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-5.0.0.tgz#414d0110cdd06705734d055652c5411260c31abd" + dependencies: + graceful-fs "^4.1.2" + jsonfile "^4.0.0" + universalify "^0.1.0" + fs-extra@~4.0.2: version "4.0.3" resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-4.0.3.tgz#0d852122e5bc5beb453fb028e9c0c9bf36340c94" @@ -4027,7 +4048,7 @@ fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" -fsevents@^1.1.2: +fsevents@^1.2.2: version "1.2.4" resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.4.tgz#f41dcb1af2582af3692da36fc55cbd8e1041c426" dependencies: @@ -4046,23 +4067,6 @@ fsm@^1.0.2: dependencies: split "~0.3.0" -fstream-ignore@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/fstream-ignore/-/fstream-ignore-1.0.5.tgz#9c31dae34767018fe1d249b24dada67d092da105" - dependencies: - fstream "^1.0.0" - inherits "2" - minimatch "^3.0.0" - -fstream@^1.0.0, fstream@^1.0.10, fstream@^1.0.2: - version "1.0.11" - resolved "https://registry.yarnpkg.com/fstream/-/fstream-1.0.11.tgz#5c1fb1f117477114f0632a0eb4b71b3cb0fd3171" - dependencies: - graceful-fs "^4.1.2" - inherits "~2.0.0" - mkdirp ">=0.5 0" - rimraf "2" - ftp@~0.3.10: version "0.3.10" resolved "https://registry.yarnpkg.com/ftp/-/ftp-0.3.10.tgz#9197d861ad8142f3e63d5a83bfe4c59f7330885d" @@ -4108,11 +4112,11 @@ gauge@~2.7.3: wide-align "^1.1.0" gc-stats@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/gc-stats/-/gc-stats-1.1.1.tgz#d2f8cb468b4379f6c27cb2dc1c8d2c05e2878a9f" + version "1.2.0" + resolved "https://registry.yarnpkg.com/gc-stats/-/gc-stats-1.2.0.tgz#c32845148f3f842064d5aafcc427306e523894f4" dependencies: - nan "^2.6.2" - node-pre-gyp "^0.7.0" + nan "^2.10.0" + node-pre-gyp "^0.10.0" generate-function@^2.0.0: version "2.0.0" @@ -4129,8 +4133,8 @@ get-browser-rtc@^1.0.0: resolved "https://registry.yarnpkg.com/get-browser-rtc/-/get-browser-rtc-1.0.2.tgz#bbcd40c8451a7ed4ef5c373b8169a409dd1d11d9" get-caller-file@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.2.tgz#f702e63127e7e231c160a80c1554acb70d5047e5" + version "1.0.3" + resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" get-folder-size@^2.0.0: version "2.0.0" @@ -4186,6 +4190,10 @@ git-rev-sync@1.9.1: graceful-fs "4.1.11" shelljs "0.7.7" +git-validate@^2.2.2: + version "2.2.4" + resolved "https://registry.yarnpkg.com/git-validate/-/git-validate-2.2.4.tgz#0adc02a2887f09ffe077db38932ba8a3de508cbe" + github-from-package@0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/github-from-package/-/github-from-package-0.0.0.tgz#97fb5d96bfde8973313f20e8288ef9a167fa64ce" @@ -4236,8 +4244,8 @@ global-dirs@^0.1.0: ini "^1.3.4" global-modules-path@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/global-modules-path/-/global-modules-path-2.1.0.tgz#923ec524e8726bb0c1a4ed4b8e21e1ff80c88bbb" + version "2.2.0" + resolved "https://registry.yarnpkg.com/global-modules-path/-/global-modules-path-2.2.0.tgz#24648267c65d02604c5549f04b46ac8973b4ba40" global@^4.3.1, global@^4.3.2: version "4.3.2" @@ -4246,11 +4254,7 @@ global@^4.3.1, global@^4.3.2: min-document "^2.19.0" process "~0.5.1" -globals@^11.0.1: - version "11.5.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-11.5.0.tgz#6bc840de6771173b191f13d3a9c94d441ee92642" - -globals@^11.1.0: +globals@^11.0.1, globals@^11.1.0: version "11.7.0" resolved "https://registry.yarnpkg.com/globals/-/globals-11.7.0.tgz#a583faa43055b1aca771914bf68258e2fc125673" @@ -4430,10 +4434,10 @@ has-values@^1.0.0: kind-of "^4.0.0" has@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/has/-/has-1.0.1.tgz#8461733f538b0837c9361e39a9ab9e9704dc2f28" + version "1.0.3" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" dependencies: - function-bind "^1.0.2" + function-bind "^1.1.1" hasbin@^1.2.3: version "1.2.3" @@ -4448,12 +4452,12 @@ hash-base@^3.0.0: inherits "^2.0.1" safe-buffer "^5.0.1" -hash.js@^1.0.0, hash.js@^1.0.3, hash.js@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/hash.js/-/hash.js-1.1.3.tgz#340dedbe6290187151c1ea1d777a3448935df846" +hash.js@^1.0.0, hash.js@^1.0.3: + version "1.1.5" + resolved "https://registry.yarnpkg.com/hash.js/-/hash.js-1.1.5.tgz#e38ab4b85dfb1e0c40fe9265c0e9b54854c23812" dependencies: inherits "^2.0.3" - minimalistic-assert "^1.0.0" + minimalistic-assert "^1.0.1" hashlru@^2.2.1: version "2.2.1" @@ -4472,7 +4476,7 @@ he@1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" -heap@^0.2.6: +heap@~0.2.6: version "0.2.6" resolved "https://registry.yarnpkg.com/heap/-/heap-0.2.6.tgz#087e1f10b046932fc8594dd9e6d378afc9d1e5ac" @@ -4508,8 +4512,8 @@ home-or-tmp@^2.0.0: os-tmpdir "^1.0.1" hosted-git-info@^2.1.4: - version "2.6.0" - resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.6.0.tgz#23235b29ab230c576aab0d4f13fc046b0b038222" + version "2.7.1" + resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.7.1.tgz#97f236977bd6e125408930ff6de3eec6281ec047" html-comment-regex@^1.1.0: version "1.1.1" @@ -4585,8 +4589,8 @@ husky@0.14.3: strip-indent "^2.0.0" hyperscript-attribute-to-property@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/hyperscript-attribute-to-property/-/hyperscript-attribute-to-property-1.0.0.tgz#825308d49bb8e2957923f731981bcc811cad7aff" + version "1.0.1" + resolved "https://registry.yarnpkg.com/hyperscript-attribute-to-property/-/hyperscript-attribute-to-property-1.0.1.tgz#06ecb885bd64424de889df545899fcf0015e4787" hyperx@^2.3.2: version "2.4.0" @@ -4594,22 +4598,16 @@ hyperx@^2.3.2: dependencies: hyperscript-attribute-to-property "^1.0.0" -iconv-lite@0.4.19, iconv-lite@^0.4.17, iconv-lite@~0.4.13: +iconv-lite@0.4.19: version "0.4.19" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.19.tgz#f7468f60135f5e5dad3399c0a81be9a1603a082b" -iconv-lite@0.4.23, iconv-lite@^0.4.22: +iconv-lite@0.4.23, iconv-lite@^0.4.17, iconv-lite@^0.4.22, iconv-lite@^0.4.4, iconv-lite@~0.4.13: version "0.4.23" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.23.tgz#297871f63be507adcfbfca715d0cd0eed84e9a63" dependencies: safer-buffer ">= 2.1.2 < 3" -iconv-lite@^0.4.4: - version "0.4.21" - resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.21.tgz#c47f8733d02171189ebc4a400f3218d348094798" - dependencies: - safer-buffer "^2.1.0" - idb-readable-stream@0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/idb-readable-stream/-/idb-readable-stream-0.0.4.tgz#3283da6645bf6b220dc61ba61df62bee5dae4acf" @@ -4617,8 +4615,8 @@ idb-readable-stream@0.0.4: xtend "^4.0.1" ieee754@^1.1.11, ieee754@^1.1.4, ieee754@^1.1.8: - version "1.1.11" - resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.1.11.tgz#c16384ffe00f5b7835824e67b6f2bd44a5229455" + version "1.1.12" + resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.1.12.tgz#50bf24e5b9c8bb98af4964c941cdb0918da7b60b" iferr@^0.1.5: version "0.1.5" @@ -4635,8 +4633,8 @@ ignore-walk@^3.0.1: minimatch "^3.0.4" ignore@^3.0.11, ignore@^3.0.9, ignore@^3.2.0, ignore@^3.3.3: - version "3.3.8" - resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.8.tgz#3f8e9c35d38708a3a7e0e9abb6c73e7ee7707b2b" + version "3.3.10" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" immediate@^3.2.3, immediate@~3.2.3: version "3.2.3" @@ -4679,7 +4677,7 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@2.0.3, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3: +inherits@2, inherits@2.0.3, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.1, inherits@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" @@ -4796,7 +4794,7 @@ ipaddr.js@1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.6.0.tgz#e3fa357b773da619f26e95f049d055c72796f86b" -ipfs-api@22.2.3, ipfs-api@^22.2.1: +ipfs-api@22.2.3: version "22.2.3" resolved "https://registry.yarnpkg.com/ipfs-api/-/ipfs-api-22.2.3.tgz#6ff425070690d3a87234dba3f814d6e03fdf2900" dependencies: @@ -4836,6 +4834,47 @@ ipfs-api@22.2.3, ipfs-api@^22.2.1: streamifier "~0.1.1" tar-stream "^1.6.1" +ipfs-api@^22.2.1: + version "22.2.4" + resolved "https://registry.yarnpkg.com/ipfs-api/-/ipfs-api-22.2.4.tgz#226ebe5caffb5c58ae8d96d1ed3870a694b24cc7" + dependencies: + async "^2.6.1" + big.js "^5.1.2" + bs58 "^4.0.1" + cids "~0.5.3" + concat-stream "^1.6.2" + debug "^3.1.0" + detect-node "^2.0.3" + flatmap "0.0.3" + glob "^7.1.2" + ipfs-block "~0.7.1" + ipfs-unixfs "~0.1.15" + ipld-dag-cbor "~0.12.1" + ipld-dag-pb "~0.14.5" + is-ipfs "~0.3.2" + is-pull-stream "0.0.0" + is-stream "^1.1.0" + libp2p-crypto "~0.13.0" + lru-cache "^4.1.3" + multiaddr "^5.0.0" + multibase "~0.4.0" + multihashes "~0.4.13" + ndjson "^1.5.0" + once "^1.4.0" + peer-id "~0.11.0" + peer-info "~0.14.1" + promisify-es6 "^1.0.3" + pull-defer "~0.2.2" + 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" + stream-http "^2.8.3" + stream-to-pull-stream "^1.7.2" + streamifier "~0.1.1" + tar-stream "^1.6.1" + ipfs-bitswap@~0.20.2: version "0.20.3" resolved "https://registry.yarnpkg.com/ipfs-bitswap/-/ipfs-bitswap-0.20.3.tgz#eb7f5e959da9d0e841a5aaef725fddea186a4e51" @@ -4901,8 +4940,8 @@ ipfs-http-response@0.1.2, ipfs-http-response@~0.1.2: readable-stream-node-to-web "^1.0.1" ipfs-mfs@~0.0.14: - version "0.0.16" - resolved "https://registry.yarnpkg.com/ipfs-mfs/-/ipfs-mfs-0.0.16.tgz#48b3d616e4ee2c561db0dd6f5ae47293f12dbf59" + version "0.0.17" + resolved "https://registry.yarnpkg.com/ipfs-mfs/-/ipfs-mfs-0.0.17.tgz#cacff41bbce07a576b2dd0abd7c4e210dc806133" dependencies: async "^2.6.1" blob "~0.0.4" @@ -4961,7 +5000,7 @@ ipfs-postmsg-proxy@3.0.0: shortid "^2.2.8" stream-to-pull-stream "^1.7.2" -ipfs-repo@~0.22.0, ipfs-repo@~0.22.1: +ipfs-repo@~0.22.1: version "0.22.1" resolved "https://registry.yarnpkg.com/ipfs-repo/-/ipfs-repo-0.22.1.tgz#39a1d07f56a95455ab1aca85cac3391cdcb62c6a" dependencies: @@ -4983,8 +5022,8 @@ ipfs-repo@~0.22.0, ipfs-repo@~0.22.1: pull-stream "^3.6.7" ipfs-unixfs-engine@~0.30.0: - version "0.30.0" - resolved "https://registry.yarnpkg.com/ipfs-unixfs-engine/-/ipfs-unixfs-engine-0.30.0.tgz#95c38f0f6fde455b9a731999a638a47786a19120" + version "0.30.1" + resolved "https://registry.yarnpkg.com/ipfs-unixfs-engine/-/ipfs-unixfs-engine-0.30.1.tgz#ed14a64a496694609d2b129ed4183180a9b54917" dependencies: async "^2.6.1" bs58 "^4.0.1" @@ -5111,28 +5150,15 @@ ipfs@0.30.0: prom-client "^11.1.1" prometheus-gc-stats "~0.5.1" -ipld-bitcoin@~0.1.5: - version "0.1.5" - resolved "https://registry.yarnpkg.com/ipld-bitcoin/-/ipld-bitcoin-0.1.5.tgz#40345d01871050d959c6ef17c78fd27bc454b881" +ipld-bitcoin@~0.1.6: + version "0.1.7" + resolved "https://registry.yarnpkg.com/ipld-bitcoin/-/ipld-bitcoin-0.1.7.tgz#4f9a1cd6bae3bf835c38c24252065caaf9732346" dependencies: bitcoinjs-lib "^3.3.2" cids "~0.5.2" - dirty-chai "^2.0.1" - hash.js "^1.1.3" - multihashes "~0.4.12" - -ipld-dag-cbor@~0.12.0: - version "0.12.0" - resolved "https://registry.yarnpkg.com/ipld-dag-cbor/-/ipld-dag-cbor-0.12.0.tgz#aea01be0d72dfc93004cfa537a75f163439906b6" - dependencies: - async "^2.6.0" - borc "^2.0.2" - bs58 "^4.0.1" - cids "~0.5.2" - is-circular "^1.0.1" + git-validate "^2.2.2" multihashes "~0.4.12" - multihashing-async "~0.4.7" - traverse "^0.6.6" + multihashing-async "~0.5.1" ipld-dag-cbor@~0.12.1: version "0.12.1" @@ -5147,24 +5173,7 @@ ipld-dag-cbor@~0.12.1: multihashing-async "~0.5.1" traverse "~0.6.6" -ipld-dag-pb@^0.14.4, ipld-dag-pb@~0.14.4: - version "0.14.4" - resolved "https://registry.yarnpkg.com/ipld-dag-pb/-/ipld-dag-pb-0.14.4.tgz#9a147575939832ab143da5b3a1b11cc37905ef7e" - dependencies: - async "^2.6.0" - bs58 "^4.0.1" - buffer-loader "~0.0.1" - cids "~0.5.3" - class-is "^1.1.0" - is-ipfs "~0.3.2" - multihashes "~0.4.13" - multihashing-async "~0.4.8" - protons "^1.0.1" - pull-stream "^3.6.7" - pull-traverse "^1.0.3" - stable "0.1.6" - -ipld-dag-pb@~0.14.5: +ipld-dag-pb@^0.14.4, ipld-dag-pb@~0.14.4, ipld-dag-pb@~0.14.5: version "0.14.5" resolved "https://registry.yarnpkg.com/ipld-dag-pb/-/ipld-dag-pb-0.14.5.tgz#bec6417401b32a80818190636a08edc0048dccec" dependencies: @@ -5181,15 +5190,14 @@ ipld-dag-pb@~0.14.5: pull-traverse "^1.0.3" stable "~0.1.8" -ipld-ethereum@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ipld-ethereum/-/ipld-ethereum-2.0.0.tgz#f024c201f8ec670f6c18c91cf3d8d39879330acf" +ipld-ethereum@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/ipld-ethereum/-/ipld-ethereum-2.0.1.tgz#673b189f1506540d3509db208bb95adbefcda462" dependencies: async "^2.6.0" cids "~0.5.2" - eth-hash-to-cid "~0.1.0" ethereumjs-account "^2.0.4" - ethereumjs-block "^1.7.0" + ethereumjs-block "^1.7.1" ethereumjs-tx "^1.3.3" ipfs-block "~0.6.1" merkle-patricia-tree "^2.2.0" @@ -5197,57 +5205,58 @@ ipld-ethereum@^2.0.0: multihashing-async "~0.4.7" rlp "^2.0.0" -ipld-git@~0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/ipld-git/-/ipld-git-0.2.0.tgz#3f8cfb8ede658b182cffbc70a683d9795bfdc716" +ipld-git@~0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/ipld-git/-/ipld-git-0.2.1.tgz#89d65fe4712493742e942c0a764d2c142d071701" dependencies: async "^2.6.0" cids "~0.5.2" multicodec "~0.2.5" multihashes "~0.4.12" - multihashing-async "~0.4.7" + multihashing-async "~0.5.1" smart-buffer "^4.0.0" traverse "~0.6.6" -ipld-raw@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ipld-raw/-/ipld-raw-2.0.0.tgz#fbac777ebed67e6a5de0991a74f488a005b9e812" +ipld-raw@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/ipld-raw/-/ipld-raw-2.0.1.tgz#aff7d471ebc26e9283910a23eff43857e3c1ab46" dependencies: cids "~0.5.2" + multihashing-async "~0.5.1" -ipld-zcash@~0.1.3: - version "0.1.3" - resolved "https://registry.yarnpkg.com/ipld-zcash/-/ipld-zcash-0.1.3.tgz#67e8286ee4244a2ad32024cc5e4ad4201cfa60a1" +ipld-zcash@~0.1.4: + version "0.1.5" + resolved "https://registry.yarnpkg.com/ipld-zcash/-/ipld-zcash-0.1.5.tgz#c4f57cb6d73093865b7dea2821591c541d60b52d" dependencies: cids "~0.5.2" dirty-chai "^2.0.1" - hash.js "^1.1.3" multihashes "~0.4.12" - zcash-bitcore-lib "^0.13.20-rc3" + multihashing-async "~0.5.1" + zcash-bitcore-lib "~0.13.20-rc3" ipld@~0.17.2: - version "0.17.2" - resolved "https://registry.yarnpkg.com/ipld/-/ipld-0.17.2.tgz#a84a978bf04591cae79099cf736b584467faf076" + version "0.17.3" + resolved "https://registry.yarnpkg.com/ipld/-/ipld-0.17.3.tgz#ede5440a5b8469b1f0280502e21a5d83011d8630" dependencies: async "^2.6.1" cids "~0.5.3" interface-datastore "~0.4.2" ipfs-block "~0.7.1" ipfs-block-service "~0.14.0" - ipfs-repo "~0.22.0" - ipld-bitcoin "~0.1.5" - ipld-dag-cbor "~0.12.0" - ipld-dag-pb "~0.14.4" - ipld-ethereum "^2.0.0" - ipld-git "~0.2.0" - ipld-raw "^2.0.0" - ipld-zcash "~0.1.3" + ipfs-repo "~0.22.1" + ipld-bitcoin "~0.1.6" + ipld-dag-cbor "~0.12.1" + ipld-dag-pb "~0.14.5" + ipld-ethereum "^2.0.1" + ipld-git "~0.2.1" + ipld-raw "^2.0.1" + ipld-zcash "~0.1.4" is-ipfs "~0.3.2" lodash.flatten "^4.4.0" lodash.includes "^4.3.0" memdown "^3.0.0" multihashes "~0.4.13" - pull-defer "^0.2.2" + pull-defer "~0.2.2" pull-sort "^1.0.1" pull-stream "^3.6.8" pull-traverse "^1.0.3" @@ -5308,8 +5317,8 @@ is-buffer@^1.0.2, is-buffer@^1.1.5: resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" is-buffer@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-2.0.2.tgz#f83a0c5bc453f6431bf83cc2ceff6cbc9d50a83b" + version "2.0.3" + resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-2.0.3.tgz#4ecf3fcf749cbd1e472689e109ac66261a25e725" is-builtin-module@^1.0.0: version "1.0.0" @@ -5318,8 +5327,8 @@ is-builtin-module@^1.0.0: builtin-modules "^1.0.0" is-callable@^1.1.1, is-callable@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.3.tgz#86eb75392805ddc33af71c92a0eedf74ee7604b2" + version "1.1.4" + resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.4.tgz#1e1adf219e1eeb684d691f9d6a05ff0d30a24d75" is-ci@^1.0.10: version "1.1.0" @@ -5328,8 +5337,8 @@ is-ci@^1.0.10: ci-info "^1.0.0" is-circular@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-circular/-/is-circular-1.0.1.tgz#65b0476a8588e546b8087c1d66d4c08d82a31679" + version "1.0.2" + resolved "https://registry.yarnpkg.com/is-circular/-/is-circular-1.0.2.tgz#2e0ab4e9835f4c6b0ea2b9855a84acd501b8366c" is-data-descriptor@^0.1.4: version "0.1.4" @@ -5460,20 +5469,10 @@ is-number@^3.0.0: dependencies: kind-of "^3.0.2" -is-number@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/is-number/-/is-number-4.0.0.tgz#0026e37f5454d73e356dfe6564699867c6a7f0ff" - is-obj@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-1.0.1.tgz#3e4729ac1f5fde025cd7d83a896dab9f4f67db0f" -is-odd@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/is-odd/-/is-odd-2.0.0.tgz#7646624671fd7ea558ccd9a2795182f2958f1b24" - dependencies: - is-number "^4.0.0" - is-path-cwd@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-path-cwd/-/is-path-cwd-1.0.0.tgz#d225ec23132e89edd38fda767472e62e65f1106d" @@ -5534,7 +5533,7 @@ is-retry-allowed@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-retry-allowed/-/is-retry-allowed-1.1.0.tgz#11a060568b67339444033d0125a61a20d564fb34" -is-stream@^1.0.0, is-stream@^1.1.0: +is-stream@1.1.0, is-stream@^1.0.0, is-stream@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" @@ -5581,8 +5580,8 @@ isemail@2.x.x: resolved "https://registry.yarnpkg.com/isemail/-/isemail-2.2.1.tgz#0353d3d9a62951080c262c2aa0a42b8ea8e9e2a6" isemail@3.x.x: - version "3.1.2" - resolved "https://registry.yarnpkg.com/isemail/-/isemail-3.1.2.tgz#937cf919002077999a73ea8b1951d590e84e01dd" + version "3.1.3" + resolved "https://registry.yarnpkg.com/isemail/-/isemail-3.1.3.tgz#64f37fc113579ea12523165c3ebe3a71a56ce571" dependencies: punycode "2.x.x" @@ -5612,9 +5611,9 @@ istanbul-lib-coverage@^1.1.2, istanbul-lib-coverage@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-1.2.0.tgz#f7d8f2e42b97e37fe796114cb0f9d68b5e3a4341" -istanbul-lib-coverage@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.0.tgz#905e71212052ffb34f2eb008102230bff03940b5" +istanbul-lib-coverage@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.1.tgz#2aee0e073ad8c5f6a0b00e0dfbf52b4667472eda" istanbul-lib-hook@^1.1.0: version "1.1.0" @@ -5623,15 +5622,15 @@ istanbul-lib-hook@^1.1.0: append-transform "^0.4.0" istanbul-lib-instrument@^2.1.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-2.3.0.tgz#777d3ba7aad2594105e60834efcbe968d11bebbc" + version "2.3.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-2.3.1.tgz#406406730a395acb2e50f0d98137ace16bd4a970" dependencies: "@babel/generator" "7.0.0-beta.51" "@babel/parser" "7.0.0-beta.51" "@babel/template" "7.0.0-beta.51" "@babel/traverse" "7.0.0-beta.51" "@babel/types" "7.0.0-beta.51" - istanbul-lib-coverage "^2.0.0" + istanbul-lib-coverage "^2.0.1" semver "^5.5.0" istanbul-lib-report@^1.1.3: @@ -5722,9 +5721,13 @@ js-tokens@^3.0.0, js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" +"js-tokens@^3.0.0 || ^4.0.0": + version "4.0.0" + resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + js-yaml@^3.5.1, js-yaml@^3.5.3, js-yaml@^3.9.1: - version "3.11.0" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.11.0.tgz#597c1a8bd57152f26d622ce4117851a51f5ebaef" + version "3.12.0" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.12.0.tgz#eaed656ec8344f10f527c6bfa1b6e2244de167d1" dependencies: argparse "^1.0.7" esprima "^4.0.0" @@ -5763,6 +5766,10 @@ json-schema-traverse@^0.3.0: version "0.3.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340" +json-schema-traverse@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" + json-schema@0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" @@ -5872,7 +5879,7 @@ jws@^3.1.4: jwa "^1.1.5" safe-buffer "^5.0.1" -k-bucket@^4.0.0: +k-bucket@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/k-bucket/-/k-bucket-4.0.1.tgz#3fc2e5693f0b7bff90d7b6b476edd6087955d542" dependencies: @@ -5957,21 +5964,13 @@ lcid@^1.0.0: dependencies: invert-kv "^1.0.0" -leb@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/leb/-/leb-0.3.0.tgz#32bee9fad168328d6aea8522d833f4180eed1da3" - -left-pad@^1.1.3: - version "1.2.0" - resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.2.0.tgz#d30a73c6b8201d8f7d8e7956ba9616087a68e0ee" - -left-pad@^1.3.0: +left-pad@^1.1.3, left-pad@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.3.0.tgz#5b8a3a7765dfe001261dde915589e782f8c94d1e" length-prefixed-stream@^1.5.2: - version "1.5.2" - resolved "https://registry.yarnpkg.com/length-prefixed-stream/-/length-prefixed-stream-1.5.2.tgz#269b29ff76324361727447f1bfacb762e6965a8f" + version "1.6.0" + resolved "https://registry.yarnpkg.com/length-prefixed-stream/-/length-prefixed-stream-1.6.0.tgz#6aeeecf38a337172ea0472250e90f5e15b8b2334" dependencies: buffer-alloc-unsafe "^1.0.0" readable-stream "^2.0.0" @@ -6013,8 +6012,8 @@ level-iterator-stream@~1.3.0: xtend "^4.0.0" level-iterator-stream@~2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/level-iterator-stream/-/level-iterator-stream-2.0.0.tgz#e0fe4273a0322177c81bb87684016bb5b90a98b4" + version "2.0.3" + resolved "https://registry.yarnpkg.com/level-iterator-stream/-/level-iterator-stream-2.0.3.tgz#ccfff7c046dcf47955ae9a86f46dfa06a31688b4" dependencies: inherits "^2.0.1" readable-stream "^2.0.5" @@ -6185,26 +6184,26 @@ libp2p-identify@~0.7.1: pull-stream "^3.6.7" libp2p-kad-dht@~0.10.0: - version "0.10.0" - resolved "https://registry.yarnpkg.com/libp2p-kad-dht/-/libp2p-kad-dht-0.10.0.tgz#d4de2a25a7d0bb1d66e95519571a54f7c75617c4" + version "0.10.1" + resolved "https://registry.yarnpkg.com/libp2p-kad-dht/-/libp2p-kad-dht-0.10.1.tgz#cca4bb57436bb7c028d2a4368285ae8ef3d3d086" dependencies: - async "^2.6.0" - base32.js "^0.1.0" + async "^2.6.1" + base32.js "~0.1.0" cids "~0.5.3" debug "^3.1.0" hashlru "^2.2.1" - heap "^0.2.6" + heap "~0.2.6" interface-datastore "~0.4.2" - k-bucket "^4.0.0" + k-bucket "^4.0.1" libp2p-crypto "~0.13.0" libp2p-record "~0.5.1" - multihashing-async "~0.4.8" - peer-id "~0.10.7" - peer-info "~0.14.0" - priorityqueue "^0.2.1" + multihashing-async "~0.5.1" + peer-id "~0.11.0" + peer-info "~0.14.1" + priorityqueue "~0.2.1" protons "^1.0.1" - pull-length-prefixed "^1.3.0" - pull-stream "^3.6.7" + pull-length-prefixed "^1.3.1" + pull-stream "^3.6.8" varint "^5.0.0" xor-distance "^1.0.0" @@ -6286,8 +6285,8 @@ libp2p-secio@~0.10.0: pull-stream "^3.6.7" libp2p-switch@~0.40.4: - version "0.40.5" - resolved "https://registry.yarnpkg.com/libp2p-switch/-/libp2p-switch-0.40.5.tgz#40910fd0df8924e2cf5a214a142f3b27fe296674" + version "0.40.6" + resolved "https://registry.yarnpkg.com/libp2p-switch/-/libp2p-switch-0.40.6.tgz#52bddbd3932f7c9f0f1b9dc5e070bcb4ebd27283" dependencies: async "^2.6.0" big.js "^5.1.2" @@ -6634,7 +6633,7 @@ lodash.values@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/lodash.values/-/lodash.values-4.3.0.tgz#a3a6c2b0ebecc5c2cba1c17e6e620fe81b53d347" -lodash@4.17.10, lodash@^4.17.10, lodash@^4.2.0: +lodash@4.17.10, lodash@^4.0.0, lodash@^4.11.1, lodash@^4.14.0, lodash@^4.15.0, lodash@^4.16.3, lodash@^4.17.10, lodash@^4.17.4, lodash@^4.17.5, lodash@^4.2.0, lodash@^4.3.0, lodash@^4.8.0, lodash@~4.17.2: version "4.17.10" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.10.tgz#1b7793cf7259ea38fb3661d4d38b3260af8ae4e7" @@ -6642,10 +6641,6 @@ lodash@=3.10.1: version "3.10.1" resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6" -lodash@^4.0.0, lodash@^4.11.1, lodash@^4.14.0, lodash@^4.15.0, lodash@^4.16.3, lodash@^4.17.4, lodash@^4.17.5, lodash@^4.3.0, lodash@^4.8.0, lodash@~4.17.2: - version "4.17.5" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.5.tgz#99a92d65c0272debe8c96b6057bc8fbfa3bed511" - log-update@2.3.x: version "2.3.0" resolved "https://registry.yarnpkg.com/log-update/-/log-update-2.3.0.tgz#88328fd7d1ce7938b29283746f0b1bc126b24708" @@ -6654,13 +6649,13 @@ log-update@2.3.x: cli-cursor "^2.0.0" wrap-ansi "^3.0.1" -lolex@^2.2.0, lolex@^2.3.2: - version "2.3.2" - resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.3.2.tgz#85f9450425103bf9e7a60668ea25dc43274ca807" +lolex@^2.2.0, lolex@^2.3.2, lolex@^2.4.2: + version "2.7.1" + resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.7.1.tgz#e40a8c4d1f14b536aa03e42a537c7adbaf0c20be" -lolex@^2.4.2: - version "2.7.0" - resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.7.0.tgz#9c087a69ec440e39d3f796767cf1b2cdc43d5ea5" +long@4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/long/-/long-4.0.0.tgz#9a7b71cfb7d361a194ea555241c92f7468d5bf28" long@^3.2.0: version "3.2.0" @@ -6683,10 +6678,10 @@ looper@^4.0.0: resolved "https://registry.yarnpkg.com/looper/-/looper-4.0.0.tgz#7706aded59a99edca06e6b54bb86c8ec19c95155" loose-envify@^1.0.0: - version "1.3.1" - resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.3.1.tgz#d1a8ad33fa9ce0e713d65fdd0ac8b748d478c848" + version "1.4.0" + resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.4.0.tgz#71ee51fa7be4caec1a63839f7e682d8132d30caf" dependencies: - js-tokens "^3.0.0" + js-tokens "^3.0.0 || ^4.0.0" lower-case@^1.1.1: version "1.1.4" @@ -6894,16 +6889,26 @@ miller-rabin@^4.0.0: bn.js "^4.0.0" brorand "^1.0.1" -mime-db@1.x.x, mime-db@~1.33.0: +mime-db@1.x.x, mime-db@~1.35.0: + version "1.35.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.35.0.tgz#0569d657466491283709663ad379a99b90d9ab47" + +mime-db@~1.33.0: version "1.33.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.33.0.tgz#a3492050a5cb9b63450541e39d9788d2272783db" -mime-types@2.1.18, mime-types@^2.1.12, mime-types@^2.1.18, mime-types@~2.1.17, mime-types@~2.1.18: +mime-types@2.1.18: version "2.1.18" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.18.tgz#6f323f60a83d11146f831ff11fd66e2fe5503bb8" dependencies: mime-db "~1.33.0" +mime-types@^2.1.12, mime-types@^2.1.18, mime-types@~2.1.17, mime-types@~2.1.18: + version "2.1.19" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.19.tgz#71e464537a7ef81c15f2db9d97e913fc0ff606f0" + dependencies: + mime-db "~1.35.0" + mime@1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/mime/-/mime-1.4.1.tgz#121f9ebc49e3766f311a76e1fa1c8003c4b03aa6" @@ -6917,8 +6922,8 @@ mimic-fn@^1.0.0: resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" mimic-response@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-1.0.0.tgz#df3d3652a73fded6b9b0b24146e6fd052353458e" + version "1.0.1" + resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-1.0.1.tgz#4923538878eef42063cb8a3e3b0798781487ab1b" mimos@^3.0.3: version "3.0.3" @@ -6933,7 +6938,7 @@ min-document@^2.19.0: dependencies: dom-walk "^0.1.0" -minimalistic-assert@^1.0.0: +minimalistic-assert@^1.0.0, minimalistic-assert@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" @@ -6941,7 +6946,7 @@ minimalistic-crypto-utils@^1.0.0, minimalistic-crypto-utils@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz#f6c00c1c0b082246e5c4d99dfb8c7c083b2b582a" -"minimatch@2 || 3", minimatch@3.0.4, minimatch@^3.0.0, minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: +"minimatch@2 || 3", minimatch@3.0.4, minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" dependencies: @@ -7001,7 +7006,7 @@ mixin-object@^2.0.1: for-in "^0.1.3" is-extendable "^0.1.1" -mkdirp@0.5.1, "mkdirp@>=0.5 0", mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@~0.5.0, mkdirp@~0.5.1: +mkdirp@0.5.1, mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@~0.5.0, mkdirp@~0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" dependencies: @@ -7124,13 +7129,7 @@ multicast-dns@^7.0.0: dns-packet "^4.0.0" thunky "^1.0.2" -multicodec@~0.2.5, multicodec@~0.2.6: - version "0.2.6" - resolved "https://registry.yarnpkg.com/multicodec/-/multicodec-0.2.6.tgz#9d2d6565fbc0815b139dfc906371fc39df4dfddb" - dependencies: - varint "^5.0.0" - -multicodec@~0.2.7: +multicodec@~0.2.5, multicodec@~0.2.6, multicodec@~0.2.7: version "0.2.7" resolved "https://registry.yarnpkg.com/multicodec/-/multicodec-0.2.7.tgz#44dcb902b7ccd8065c4c348fe9987acf14a0679d" dependencies: @@ -7221,7 +7220,7 @@ mz@2.7.0, mz@^2.6.0: object-assign "^4.0.1" thenify-all "^1.0.0" -nan@^2.0, nan@^2.10.0, nan@^2.2.1, nan@^2.6.2, nan@^2.9.2, nan@~2.10.0: +nan@^2.10.0, nan@^2.2.1, nan@^2.9.2, nan@~2.10.0: version "2.10.0" resolved "https://registry.yarnpkg.com/nan/-/nan-2.10.0.tgz#96d0cd610ebd58d4b4de9cc0c6828cda99c7548f" @@ -7256,8 +7255,10 @@ nanocomponent@^6.5.0: on-load "^3.3.4" nanohref@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/nanohref/-/nanohref-3.0.1.tgz#3879428e4fa80b7d5484692471cfa0b4a3348f8e" + version "3.0.3" + resolved "https://registry.yarnpkg.com/nanohref/-/nanohref-3.0.3.tgz#194d78561c22d73d9006464a7d1246396552f6cc" + dependencies: + nanoassert "^1.1.0" nanohtml@^1.1.0: version "1.2.4" @@ -7274,6 +7275,10 @@ nanohtml@^1.1.0: through2 "^2.0.3" transform-ast "^2.4.0" +nanoid@^1.0.7: + version "1.1.0" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-1.1.0.tgz#b18e806e1cdbfdbe030374d5cf08a48cbc80b474" + nanolocation@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/nanolocation/-/nanolocation-1.0.1.tgz#1ec4d6ad567be81e34108a66b982a0a2f54d1e11" @@ -7285,15 +7290,14 @@ nanolru@^1.0.0: resolved "https://registry.yarnpkg.com/nanolru/-/nanolru-1.0.0.tgz#0a5679cd4e4578c4ca3741e610b71c4c9b5afaf8" nanomatch@^1.2.9: - version "1.2.9" - resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.9.tgz#879f7150cb2dab7a471259066c104eee6e0fa7c2" + version "1.2.13" + resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.13.tgz#b87a8aa4fc0de8fe6be88895b38983ff265bd119" dependencies: arr-diff "^4.0.0" array-unique "^0.3.2" define-property "^2.0.2" extend-shallow "^3.0.2" fragment-cache "^0.2.1" - is-odd "^2.0.0" is-windows "^1.0.2" kind-of "^6.0.2" object.pick "^1.3.0" @@ -7314,8 +7318,10 @@ nanoquery@^1.1.0: nanoassert "^1.1.0" nanoraf@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/nanoraf/-/nanoraf-3.0.1.tgz#ab9fb9c257b9adcc71d82982cb58d8fa3503764a" + version "3.1.0" + resolved "https://registry.yarnpkg.com/nanoraf/-/nanoraf-3.1.0.tgz#97a892f1009146b95c8774b521d92e45dcdd229b" + dependencies: + nanoassert "^1.1.0" nanorouter@^3.0.1: version "3.1.1" @@ -7367,7 +7373,7 @@ ndjson@^1.5.0: split2 "^2.1.0" through2 "^2.0.3" -needle@^2.0.1, needle@^2.2.0: +needle@^2.0.1, needle@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/needle/-/needle-2.2.1.tgz#b5e325bd3aae8c2678902fa296f729455d1d3a7d" dependencies: @@ -7403,8 +7409,8 @@ nigel@2.x.x: vise "2.x.x" nise@^1.2.0, nise@^1.3.3: - version "1.4.0" - resolved "https://registry.yarnpkg.com/nise/-/nise-1.4.0.tgz#7aa1fe955f5ef121853d898cc4d660e91295d5e9" + version "1.4.2" + resolved "https://registry.yarnpkg.com/nise/-/nise-1.4.2.tgz#a9a3800e3994994af9e452333d549d60f72b8e8c" dependencies: "@sinonjs/formatio" "^2.0.0" just-extend "^1.1.27" @@ -7419,8 +7425,8 @@ no-case@^2.2.0: lower-case "^1.1.1" node-abi@^2.2.0: - version "2.4.1" - resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-2.4.1.tgz#7628c4d4ec4e9cd3764ceb3652f36b2e7f8d4923" + version "2.4.3" + resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-2.4.3.tgz#43666b7b17e57863e572409edbb82115ac7af28b" dependencies: semver "^5.4.1" @@ -7466,35 +7472,20 @@ node-notifier@5.2.1: which "^1.3.0" node-pre-gyp@^0.10.0: - version "0.10.0" - resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.10.0.tgz#6e4ef5bb5c5203c6552448828c852c40111aac46" + version "0.10.3" + resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.10.3.tgz#3070040716afdc778747b61b6887bf78880b80fc" dependencies: detect-libc "^1.0.2" mkdirp "^0.5.1" - needle "^2.2.0" + needle "^2.2.1" nopt "^4.0.1" npm-packlist "^1.1.6" npmlog "^4.0.2" - rc "^1.1.7" + rc "^1.2.7" rimraf "^2.6.1" semver "^5.3.0" tar "^4" -node-pre-gyp@^0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.7.0.tgz#55aeffbaed93b50d0a4657d469198cd80ac9df36" - dependencies: - detect-libc "^1.0.2" - mkdirp "^0.5.1" - nopt "^4.0.1" - npmlog "^4.0.2" - rc "^1.1.7" - request "2.83.0" - rimraf "^2.6.1" - semver "^5.3.0" - tar "^2.2.1" - tar-pack "^3.4.0" - nodeify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/nodeify/-/nodeify-1.0.1.tgz#64ab69a7bdbaf03ce107b4f0335c87c0b9e91b1d" @@ -7650,8 +7641,8 @@ object-copy@^0.1.0: kind-of "^3.0.3" object-keys@^1.0.11, object-keys@^1.0.8: - version "1.0.11" - resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.0.11.tgz#c54601778ad560f1142ce0e01bcca8b56d13426d" + version "1.0.12" + resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.0.12.tgz#09c53855377575310cca62f55bb334abff7b3ed2" object-keys@~0.4.0: version "0.4.0" @@ -7689,8 +7680,8 @@ on-finished@~2.3.0: ee-first "1.1.1" on-load@^3.3.4: - version "3.4.0" - resolved "https://registry.yarnpkg.com/on-load/-/on-load-3.4.0.tgz#13ebe3d13852df3d1b2e559bcece659164f40140" + version "3.4.1" + resolved "https://registry.yarnpkg.com/on-load/-/on-load-3.4.1.tgz#e554d0e025f29c8692e91c4c3fcf50d0c2bb9142" dependencies: global "^4.3.2" nanoassert "^1.1.0" @@ -7808,8 +7799,8 @@ p-finally@^1.0.0: resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" p-limit@^1.1.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.2.0.tgz#0e92b6bedcb59f022c13d0f1949dc82d15909f1c" + version "1.3.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.3.0.tgz#b86bd5f0c25690911c7590fcbfc2010d54b3ccb8" dependencies: p-try "^1.0.0" @@ -8062,7 +8053,7 @@ peer-id@~0.11.0: lodash "^4.17.10" multihashes "~0.4.13" -peer-info@^0.14.0, peer-info@^0.14.1, peer-info@~0.14.0, peer-info@~0.14.1: +peer-info@^0.14.0, peer-info@^0.14.1, peer-info@~0.14.1: version "0.14.1" resolved "https://registry.yarnpkg.com/peer-info/-/peer-info-0.14.1.tgz#ac5aec421e9965f7b0e7576d717941bb25676134" dependencies: @@ -8167,6 +8158,10 @@ pkg-up@^1.0.0: dependencies: find-up "^1.0.0" +pkginfo@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/pkginfo/-/pkginfo-0.4.1.tgz#b5418ef0439de5425fc4995042dced14fb2a84ff" + pluralize@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-1.2.1.tgz#d1a21483fd22bb41e58a12fa3421823140897c45" @@ -8244,7 +8239,7 @@ pretty-hrtime@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz#b7e3ea42435a4c9b2759d99e0f201eb195802ee1" -priorityqueue@^0.2.1: +priorityqueue@~0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/priorityqueue/-/priorityqueue-0.2.1.tgz#f57e623f20237f30c142d4cb45fafed9e7d51403" @@ -8347,9 +8342,9 @@ proxy-addr@~2.0.3: forwarded "~0.1.2" ipaddr.js "1.6.0" -proxy-agent@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/proxy-agent/-/proxy-agent-3.0.0.tgz#f6768e202889b2285d39906d3a94768416f8f713" +proxy-agent@^2.0.0: + version "2.3.1" + resolved "https://registry.yarnpkg.com/proxy-agent/-/proxy-agent-2.3.1.tgz#3d49d863d46cf5f37ca8394848346ea02373eac6" dependencies: agent-base "^4.2.0" debug "^3.1.0" @@ -8431,12 +8426,12 @@ pull-handshake@^1.1.4: pull-pushable "^2.0.0" pull-reader "^1.2.3" -pull-length-prefixed@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/pull-length-prefixed/-/pull-length-prefixed-1.3.0.tgz#99f3dac7ea4f896d905f4d2da224460811703a5e" +pull-length-prefixed@^1.3.0, pull-length-prefixed@^1.3.1: + version "1.3.1" + resolved "https://registry.yarnpkg.com/pull-length-prefixed/-/pull-length-prefixed-1.3.1.tgz#32292d44a87f5b2397cb281cf63a64d2da68ea0c" dependencies: pull-pushable "^2.0.1" - pull-reader "^1.2.9" + pull-reader "^1.3.0" safe-buffer "^5.0.1" varint "^5.0.0" @@ -8479,9 +8474,9 @@ pull-pushable@^2.0.0, pull-pushable@^2.0.1, pull-pushable@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/pull-pushable/-/pull-pushable-2.2.0.tgz#5f2f3aed47ad86919f01b12a2e99d6f1bd776581" -pull-reader@^1.2.3, pull-reader@^1.2.9: - version "1.2.9" - resolved "https://registry.yarnpkg.com/pull-reader/-/pull-reader-1.2.9.tgz#d2e9ad00bcfb54e62aa66d42c2dbbcb5eb6843b0" +pull-reader@^1.2.3, pull-reader@^1.3.0: + version "1.3.1" + resolved "https://registry.yarnpkg.com/pull-reader/-/pull-reader-1.3.1.tgz#03a253e37efce111223ea2dc1dec847be1940be6" pull-sort@^1.0.1: version "1.0.1" @@ -8589,11 +8584,11 @@ pushdata-bitcoin@^1.0.1: dependencies: bitcoin-ops "^1.3.0" -qs@6.5.1, qs@~6.5.1: +qs@6.5.1: version "6.5.1" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" -qs@^6.5.2: +qs@^6.5.2, qs@~6.5.1: version "6.5.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" @@ -8650,7 +8645,7 @@ raw-loader@0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/raw-loader/-/raw-loader-0.5.1.tgz#0c3d0beaed8a01c966d9787bf778281252a979aa" -rc@^1.0.1, rc@^1.1.6, rc@^1.1.7: +rc@^1.0.1, rc@^1.1.6, rc@^1.2.7: version "1.2.8" resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.8.tgz#cd924bf5200a075b83c188cd6b9e211b7fc0d3ed" dependencies: @@ -8693,7 +8688,7 @@ readable-stream-node-to-web@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/readable-stream-node-to-web/-/readable-stream-node-to-web-1.0.1.tgz#8b7614faa1465ebfa0da9b9ca6303fa27073b7cf" -"readable-stream@1 || 2", readable-stream@2, readable-stream@2.3.6, readable-stream@^2.0.1, readable-stream@^2.0.4, readable-stream@^2.3.0, readable-stream@^2.3.6: +"readable-stream@1 || 2", readable-stream@2, readable-stream@2.3.6, readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.4, readable-stream@^2.0.5, readable-stream@^2.0.6, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.0, readable-stream@^2.3.3, readable-stream@^2.3.4, readable-stream@^2.3.5, readable-stream@^2.3.6: version "2.3.6" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf" dependencies: @@ -8714,30 +8709,6 @@ readable-stream@1.1.x, readable-stream@^1.0.33: isarray "0.0.1" string_decoder "~0.10.x" -readable-stream@^2.0.0, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.0.6, readable-stream@^2.1.4, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.3, readable-stream@^2.3.4: - version "2.3.4" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.4.tgz#c946c3f47fa7d8eabc0b6150f4a12f69a4574071" - dependencies: - core-util-is "~1.0.0" - inherits "~2.0.3" - isarray "~1.0.0" - process-nextick-args "~2.0.0" - safe-buffer "~5.1.1" - string_decoder "~1.0.3" - util-deprecate "~1.0.1" - -readable-stream@^2.3.5: - version "2.3.5" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.5.tgz#b4f85003a938cbb6ecbce2a124fb1012bd1a838d" - dependencies: - core-util-is "~1.0.0" - inherits "~2.0.3" - isarray "~1.0.0" - process-nextick-args "~2.0.0" - safe-buffer "~5.1.1" - string_decoder "~1.0.3" - util-deprecate "~1.0.1" - readable-stream@~1.0.15: version "1.0.34" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" @@ -8914,34 +8885,7 @@ repeating@^2.0.0: dependencies: is-finite "^1.0.0" -request@2.83.0: - version "2.83.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.83.0.tgz#ca0b65da02ed62935887808e6f510381034e3356" - dependencies: - aws-sign2 "~0.7.0" - aws4 "^1.6.0" - caseless "~0.12.0" - combined-stream "~1.0.5" - extend "~3.0.1" - forever-agent "~0.6.1" - form-data "~2.3.1" - har-validator "~5.0.3" - hawk "~6.0.2" - http-signature "~1.2.0" - is-typedarray "~1.0.0" - isstream "~0.1.2" - json-stringify-safe "~5.0.1" - mime-types "~2.1.17" - oauth-sign "~0.8.2" - performance-now "^2.1.0" - qs "~6.5.1" - safe-buffer "^5.1.1" - stringstream "~0.0.5" - tough-cookie "~2.3.3" - tunnel-agent "^0.6.0" - uuid "^3.1.0" - -request@2.87.0, request@^2.83.0: +request@2.87.0, request@^2.83.0, request@^2.87.0: version "2.87.0" resolved "https://registry.yarnpkg.com/request/-/request-2.87.0.tgz#32f00235cd08d482b4d0d68db93a829c0ed5756e" dependencies: @@ -9030,15 +8974,9 @@ resolve-url@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" -resolve@^1.1.6: - version "1.5.0" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.5.0.tgz#1f09acce796c9a762579f31b2c1cc4c3cddf9f36" - dependencies: - path-parse "^1.0.5" - -resolve@^1.1.7: - version "1.7.1" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.7.1.tgz#aadd656374fd298aee895bc026b8297418677fd3" +resolve@^1.1.6, resolve@^1.1.7: + version "1.8.1" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.8.1.tgz#82f1ec19a423ac1fbd080b0bab06ba36e84a7a26" dependencies: path-parse "^1.0.5" @@ -9066,7 +9004,7 @@ right-align@^0.1.1: dependencies: align-text "^0.1.1" -rimraf@2, rimraf@^2.2.8, rimraf@^2.5.1, rimraf@^2.5.4, rimraf@^2.6.1, rimraf@^2.6.2: +rimraf@^2.2.8, rimraf@^2.5.4, rimraf@^2.6.1, rimraf@^2.6.2: version "2.6.2" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.2.tgz#2ed8150d24a16ea8651e6d6ef0f47c4158ce7a36" dependencies: @@ -9090,8 +9028,10 @@ ripemd160@^2.0.0, ripemd160@^2.0.1: inherits "^2.0.1" rlp@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/rlp/-/rlp-2.0.0.tgz#9db384ff4b89a8f61563d92395d8625b18f3afb0" + version "2.1.0" + resolved "https://registry.yarnpkg.com/rlp/-/rlp-2.1.0.tgz#e4f9886d5a982174f314543831e36e1a658460f9" + dependencies: + safe-buffer "^5.1.1" rsa-pem-to-jwk@^1.1.3: version "1.1.3" @@ -9143,16 +9083,16 @@ rx-lite@^3.1.2: resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-3.1.2.tgz#19ce502ca572665f3b647b10939f97fd1615f102" rxjs@^6.1.0: - version "6.2.0" - resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.2.0.tgz#e024d0e180b72756a83c2aaea8f25423751ba978" + version "6.2.2" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.2.2.tgz#eb75fa3c186ff5289907d06483a77884586e1cf9" dependencies: tslib "^1.9.0" -safe-buffer@5.1.1, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: +safe-buffer@5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" -safe-buffer@^5.1.2: +safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@^5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.2" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" @@ -9166,7 +9106,7 @@ safe-regex@^1.1.0: dependencies: ret "~0.1.10" -"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.1.0: +"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" @@ -9375,8 +9315,10 @@ shellwords@^0.1.1: resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b" shortid@^2.2.8: - version "2.2.8" - resolved "https://registry.yarnpkg.com/shortid/-/shortid-2.2.8.tgz#033b117d6a2e975804f6f0969dbe7d3d0b355131" + version "2.2.12" + resolved "https://registry.yarnpkg.com/shortid/-/shortid-2.2.12.tgz#8e9a95ffbc671fff8f09e985dbc7874102b0cfd2" + dependencies: + nanoid "^1.0.7" shot@^3.4.2: version "3.4.2" @@ -9546,6 +9488,16 @@ snyk-config@2.1.0: debug "^3.1.0" nconf "^0.10.0" +snyk-docker-plugin@1.10.3: + version "1.10.3" + resolved "https://registry.yarnpkg.com/snyk-docker-plugin/-/snyk-docker-plugin-1.10.3.tgz#2ac2f05ab821e122a5e1851240d3c021bbb8223f" + dependencies: + debug "^3.1.0" + fs-extra "^5.0.0" + pkginfo "^0.4.1" + request "^2.87.0" + temp-dir "^1.0.0" + snyk-go-plugin@1.5.1: version "1.5.1" resolved "https://registry.yarnpkg.com/snyk-go-plugin/-/snyk-go-plugin-1.5.1.tgz#220016f2dc51e1f5fe8efe496049039ad3f03010" @@ -9571,9 +9523,9 @@ snyk-mvn-plugin@1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/snyk-mvn-plugin/-/snyk-mvn-plugin-1.2.0.tgz#e23c60e35457ce5a26fd4252ddf120dbd7e9ef2a" -snyk-nuget-plugin@1.6.2: - version "1.6.2" - resolved "https://registry.yarnpkg.com/snyk-nuget-plugin/-/snyk-nuget-plugin-1.6.2.tgz#ea21181be53c1e7c9183907c25a71d914c5888b9" +snyk-nuget-plugin@1.6.3: + version "1.6.3" + resolved "https://registry.yarnpkg.com/snyk-nuget-plugin/-/snyk-nuget-plugin-1.6.3.tgz#841a754d5b8d6eee8744e2f842d3fa5e07a9b602" dependencies: debug "^3.1.0" es6-promise "^4.1.1" @@ -9647,9 +9599,9 @@ snyk-tree@^1.0.0: dependencies: archy "^1.0.0" -snyk-try-require@1.3.0, snyk-try-require@^1.1.1: - version "1.3.0" - resolved "https://registry.yarnpkg.com/snyk-try-require/-/snyk-try-require-1.3.0.tgz#f35706acf91c8af788d58e1f1ad6bf0fcf6c5493" +snyk-try-require@1.3.1, snyk-try-require@^1.1.1: + version "1.3.1" + resolved "https://registry.yarnpkg.com/snyk-try-require/-/snyk-try-require-1.3.1.tgz#6e026f92e64af7fcccea1ee53d524841e418a212" dependencies: debug "^3.1.0" lodash.clonedeep "^4.3.0" @@ -9657,8 +9609,8 @@ snyk-try-require@1.3.0, snyk-try-require@^1.1.1: then-fs "^2.0.0" snyk@^1.78.1: - version "1.82.0" - resolved "https://registry.yarnpkg.com/snyk/-/snyk-1.82.0.tgz#eeeb8187dbd79af59a5c608f1d1ce35deee27b9c" + version "1.89.0" + resolved "https://registry.yarnpkg.com/snyk/-/snyk-1.89.0.tgz#254fa9bef8bbf0e1d5b10540312fcce4aa71507c" dependencies: abbrev "^1.1.1" ansi-escapes "^3.1.0" @@ -9671,16 +9623,17 @@ snyk@^1.78.1: needle "^2.0.1" opn "^5.2.0" os-name "^2.0.1" - proxy-agent "^3.0.0" + proxy-agent "^2.0.0" proxy-from-env "^1.0.0" recursive-readdir "^2.2.2" semver "^5.5.0" snyk-config "2.1.0" + snyk-docker-plugin "1.10.3" snyk-go-plugin "1.5.1" snyk-gradle-plugin "1.3.0" snyk-module "1.8.2" snyk-mvn-plugin "1.2.0" - snyk-nuget-plugin "1.6.2" + snyk-nuget-plugin "1.6.3" snyk-php-plugin "1.5.1" snyk-policy "1.12.0" snyk-python-plugin "1.6.1" @@ -9688,7 +9641,7 @@ snyk@^1.78.1: snyk-resolve-deps "3.1.0" snyk-sbt-plugin "1.3.0" snyk-tree "^1.0.0" - snyk-try-require "1.3.0" + snyk-try-require "1.3.1" tempfile "^2.0.0" then-fs "^2.0.0" undefsafe "^2.0.0" @@ -9785,7 +9738,7 @@ source-map-support@0.5.3: dependencies: source-map "^0.6.0" -source-map-support@0.5.6, source-map-support@~0.5.4: +source-map-support@0.5.6, source-map-support@~0.5.4, source-map-support@~0.5.6: version "0.5.6" resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.6.tgz#4435cee46b1aab62b8e8610ce60f788091c51c13" dependencies: @@ -9891,13 +9844,14 @@ sprintf-js@~1.0.2: resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" sshpk@^1.7.0: - version "1.14.1" - resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.14.1.tgz#130f5975eddad963f1d56f92b9ac6c51fa9f83eb" + version "1.14.2" + resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.14.2.tgz#c6fc61648a3d9c4e764fd3fcdf4ea105e492ba98" dependencies: asn1 "~0.2.3" assert-plus "^1.0.0" dashdash "^1.12.0" getpass "^0.1.1" + safer-buffer "^2.0.2" optionalDependencies: bcrypt-pbkdf "^1.0.0" ecc-jsbn "~0.1.1" @@ -9910,10 +9864,6 @@ ssri@^5.2.4: dependencies: safe-buffer "^5.1.1" -stable@0.1.6: - version "0.1.6" - resolved "https://registry.yarnpkg.com/stable/-/stable-0.1.6.tgz#910f5d2aed7b520c6e777499c1f32e139fdecb10" - stable@~0.1.8: version "0.1.8" resolved "https://registry.yarnpkg.com/stable/-/stable-0.1.8.tgz#836eb3c8382fe2936feaf544631017ce7d47a3cf" @@ -10069,12 +10019,6 @@ string_decoder@~0.10.x: version "0.10.31" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" -string_decoder@~1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.0.3.tgz#0fc67d7c141825de94282dd536bec6b9bce860ab" - dependencies: - safe-buffer "~5.1.0" - stringify-entities@^1.0.1: version "1.3.2" resolved "https://registry.yarnpkg.com/stringify-entities/-/stringify-entities-1.3.2.tgz#a98417e5471fd227b3e45d3db1861c11caf668f7" @@ -10167,7 +10111,7 @@ supports-color@3.1.2: dependencies: has-flag "^1.0.0" -supports-color@5.4.0, supports-color@^5.4.0: +supports-color@5.4.0, supports-color@^5.1.0, supports-color@^5.2.0, supports-color@^5.3.0, supports-color@^5.4.0: version "5.4.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54" dependencies: @@ -10183,18 +10127,6 @@ supports-color@^3.1.2: dependencies: has-flag "^1.0.0" -supports-color@^5.1.0, supports-color@^5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.2.0.tgz#b0d5333b1184dd3666cbe5aa0b45c5ac7ac17a4a" - dependencies: - has-flag "^3.0.0" - -supports-color@^5.3.0: - version "5.3.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.3.0.tgz#5b24ac15db80fa927cf5227a4a33fd3c4c7676c0" - dependencies: - has-flag "^3.0.0" - table@4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/table/-/table-4.0.2.tgz#a33447375391e766ad34d3486e6e2aedc84d2e36" @@ -10226,27 +10158,14 @@ tapable@^1.0.0: resolved "https://registry.yarnpkg.com/tapable/-/tapable-1.0.0.tgz#cbb639d9002eed9c6b5975eb20598d7936f1f9f2" tar-fs@^1.13.0: - version "1.16.2" - resolved "https://registry.yarnpkg.com/tar-fs/-/tar-fs-1.16.2.tgz#17e5239747e399f7e77344f5f53365f04af53577" + version "1.16.3" + resolved "https://registry.yarnpkg.com/tar-fs/-/tar-fs-1.16.3.tgz#966a628841da2c4010406a82167cbd5e0c72d509" dependencies: chownr "^1.0.1" mkdirp "^0.5.1" pump "^1.0.0" tar-stream "^1.1.2" -tar-pack@^3.4.0: - version "3.4.1" - resolved "https://registry.yarnpkg.com/tar-pack/-/tar-pack-3.4.1.tgz#e1dbc03a9b9d3ba07e896ad027317eb679a10a1f" - dependencies: - debug "^2.2.0" - fstream "^1.0.10" - fstream-ignore "^1.0.5" - once "^1.3.3" - readable-stream "^2.1.4" - rimraf "^2.5.1" - tar "^2.2.1" - uid-number "^0.0.6" - tar-stream@^1.1.2, tar-stream@^1.5.0, tar-stream@^1.6.1: version "1.6.1" resolved "https://registry.yarnpkg.com/tar-stream/-/tar-stream-1.6.1.tgz#f84ef1696269d6223ca48f6e1eeede3f7e81f395" @@ -10259,14 +10178,6 @@ tar-stream@^1.1.2, tar-stream@^1.5.0, tar-stream@^1.6.1: to-buffer "^1.1.0" xtend "^4.0.0" -tar@^2.2.1: - version "2.2.1" - resolved "https://registry.yarnpkg.com/tar/-/tar-2.2.1.tgz#8e4d2a256c0e2185c6b18ad694aec968b83cb1d1" - dependencies: - block-stream "*" - fstream "^1.0.2" - inherits "2" - tar@^4: version "4.4.4" resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.4.tgz#ec8409fae9f665a4355cc3b4087d0820232bb8cd" @@ -10309,6 +10220,15 @@ term-size@^1.2.0: dependencies: execa "^0.7.0" +terser@3.8.0, uglify-es@^3.3.4, "uglify-es@npm:terser": + name uglify-es + version "3.8.0" + resolved "https://registry.yarnpkg.com/terser/-/terser-3.8.0.tgz#66a4f4f500d2c829faab840f318c49cc471d73ae" + dependencies: + commander "~2.16.0" + source-map "~0.6.1" + source-map-support "~0.5.6" + test-exclude@^4.2.0: version "4.2.1" resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-4.2.1.tgz#dfa222f03480bca69207ca728b37d74b45f724fa" @@ -10461,8 +10381,8 @@ tosource@1.0.0: resolved "https://registry.yarnpkg.com/tosource/-/tosource-1.0.0.tgz#42d88dd116618bcf00d6106dd5446f3427902ff1" tough-cookie@~2.3.3: - version "2.3.3" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.3.tgz#0b618a5565b6dea90bf3425d04d55edc475a7561" + version "2.3.4" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.4.tgz#ec60cee38ac675063ffc97a5c18970578ee83655" dependencies: punycode "^1.4.1" @@ -10521,12 +10441,12 @@ truncate-utf8-bytes@^1.0.0: utf8-byte-length "^1.0.1" tryer@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/tryer/-/tryer-1.0.0.tgz#027b69fa823225e551cace3ef03b11f6ab37c1d7" + version "1.0.1" + resolved "https://registry.yarnpkg.com/tryer/-/tryer-1.0.1.tgz#f2c85406800b9b0f74c9f7465b81eaad241252f8" tslib@^1.9.0: - version "1.9.2" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.2.tgz#8be0cc9a1f6dc7727c38deb16c2ebd1a2892988e" + version "1.9.3" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.3.tgz#d7e4dd79245d85428c4d7e4822a79917954ca286" tty-browserify@0.0.0: version "0.0.0" @@ -10577,13 +10497,6 @@ typeforce@^1.11.3: version "1.12.0" resolved "https://registry.yarnpkg.com/typeforce/-/typeforce-1.12.0.tgz#ca40899919f1466d7819e37be039406beb912a2e" -uglify-es@^3.3.4: - version "3.3.9" - resolved "https://registry.yarnpkg.com/uglify-es/-/uglify-es-3.3.9.tgz#0c1c4f0700bed8dbc124cdb304d2592ca203e677" - dependencies: - commander "~2.13.0" - source-map "~0.6.1" - uglify-js@^2.6: version "2.8.29" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.8.29.tgz#29c5733148057bb4e1f75df35b7a9cb72e6a59dd" @@ -10598,8 +10511,8 @@ uglify-to-browserify@~1.0.0: resolved "https://registry.yarnpkg.com/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz#6e0924d6bda6b5afe349e39a6d632850a0f882b7" uglifyjs-webpack-plugin@^1.2.4: - version "1.2.5" - resolved "https://registry.yarnpkg.com/uglifyjs-webpack-plugin/-/uglifyjs-webpack-plugin-1.2.5.tgz#2ef8387c8f1a903ec5e44fa36f9f3cbdcea67641" + version "1.2.7" + resolved "https://registry.yarnpkg.com/uglifyjs-webpack-plugin/-/uglifyjs-webpack-plugin-1.2.7.tgz#57638dd99c853a1ebfe9d97b42160a8a507f9d00" dependencies: cacache "^10.0.4" find-cache-dir "^1.0.0" @@ -10610,10 +10523,6 @@ uglifyjs-webpack-plugin@^1.2.4: webpack-sources "^1.1.0" worker-farm "^1.5.2" -uid-number@^0.0.6: - version "0.0.6" - resolved "https://registry.yarnpkg.com/uid-number/-/uid-number-0.0.6.tgz#0ea10e8035e8eb5b8e4449f06da1c730663baa81" - ultron@1.0.x: version "1.0.2" resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.0.2.tgz#ace116ab557cd197386a4e88f4685378c8b2e4fa" @@ -10702,8 +10611,8 @@ unist-util-visit@^1.1.0: unist-util-is "^2.1.1" universalify@^0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.1.tgz#fa71badd4437af4c148841e3b3b165f9e9e590b7" + version "0.1.2" + resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66" unpipe@1.0.0, unpipe@~1.0.0: version "1.0.0" @@ -10724,7 +10633,7 @@ upath@1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/upath/-/upath-1.0.5.tgz#02cab9ecebe95bbec6d5fc2566325725ab6d1a73" -upath@^1.0.0: +upath@^1.0.5: version "1.1.0" resolved "https://registry.yarnpkg.com/upath/-/upath-1.1.0.tgz#35256597e46a581db4793d0ce47fa9aebfc9fabd" @@ -10793,10 +10702,8 @@ url@^0.11.0: querystring "0.2.0" use@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/use/-/use-3.1.0.tgz#14716bf03fdfefd03040aef58d8b4b85f3a7c544" - dependencies: - kind-of "^6.0.2" + version "3.1.1" + resolved "https://registry.yarnpkg.com/use/-/use-3.1.1.tgz#d50c8cac79a19fbc20f2911f56eb973f4e10070f" user-home@^2.0.0: version "2.0.0" @@ -10812,19 +10719,25 @@ util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" -util@0.10.3, util@^0.10.3: +util@0.10.3: version "0.10.3" resolved "https://registry.yarnpkg.com/util/-/util-0.10.3.tgz#7afb1afe50805246489e3db7fe0ed379336ac0f9" dependencies: inherits "2.0.1" +util@^0.10.3: + version "0.10.4" + resolved "https://registry.yarnpkg.com/util/-/util-0.10.4.tgz#3aa0125bfe668a4672de58857d3ace27ecb76901" + dependencies: + inherits "2.0.3" + utils-merge@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/utils-merge/-/utils-merge-1.0.1.tgz#9f95710f50a267947b2ccc124741c1028427e713" uuid@^3.0.0, uuid@^3.0.1, uuid@^3.1.0, uuid@^3.2.1: - version "3.2.1" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.2.1.tgz#12c528bb9d58d0b9265d9a2f6f0fe8be17ff1f14" + version "3.3.2" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" v8-compile-cache@^2.0.0: version "2.0.0" @@ -10980,9 +10893,9 @@ webpack-bundle-analyzer@2.13.1: opener "^1.4.3" ws "^4.0.0" -webpack-cli@3.0.8: - version "3.0.8" - resolved "https://registry.yarnpkg.com/webpack-cli/-/webpack-cli-3.0.8.tgz#90eddcf04a4bfc31aa8c0edc4c76785bc4f1ccd9" +webpack-cli@3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/webpack-cli/-/webpack-cli-3.1.0.tgz#d71a83687dcfeb758fdceeb0fe042f96bcf62994" dependencies: chalk "^2.4.1" cross-spawn "^6.0.5" @@ -10994,7 +10907,7 @@ webpack-cli@3.0.8: loader-utils "^1.1.0" supports-color "^5.4.0" v8-compile-cache "^2.0.0" - yargs "^11.1.0" + yargs "^12.0.1" webpack-merge@4.1.3: version "4.1.3" @@ -11009,22 +10922,22 @@ webpack-sources@^1.0.1, webpack-sources@^1.1.0: source-list-map "^2.0.0" source-map "~0.6.1" -webpack@4.14.0: - version "4.14.0" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.14.0.tgz#bbcc40dbf9a34129491b431574189d3802972243" +webpack@4.16.1: + version "4.16.1" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.16.1.tgz#2c4b89ea648125c3e67bcca6adf49ce2c14b2d31" dependencies: - "@webassemblyjs/ast" "1.5.12" - "@webassemblyjs/helper-module-context" "1.5.12" - "@webassemblyjs/wasm-edit" "1.5.12" - "@webassemblyjs/wasm-opt" "1.5.12" - "@webassemblyjs/wasm-parser" "1.5.12" + "@webassemblyjs/ast" "1.5.13" + "@webassemblyjs/helper-module-context" "1.5.13" + "@webassemblyjs/wasm-edit" "1.5.13" + "@webassemblyjs/wasm-opt" "1.5.13" + "@webassemblyjs/wasm-parser" "1.5.13" acorn "^5.6.2" acorn-dynamic-import "^3.0.0" ajv "^6.1.0" ajv-keywords "^3.1.0" chrome-trace-event "^1.0.0" enhanced-resolve "^4.1.0" - eslint-scope "^3.7.1" + eslint-scope "^4.0.0" json-parse-better-errors "^1.0.2" loader-runner "^2.3.0" loader-utils "^1.1.0" @@ -11313,7 +11226,7 @@ yargs@11.0.0, yargs@~11.0.0: y18n "^3.2.1" yargs-parser "^9.0.2" -yargs@11.1.0, yargs@^11.1.0: +yargs@11.1.0: version "11.1.0" resolved "https://registry.yarnpkg.com/yargs/-/yargs-11.1.0.tgz#90b869934ed6e871115ea2ff58b03f4724ed2d77" dependencies: @@ -11397,7 +11310,7 @@ yeast@0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/yeast/-/yeast-0.1.2.tgz#008e06d8094320c372dbc2f8ed76a0ca6c8ac419" -zcash-bitcore-lib@^0.13.20-rc3: +zcash-bitcore-lib@~0.13.20-rc3: version "0.13.20-rc3" resolved "https://registry.yarnpkg.com/zcash-bitcore-lib/-/zcash-bitcore-lib-0.13.20-rc3.tgz#813a0f56dcf8b76bc1429951bea6d1236c507008" dependencies: From dd870ee6feb839b63f3e1b0f4ddfde3016ada889 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Sun, 22 Jul 2018 17:29:48 +0200 Subject: [PATCH 07/31] fix: basic error handling for libdweb protocol --- add-on/src/lib/ipfs-protocol-libdweb.js | 48 +++++++++++++------------ 1 file changed, 25 insertions(+), 23 deletions(-) diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 97ec7e60c..05fd331b2 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -29,7 +29,7 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { // TODO: // - detect invalid addrs and display error page // - support streaming - content: streamRespond(ipfs, path) + content: streamRespond(ipfs, path, request) } } catch (err) { console.error('[ipfs-companion] failed to get data for ' + request.url, err) @@ -39,11 +39,16 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { } } -async function * streamRespond (ipfs, path) { - const response = await getResponse(ipfs, path) +async function * streamRespond (ipfs, path, request) { + let response + try { + response = await getResponse(ipfs, path) + } catch (error) { + yield toErrorResponse(request, error) + return + } if (isStream(response)) { for await (const chunk of asyncIterateStream(response, false)) { - // for await (const chunk of new S2A(response)) { // Buffer to ArrayBuffer yield toArrayBuffer(chunk) } @@ -53,19 +58,24 @@ async function * streamRespond (ipfs, path) { } } -/* -function toAsyncIterator(stream) { - // console.log('toAsyncIterator.stream', stream) - //const s2a = new S2A(stream) - const s2a = asyncIterateStream(stream, false) - // console.log('toAsyncIterator.s2a', s2a) - return s2a +// Prepare response with a meaningful error +function toErrorResponse (request, error) { + console.error(`IPFS Error while getting response for ${request.url}`, error) + // TODO + // - create proper error page + // - find a way to communicate common errors (eg. not found, invalid CID, timeout) + const textBuffer = text => new TextEncoder('utf-8').encode(text).buffer + if (error.message === 'file does not exist') { + // eg. when trying to access a non-existing file in a directory (basically http 404) + return textBuffer('Not found') + } else if (error.message === 'selected encoding not supported') { + // eg. when trying to access invalid CID + return textBuffer('IPFS Error: selected encoding is not supported in browser context. Make sure your CID is a valid CIDv1 in Base32.') + } + return textBuffer(`Unable to produce IPFS response for "${request.url}": ${error}`) } -*/ async function getResponse (ipfs, path) { - let listing - // We're using ipfs.ls to figure out if a path is a file or a directory. // // If the listing is empty then it's (likely) a file @@ -82,15 +92,7 @@ async function getResponse (ipfs, path) { // // The second alternative would be to resolve the path ourselves using the // object API, but that could take a while for long paths. - try { - listing = await ipfs.ls(path) - } catch (err) { - if (err.message === 'file does not exist') { - // eg. when trying to access a non-existing file in a directory - return new TextEncoder('utf-8').encode('Not found').buffer - } - throw err - } + const listing = await ipfs.ls(path) if (isDirectory(listing)) { return getDirectoryListingOrIndexResponse(ipfs, path, listing) From 1d814f7b64d09d6bbd81577132b49f23265f5788 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Thu, 2 Aug 2018 11:56:57 -0700 Subject: [PATCH 08/31] PoC IPNS support --- add-on/src/lib/ipfs-companion.js | 1 + add-on/src/lib/ipfs-protocol-libdweb.js | 30 ++++++++++++++++++++----- 2 files changed, 26 insertions(+), 5 deletions(-) diff --git a/add-on/src/lib/ipfs-companion.js b/add-on/src/lib/ipfs-companion.js index 463b97b03..82c1548ec 100644 --- a/add-on/src/lib/ipfs-companion.js +++ b/add-on/src/lib/ipfs-companion.js @@ -107,6 +107,7 @@ module.exports = async function init () { console.log('[ipfs-companion] registerProtocol from mozilla/libdweb is available. Adding ipfs:// handler') const { createIpfsUrlProtocolHandler } = require('./ipfs-protocol-libdweb') browser.protocol.registerProtocol('ipfs', createIpfsUrlProtocolHandler(() => ipfs)) + browser.protocol.registerProtocol('ipns', createIpfsUrlProtocolHandler(() => ipfs)) } else { console.log('[ipfs-companion] browser.protocol.registerStringProtocol not available, native protocol will not be registered') } diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 05fd331b2..608b0d040 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -14,11 +14,18 @@ const isStream = require('is-stream') exports.createIpfsUrlProtocolHandler = (getIpfs) => { return request => { - console.time('[ipfs-companion] IpfsUrlProtocolHandler') + console.time('[ipfs-companion] LibdwebProtocolHandler') console.log(`[ipfs-companion] handling ${request.url}`) - let path = request.url.replace('ipfs://', '/') - path = path.startsWith('/ipfs') ? path : `/ipfs${path}` + let path + if (request.url.startsWith('ipfs:')) { + path = request.url.replace('ipfs://', '/') + path = path.startsWith('/ipfs') ? path : `/ipfs${path}` + } else if (request.url.startsWith('ipns:')) { + path = request.url.replace('ipns://', '/') + path = path.startsWith('/ipns') ? path : `/ipns${path}` + } + const ipfs = getIpfs() try { @@ -35,7 +42,7 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { console.error('[ipfs-companion] failed to get data for ' + request.url, err) } - console.timeEnd('[ipfs-companion] IpfsUrlProtocolHandler') + console.timeEnd('[ipfs-companion] LibdwebProtocolHandler') } } @@ -76,6 +83,12 @@ function toErrorResponse (request, error) { } async function getResponse (ipfs, path) { + // TODO: move IPNS resolv just before cat, so that directory listing uses correct protocol + if (path.startsWith('/ipns/')) { + const response = await ipfs.name.resolve(path, {recursive: true, nocache: false}) + path = response.Path ? response.Path : response + } + // We're using ipfs.ls to figure out if a path is a file or a directory. // // If the listing is empty then it's (likely) a file @@ -134,6 +147,13 @@ function getDirectoryListingOrIndexResponse (ipfs, path, listing) { */ return ipfs.files.catReadableStream(PathUtils.joinURLParts(path, index.name)) } - const response = dirView.render(path.replace(/^\/ipfs\//, 'ipfs://'), listing) + + // TODO: deuglify ;-) + if (path.startsWith('/ipfs/')) { + path = path.replace(/^\/ipfs\//, 'ipfs://') + } else if (path.startsWith('/ipns/')) { + path = path.replace(/^\/ipns\//, 'ipns://') + } + const response = dirView.render(path, listing) return new TextEncoder('utf-8').encode(response).buffer } From 2ddf9eaa51dd1a6f6dafc90eb59bec17853e60af Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Thu, 2 Aug 2018 14:19:59 -0700 Subject: [PATCH 09/31] docs: simplified libdweb dev notes --- docs/libdweb.md | 30 ++++++++++++++++-------------- package.json | 4 ++-- 2 files changed, 18 insertions(+), 16 deletions(-) diff --git a/docs/libdweb.md b/docs/libdweb.md index 36ad3e16e..a5cbd2ab2 100644 --- a/docs/libdweb.md +++ b/docs/libdweb.md @@ -11,13 +11,15 @@ See also: ## TL;DR -1. Having `firefox-nightly` in `$PATH`, execute commands below to build and run Companion extension in libdweb-enabled context: +1. Having `firefox-nightly` in `$PATH`, execute commands below to checkout, build and run Companion extension in libdweb-enabled context: ``` - yarn libdweb + git clone -b libdweb --recurse-submodules --depth 1 https://github.com/ipfs-shipyard/ipfs-companion.git + npm run libdweb ``` 2. Optional Smoke-Test: - Open `ipfs://bafkreickb4yq3sr3q2xqn3z3wzimilsa4wkbx25azqbvcnihq65moyjcvi` + - Open `ipns://docs.ipfs.io` - Confirm `ipfs://` protocol remains in Location Bar ([example](https://ipfs.io/ipfs/bafybeie5gq4jxvzmsym6hjlwxej4rwdoxt7wadqvmmwbqi7r27fclha2va)) ## Developer Notes @@ -28,22 +30,21 @@ See also: - Get latest Nightly from http://nightly.mozilla.org/ - libdweb won't run in regular release, it has to be nightly or developer edition -### Build libdweb-enabled bundle +### How to Build and run libdweb-enabled bundle ``` -git submodule update --init --checkout --depth 1 libdweb -yarn -yarn build -yarn libdweb:bundle -``` +# checkout libdweb branch into a new directory +# including submodules (namely ./libdweb) +git clone -b libdweb --recurse-submodules --depth 1 https://github.com/ipfs-shipyard/ipfs-companion.git -or use all-in-one alias: -``` -yarn libdweb:build -``` +# install deps and build +npm run libdweb:build +# run (assumes firefox-nightly on PATH) +npm run libdweb:firefox +``` -### Deploy in Firefox with libdweb APIs ✂️ +### Manually Deploy in Firefox with libdweb APIs ✂️ To run your extension in libdweb context: @@ -55,7 +56,7 @@ web-ext run --firefox=/path/to/nightly/firefox-bin --browser-console --url about or use alias: ``` -yarn libdweb:firefox +npm run libdweb:firefox ``` @@ -70,6 +71,7 @@ Additional notes: #### Protocol Handler API 1. Open `ipfs://bafkreickb4yq3sr3q2xqn3z3wzimilsa4wkbx25azqbvcnihq65moyjcvi` +1. Open `ipns://docs.ipfs.io` 1. Confirm `ipfs://` protocol remains in Location Bar ([example](https://ipfs.io/ipfs/bafybeie5gq4jxvzmsym6hjlwxej4rwdoxt7wadqvmmwbqi7r27fclha2va)) ## References diff --git a/package.json b/package.json index f1e0ab245..220ef1d77 100644 --- a/package.json +++ b/package.json @@ -42,10 +42,10 @@ "precommit": "run-s lint:standard", "prepush": "run-s clean build lint test", "firefox": "web-ext run --browser-console", - "libdweb": "run-s libdweb:build libdweb:firefox ", + "libdweb": "npm run libdweb:build && npm run libdweb:firefox", "libdweb:build": "git submodule update --init --checkout --depth 1 libdweb && npm run dev-build && npm run libdweb:bundle", "libdweb:bundle": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-libdweb.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/libdweb/", - "libdweb:firefox": "run-s libdweb:bundle && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=nightly --browser-console --url about:debugging", + "libdweb:firefox": "npx run-s libdweb:bundle && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=nightly --browser-console --url about:debugging", "ci": "run-s ci:*", "ci:install": "npx yarn@1.7.0 install --frozen-lockfile || npx yarn@1.7.0 install --frozen-lockfile", "ci:test": "npx yarn@1.7.0 test", From 252776a1325a68fe527fdf6eae44f56eed5a1155 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Thu, 2 Aug 2018 15:35:12 -0700 Subject: [PATCH 10/31] fix: make ipns:// work with embedded js-ipfs js-ipfs does not support IPNS yet, but it has ipfs.dns API for dnslink lookup, which actually all we need --- add-on/src/lib/ipfs-protocol-libdweb.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 608b0d040..e22265367 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -85,7 +85,9 @@ function toErrorResponse (request, error) { async function getResponse (ipfs, path) { // TODO: move IPNS resolv just before cat, so that directory listing uses correct protocol if (path.startsWith('/ipns/')) { - const response = await ipfs.name.resolve(path, {recursive: true, nocache: false}) + // const response = await ipfs.name.resolve(path, {recursive: true, nocache: false}) + const fqdn = path.replace(/^\/ipns\//, '') + const response = await ipfs.dns(fqdn) path = response.Path ? response.Path : response } From 3378c1ade5d6d17bb307196568fb37817e218319 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Thu, 2 Aug 2018 15:51:28 -0700 Subject: [PATCH 11/31] fix: meaningful error when global toggle is off --- add-on/src/lib/ipfs-companion.js | 4 ++-- add-on/src/lib/ipfs-protocol-libdweb.js | 7 +++---- web-ext-config.js | 1 + 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/add-on/src/lib/ipfs-companion.js b/add-on/src/lib/ipfs-companion.js index 82c1548ec..8537b1ece 100644 --- a/add-on/src/lib/ipfs-companion.js +++ b/add-on/src/lib/ipfs-companion.js @@ -106,8 +106,8 @@ module.exports = async function init () { } else if (runtime.hasNativeProtocolHandler && browser.protocol.registerProtocol) { console.log('[ipfs-companion] registerProtocol from mozilla/libdweb is available. Adding ipfs:// handler') const { createIpfsUrlProtocolHandler } = require('./ipfs-protocol-libdweb') - browser.protocol.registerProtocol('ipfs', createIpfsUrlProtocolHandler(() => ipfs)) - browser.protocol.registerProtocol('ipns', createIpfsUrlProtocolHandler(() => ipfs)) + browser.protocol.registerProtocol('ipfs', createIpfsUrlProtocolHandler(getIpfs)) + browser.protocol.registerProtocol('ipns', createIpfsUrlProtocolHandler(getIpfs)) } else { console.log('[ipfs-companion] browser.protocol.registerStringProtocol not available, native protocol will not be registered') } diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index e22265367..5933e0e4c 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -26,8 +26,6 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { path = path.startsWith('/ipns') ? path : `/ipns${path}` } - const ipfs = getIpfs() - try { return { // Notes: @@ -36,7 +34,7 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { // TODO: // - detect invalid addrs and display error page // - support streaming - content: streamRespond(ipfs, path, request) + content: streamRespond(getIpfs, path, request) } } catch (err) { console.error('[ipfs-companion] failed to get data for ' + request.url, err) @@ -46,9 +44,10 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { } } -async function * streamRespond (ipfs, path, request) { +async function * streamRespond (getIpfs, path, request) { let response try { + const ipfs = getIpfs() response = await getResponse(ipfs, path) } catch (error) { yield toErrorResponse(request, error) diff --git a/web-ext-config.js b/web-ext-config.js index 9a495f5c2..e062fbff6 100644 --- a/web-ext-config.js +++ b/web-ext-config.js @@ -6,6 +6,7 @@ module.exports = { sourceDir: 'add-on/', ignoreFiles: [ 'src/', + 'libdweb/', 'manifest.*.json' ], // Command options: From c4881204444c652f9cecc05a8c79f16ad67254a9 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 3 Aug 2018 10:49:42 -0700 Subject: [PATCH 12/31] feat(libdweb): download nightly if missing --- .gitignore | 2 +- package.json | 18 +- yarn.lock | 473 +++++++++++++++++++++++++++++++++++++++++++++++++-- 3 files changed, 468 insertions(+), 25 deletions(-) diff --git a/.gitignore b/.gitignore index 1e8aed7e8..452eaf2b0 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,7 @@ vendor node_modules package-lock.json -./firefox/ +firefox cache build npm-debug.log diff --git a/package.json b/package.json index 220ef1d77..e35159021 100644 --- a/package.json +++ b/package.json @@ -24,11 +24,14 @@ "build:js": "run-p build:js:*", "build:js:webpack": "webpack -p", "build:minimize-dist": "shx rm -rf add-on/dist/lib add-on/dist/contentScripts/ add-on/dist/bundles/ipfsProxyContentScriptPayload.bundle.js", - "build:bundle-all": "RELEASE_CHANNEL=${RELEASE_CHANNEL:=dev} run-s bundle:generic && cross-env-shell test \"$RELEASE_CHANNEL\" = \"beta\" && run-s bundle:firefox:beta || run-s bundle:firefox", + "build:bundle-all": "RELEASE_CHANNEL=${RELEASE_CHANNEL:=dev} npm run bundle:generic && cross-env-shell npm run bundle:firefox:$RELEASE_CHANNEL", "bundle": "run-s bundle:*", "bundle:generic": "shx cp add-on/manifest.common.json add-on/manifest.json && web-ext build -a build/generic", "bundle:firefox": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/", + "bundle:firefox:dev": "npm run bundle:firefox", + "bundle:firefox:release": "npm run bundle:firefox", "bundle:firefox:beta": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-beta.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/beta/", + "bundle:firefox:libdweb": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-libdweb.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/libdweb/", "watch": "npm-run-all build:copy --parallel watch:*", "watch:js": "run-p watch:js:*", "watch:js:webpack": "webpack --watch --progress -d --devtool inline-source-map", @@ -41,11 +44,11 @@ "fix:lint:standard": "standard -v --fix \"*.js\" \"add-on/src/**/*.js\" \"test/**/*.js\"", "precommit": "run-s lint:standard", "prepush": "run-s clean build lint test", - "firefox": "web-ext run --browser-console", - "libdweb": "npm run libdweb:build && npm run libdweb:firefox", - "libdweb:build": "git submodule update --init --checkout --depth 1 libdweb && npm run dev-build && npm run libdweb:bundle", - "libdweb:bundle": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json add-on/manifest.firefox-libdweb.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/libdweb/", - "libdweb:firefox": "npx run-s libdweb:bundle && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=nightly --browser-console --url about:debugging", + "firefox": "web-ext run --browser-console --url about:debugging", + "libdweb": "npm run ci:install && npm run libdweb:build && npm run libdweb:firefox", + "libdweb:build": "git submodule update --init --checkout --depth 1 libdweb && cross-env-shell RELEASE_CHANNEL=libdweb npm run dev-build", + "libdweb:firefox": "npm run get-firefox-nightly && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=./firefox/firefox --browser-console --url about:debugging", + "get-firefox-nightly": "shx test -e ./firefox/firefox || get-firefox -b nightly -e", "ci": "run-s ci:*", "ci:install": "npx yarn@1.7.0 install --frozen-lockfile || npx yarn@1.7.0 install --frozen-lockfile", "ci:test": "npx yarn@1.7.0 test", @@ -73,6 +76,7 @@ "cross-env": "5.2.0", "fakefile": "0.0.9", "fs-promise": "2.0.3", + "get-firefox": "2.1.1", "husky": "0.14.3", "ignore-styles": "5.0.1", "json": "9.0.6", @@ -108,8 +112,8 @@ "ipfs-css": "0.5.2", "ipfs-http-response": "0.1.2", "ipfs-postmsg-proxy": "3.0.0", - "is-stream": "1.1.0", "is-ipfs": "0.4.2", + "is-stream": "1.1.0", "is-svg": "3.0.0", "lru_map": "0.3.3", "mime-types": "2.1.18", diff --git a/yarn.lock b/yarn.lock index 253fc6b14..86855f916 100644 --- a/yarn.lock +++ b/yarn.lock @@ -178,6 +178,12 @@ dependencies: lodash "^4.15.0" +"@samverschueren/stream-to-observable@^0.3.0": + version "0.3.0" + resolved "https://registry.yarnpkg.com/@samverschueren/stream-to-observable/-/stream-to-observable-0.3.0.tgz#ecdf48d532c58ea477acfcab80348424f8d0662f" + dependencies: + any-observable "^0.3.0" + "@sinonjs/formatio@^2.0.0": version "2.0.0" resolved "https://registry.yarnpkg.com/@sinonjs/formatio/-/formatio-2.0.0.tgz#84db7e9eb5531df18a8c5e0bfb6e449e55e654b2" @@ -564,6 +570,16 @@ ammo@2.x.x, ammo@^2.0.4: boom "5.x.x" hoek "4.x.x" +amqplib@^0.5.1: + version "0.5.2" + resolved "https://registry.yarnpkg.com/amqplib/-/amqplib-0.5.2.tgz#d2d7313c7ffaa4d10bcf1e6252de4591b6cc7b63" + dependencies: + bitsyntax "~0.0.4" + bluebird "^3.4.6" + buffer-more-ints "0.0.2" + readable-stream "1.x >=1.1.9" + safe-buffer "^5.0.1" + anchor-markdown-header@^0.5.5: version "0.5.7" resolved "https://registry.yarnpkg.com/anchor-markdown-header/-/anchor-markdown-header-0.5.7.tgz#045063d76e6a1f9cd327a57a0126aa0fdec371a7" @@ -576,7 +592,7 @@ ansi-align@^2.0.0: dependencies: string-width "^2.0.0" -ansi-escapes@^1.1.0: +ansi-escapes@^1.0.0, ansi-escapes@^1.1.0: version "1.4.0" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-1.4.0.tgz#d3a8a83b319aa67793662b13e761c7911422306e" @@ -610,6 +626,10 @@ ansicolors@^0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/ansicolors/-/ansicolors-0.3.2.tgz#665597de86a9ffe3aa9bfbe6cae5c6ea426b4979" +any-observable@^0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/any-observable/-/any-observable-0.3.0.tgz#af933475e5806a67d0d7df090dd5e8bef65d119b" + any-promise@^1.0.0, any-promise@^1.1.0, any-promise@^1.3.0, any-promise@~1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/any-promise/-/any-promise-1.3.0.tgz#abc6afeedcea52e809cdc0376aed3ce39635d17f" @@ -688,6 +708,10 @@ array-filter@~0.0.0: version "0.0.1" resolved "https://registry.yarnpkg.com/array-filter/-/array-filter-0.0.1.tgz#7da8cf2e26628ed732803581fd21f67cacd2eeec" +array-find-index@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/array-find-index/-/array-find-index-1.0.2.tgz#df010aa1287e164bbda6f9723b0a96a1ec4187a1" + array-flatten@1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/array-flatten/-/array-flatten-1.1.1.tgz#9a5f699051b1e7073328f2a008968b64ea2955d2" @@ -1405,6 +1429,10 @@ base64-js@0.0.2: version "0.0.2" resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-0.0.2.tgz#024f0f72afa25b75f9c0ee73cd4f55ec1bed9784" +base64-js@0.0.8: + version "0.0.8" + resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-0.0.8.tgz#1101e9544f4a76b1bc3b26d452ca96d7a35e7978" + base64-js@^1.0.2: version "1.3.0" resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.3.0.tgz#cab1e6118f051095e58b5281aea8c1cd22bfc0e3" @@ -1511,6 +1539,12 @@ bitcoinjs-lib@^3.3.2: varuint-bitcoin "^1.0.4" wif "^2.0.1" +bitsyntax@~0.0.4: + version "0.0.4" + resolved "https://registry.yarnpkg.com/bitsyntax/-/bitsyntax-0.0.4.tgz#eb10cc6f82b8c490e3e85698f07e83d46e0cba82" + dependencies: + buffer-more-ints "0.0.2" + bl@^1.0.0: version "1.2.2" resolved "https://registry.yarnpkg.com/bl/-/bl-1.2.2.tgz#a160911717103c07410cef63ef51b397c025af9c" @@ -1533,7 +1567,7 @@ blob@0.0.4, blob@~0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/blob/-/blob-0.0.4.tgz#bcf13052ca54463f30f9fc7e95b9a47630a94921" -bluebird@^3.5.1: +bluebird@^3.4.6, bluebird@^3.5.1: version "3.5.1" resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.5.1.tgz#d9551f9de98f1fcda1e683d17ee91a0602ee2eb9" @@ -1780,6 +1814,10 @@ buffer-loader@~0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/buffer-loader/-/buffer-loader-0.0.1.tgz#4d677ca92dd889310878b02a2fbcfab712024cf2" +buffer-more-ints@0.0.2: + version "0.0.2" + resolved "https://registry.yarnpkg.com/buffer-more-ints/-/buffer-more-ints-0.0.2.tgz#26b3885d10fa13db7fc01aae3aab870199e0124c" + buffer-peek-stream@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/buffer-peek-stream/-/buffer-peek-stream-1.0.1.tgz#53b47570a1347787c5bad4ca2ca3021f9d8b3cfd" @@ -1794,6 +1832,14 @@ buffer-xor@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/buffer-xor/-/buffer-xor-1.0.3.tgz#26e61ed1422fb70dd42e6e36729ed51d855fe8d9" +buffer@^3.0.1: + version "3.6.0" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-3.6.0.tgz#a72c936f77b96bf52f5f7e7b467180628551defb" + dependencies: + base64-js "0.0.8" + ieee754 "^1.1.4" + isarray "^1.0.0" + buffer@^4.3.0: version "4.9.1" resolved "https://registry.yarnpkg.com/buffer/-/buffer-4.9.1.tgz#6d1bb601b07a4efced97094132093027c95bc298" @@ -1914,6 +1960,14 @@ camel-case@^3.0.0: no-case "^2.2.0" upper-case "^1.1.1" +camelcase-keys@^4.0.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/camelcase-keys/-/camelcase-keys-4.2.0.tgz#a2aa5fb1af688758259c32c141426d78923b9b77" + dependencies: + camelcase "^4.1.0" + map-obj "^2.0.0" + quick-lru "^1.0.0" + camelcase@4.1.0, camelcase@^4.0.0, camelcase@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-4.1.0.tgz#d545635be1e33c542649c69173e5de6acfae34dd" @@ -2156,7 +2210,7 @@ cli-boxes@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/cli-boxes/-/cli-boxes-1.0.0.tgz#4fa917c3e59c94a004cd61f8ee509da651687143" -cli-cursor@^1.0.1: +cli-cursor@^1.0.1, cli-cursor@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-1.0.2.tgz#64da3f7d56a54412e59794bd62dc35295e8f2987" dependencies: @@ -2168,6 +2222,17 @@ cli-cursor@^2.0.0, cli-cursor@^2.1.0: dependencies: restore-cursor "^2.0.0" +cli-spinners@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/cli-spinners/-/cli-spinners-0.1.2.tgz#bb764d88e185fb9e1e6a2a1f19772318f605e31c" + +cli-truncate@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/cli-truncate/-/cli-truncate-0.2.1.tgz#9f15cfbb0705005369216c626ac7d05ab90dd574" + dependencies: + slice-ansi "0.0.4" + string-width "^1.0.1" + cli-width@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.0.tgz#ff19ede8a9a5e579324147b0c11f0fbcbabed639" @@ -2269,6 +2334,12 @@ commander@^2.11.0, commander@^2.13.0, commander@^2.15.0, commander@^2.3.0, comma version "2.16.0" resolved "https://registry.yarnpkg.com/commander/-/commander-2.16.0.tgz#f16390593996ceb4f3eeb020b31d78528f7f8a50" +commander@~2.8.1: + version "2.8.1" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.8.1.tgz#06be367febfda0c330aa1e2a072d3dc9762425d4" + dependencies: + graceful-readlink ">= 1.0.0" + common-tags@1.7.2: version "1.7.2" resolved "https://registry.yarnpkg.com/common-tags/-/common-tags-1.7.2.tgz#24d9768c63d253a56ecff93845b44b4df1d52771" @@ -2283,7 +2354,7 @@ component-bind@1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/component-bind/-/component-bind-1.0.0.tgz#00c608ab7dcd93897c0009651b1d3a8e1e73bbd1" -component-emitter@1.2.1, component-emitter@^1.2.1: +component-emitter@1.2.1, component-emitter@^1.2.0, component-emitter@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.2.1.tgz#137918d6d78283f7df7a6b7c5a63e140e69425e6" @@ -2368,6 +2439,10 @@ cookie@0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.3.1.tgz#e7e0a1f9ef43b4c8ba925c5c5a96e806d16873bb" +cookiejar@^2.1.0: + version "2.1.2" + resolved "https://registry.yarnpkg.com/cookiejar/-/cookiejar-2.1.2.tgz#dd8a235530752f988f9a0844f3fc589e3111125c" + copy-concurrently@^1.0.0: version "1.0.5" resolved "https://registry.yarnpkg.com/copy-concurrently/-/copy-concurrently-1.0.5.tgz#92297398cae34937fcafd6ec8139c18051f0b5e0" @@ -2513,6 +2588,12 @@ css-what@2.1: version "2.1.0" resolved "https://registry.yarnpkg.com/css-what/-/css-what-2.1.0.tgz#9467d032c38cfaefb9f2d79501253062f87fa1bd" +currently-unhandled@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/currently-unhandled/-/currently-unhandled-0.4.1.tgz#988df33feab191ef799a61369dd76c17adf957ea" + dependencies: + array-find-index "^1.0.1" + cyclist@~0.2.2: version "0.2.2" resolved "https://registry.yarnpkg.com/cyclist/-/cyclist-0.2.2.tgz#1b33792e11e914a2fd6d6ed6447464444e5fa640" @@ -2576,6 +2657,10 @@ datastore-level@~0.8.0: levelup "^2.0.2" pull-stream "^3.6.1" +date-fns@^1.27.2: + version "1.29.0" + resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-1.29.0.tgz#12e609cdcb935127311d04d33334e2960a2a54e6" + date-now@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/date-now/-/date-now-0.1.4.tgz#eaf439fd4d4848ad74e5cc7dbef200672b9e345b" @@ -2606,13 +2691,20 @@ debug@3.1.0, debug@^3.1.0, debug@~3.1.0: dependencies: ms "2.0.0" +decamelize-keys@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/decamelize-keys/-/decamelize-keys-1.1.0.tgz#d171a87933252807eb3cb61dc1c1445d078df2d9" + dependencies: + decamelize "^1.1.0" + map-obj "^1.0.0" + decamelize@2.0.0, decamelize@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-2.0.0.tgz#656d7bbc8094c4c788ea53c5840908c9c7d063c7" dependencies: xregexp "4.0.0" -decamelize@^1.0.0, decamelize@^1.1.1: +decamelize@^1.0.0, decamelize@^1.1.0, decamelize@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" @@ -2626,6 +2718,54 @@ decompress-response@^3.3.0: dependencies: mimic-response "^1.0.0" +decompress-tar@^4.0.0, decompress-tar@^4.1.0, decompress-tar@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/decompress-tar/-/decompress-tar-4.1.1.tgz#718cbd3fcb16209716e70a26b84e7ba4592e5af1" + dependencies: + file-type "^5.2.0" + is-stream "^1.1.0" + tar-stream "^1.5.2" + +decompress-tarbz2@^4.0.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/decompress-tarbz2/-/decompress-tarbz2-4.1.1.tgz#3082a5b880ea4043816349f378b56c516be1a39b" + dependencies: + decompress-tar "^4.1.0" + file-type "^6.1.0" + is-stream "^1.1.0" + seek-bzip "^1.0.5" + unbzip2-stream "^1.0.9" + +decompress-targz@^4.0.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/decompress-targz/-/decompress-targz-4.1.1.tgz#c09bc35c4d11f3de09f2d2da53e9de23e7ce1eee" + dependencies: + decompress-tar "^4.1.1" + file-type "^5.2.0" + is-stream "^1.1.0" + +decompress-unzip@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/decompress-unzip/-/decompress-unzip-4.0.1.tgz#deaaccdfd14aeaf85578f733ae8210f9b4848f69" + dependencies: + file-type "^3.8.0" + get-stream "^2.2.0" + pify "^2.3.0" + yauzl "^2.4.2" + +decompress@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/decompress/-/decompress-4.2.0.tgz#7aedd85427e5a92dacfe55674a7c505e96d01f9d" + dependencies: + decompress-tar "^4.0.0" + decompress-tarbz2 "^4.0.0" + decompress-targz "^4.0.0" + decompress-unzip "^4.0.1" + graceful-fs "^4.1.10" + make-dir "^1.0.0" + pify "^2.3.0" + strip-dirs "^2.0.0" + deep-eql@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-3.0.1.tgz#dfc9404400ad1c8fe023e7da1df1c147c4b444df" @@ -2981,6 +3121,10 @@ electron-to-chromium@^1.3.47: version "1.3.52" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.52.tgz#d2d9f1270ba4a3b967b831c40ef71fb4d9ab5ce0" +elegant-spinner@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/elegant-spinner/-/elegant-spinner-1.0.1.tgz#db043521c95d7e303fd8f345bedc3349cfb0729e" + elliptic@=3.0.3: version "3.0.3" resolved "http://registry.npmjs.org/elliptic/-/elliptic-3.0.3.tgz#865c9b420bfbe55006b9f969f97a0d2c44966595" @@ -3708,13 +3852,19 @@ fd-slicer@~1.0.1: dependencies: pend "~1.2.0" +fd-slicer@~1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/fd-slicer/-/fd-slicer-1.1.0.tgz#25c7c89cb1f9077f8891bbe61d8f390eae256f1e" + dependencies: + pend "~1.2.0" + figures@2.0.x, figures@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/figures/-/figures-2.0.0.tgz#3ab1a2d2a62c8bfb431a0c94cb797a2fce27c962" dependencies: escape-string-regexp "^1.0.5" -figures@^1.3.5: +figures@^1.3.5, figures@^1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/figures/-/figures-1.7.0.tgz#cbe1e3affcf1cd44b80cadfed28dc793a9701d2e" dependencies: @@ -3749,6 +3899,18 @@ file-type@8.0.0: version "8.0.0" resolved "https://registry.yarnpkg.com/file-type/-/file-type-8.0.0.tgz#6e4bccc741187f4113334a4e4a4ef84d54d7cc1e" +file-type@^3.8.0: + version "3.9.0" + resolved "https://registry.yarnpkg.com/file-type/-/file-type-3.9.0.tgz#257a078384d1db8087bc449d107d52a52672b9e9" + +file-type@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/file-type/-/file-type-5.2.0.tgz#2ddbea7c73ffe36368dfae49dc338c058c2b8ad6" + +file-type@^6.1.0: + version "6.2.0" + resolved "https://registry.yarnpkg.com/file-type/-/file-type-6.2.0.tgz#e50cd75d356ffed4e306dc4f5bcf52a79903a919" + file-type@^8.0.0, file-type@^8.1.0: version "8.1.0" resolved "https://registry.yarnpkg.com/file-type/-/file-type-8.1.0.tgz#244f3b7ef641bbe0cca196c7276e4b332399f68c" @@ -3933,7 +4095,7 @@ forever-agent@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" -form-data@~2.3.1: +form-data@^2.3.1, form-data@~2.3.1: version "2.3.2" resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.2.tgz#4970498be604c20c005d4f5c23aecd21d6b49099" dependencies: @@ -3952,6 +4114,10 @@ form-data@~2.3.1: foreachasync "^3.0.0" remedial "^1.0.7" +formidable@^1.2.0: + version "1.2.1" + resolved "https://registry.yarnpkg.com/formidable/-/formidable-1.2.1.tgz#70fb7ca0290ee6ff961090415f4b3df3d2082659" + forwarded@~0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/forwarded/-/forwarded-0.1.2.tgz#98c23dab1175657b8c0573e8ceccd91b0ff18c84" @@ -4136,6 +4302,20 @@ get-caller-file@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" +get-firefox@2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/get-firefox/-/get-firefox-2.1.1.tgz#1dbafe1e357fb292e816d4c64b6fc7a5153bf7a7" + dependencies: + chalk "^2.4.1" + decompress "^4.2.0" + listr "^0.14.0" + meow "^5.0.0" + moz-download-url "^2.0.0" + node-fetch "^2.1.2" + sha "^2.0.1" + stream-to-promise "^2.2.0" + taskcluster-client "^11.0.0" + get-folder-size@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/get-folder-size/-/get-folder-size-2.0.0.tgz#f0ecb4aa30ea855e051366714eaabcc41cf9d43f" @@ -4151,6 +4331,13 @@ get-stdin@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/get-stdin/-/get-stdin-5.0.1.tgz#122e161591e21ff4c52530305693f20e6393a398" +get-stream@^2.2.0: + version "2.3.1" + resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-2.3.1.tgz#5f38f93f346009666ee0150a054167f91bdd95de" + dependencies: + object-assign "^4.0.1" + pinkie-promise "^2.0.0" + get-stream@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14" @@ -4289,7 +4476,7 @@ got@^6.7.1: unzip-response "^2.0.1" url-parse-lax "^1.0.0" -graceful-fs@4.1.11, graceful-fs@^4.1.0, graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9: +graceful-fs@4.1.11, graceful-fs@^4.1.0, graceful-fs@^4.1.10, graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9: version "4.1.11" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658" @@ -4463,7 +4650,7 @@ hashlru@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/hashlru/-/hashlru-2.2.1.tgz#10f2099a0d7c05a40f2beaf5c1d39cf2f7dabf36" -hawk@~6.0.2: +hawk@^6.0.2, hawk@~6.0.2: version "6.0.2" resolved "https://registry.yarnpkg.com/hawk/-/hawk-6.0.2.tgz#af4d914eb065f9b5ce4d9d11c1cb2126eecc3038" dependencies: @@ -4655,6 +4842,16 @@ imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" +indent-string@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-2.1.0.tgz#8e2d48348742121b4a8218b7a137e9a52049dc80" + dependencies: + repeating "^2.0.0" + +indent-string@^3.0.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-3.2.0.tgz#4a5fd6d27cc332f37e5419a504dbb837105c9289" + indexof@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/indexof/-/indexof-0.0.1.tgz#82dc336d232b9062179d05ab3293a66059fd435d" @@ -5444,6 +5641,10 @@ is-my-json-valid@^2.10.0: jsonpointer "^4.0.0" xtend "^4.0.0" +is-natural-number@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/is-natural-number/-/is-natural-number-4.0.1.tgz#ab9d76e1db4ced51e35de0c72ebecf09f734cde8" + is-npm@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-npm/-/is-npm-1.0.0.tgz#f2fb63a65e4905b406c86072765a1a4dc793b9f4" @@ -5458,6 +5659,12 @@ is-obj@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-1.0.1.tgz#3e4729ac1f5fde025cd7d83a896dab9f4f67db0f" +is-observable@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-observable/-/is-observable-1.1.0.tgz#b3e986c8f44de950867cab5403f5a3465005975e" + dependencies: + symbol-observable "^1.1.0" + is-path-cwd@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-path-cwd/-/is-path-cwd-1.0.0.tgz#d225ec23132e89edd38fda767472e62e65f1106d" @@ -5474,6 +5681,10 @@ is-path-inside@^1.0.0: dependencies: path-is-inside "^1.0.1" +is-plain-obj@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-plain-obj/-/is-plain-obj-1.1.0.tgz#71a50c8429dfca773c92a390a4a03b39fcd51d3e" + is-plain-object@^2.0.1, is-plain-object@^2.0.3, is-plain-object@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-2.0.4.tgz#2c163b3fafb1b606d9d17928f05c2a1c38e07677" @@ -6379,6 +6590,53 @@ libp2p@~0.23.0: peer-id "~0.11.0" peer-info "~0.14.1" +listr-silent-renderer@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/listr-silent-renderer/-/listr-silent-renderer-1.1.1.tgz#924b5a3757153770bf1a8e3fbf74b8bbf3f9242e" + +listr-update-renderer@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/listr-update-renderer/-/listr-update-renderer-0.4.0.tgz#344d980da2ca2e8b145ba305908f32ae3f4cc8a7" + dependencies: + chalk "^1.1.3" + cli-truncate "^0.2.1" + elegant-spinner "^1.0.1" + figures "^1.7.0" + indent-string "^3.0.0" + log-symbols "^1.0.2" + log-update "^1.0.2" + strip-ansi "^3.0.1" + +listr-verbose-renderer@^0.4.0: + version "0.4.1" + resolved "https://registry.yarnpkg.com/listr-verbose-renderer/-/listr-verbose-renderer-0.4.1.tgz#8206f4cf6d52ddc5827e5fd14989e0e965933a35" + dependencies: + chalk "^1.1.3" + cli-cursor "^1.0.2" + date-fns "^1.27.2" + figures "^1.7.0" + +listr@^0.14.0: + version "0.14.1" + resolved "https://registry.yarnpkg.com/listr/-/listr-0.14.1.tgz#8a7afa4a7135cee4c921d128e0b7dfc6e522d43d" + dependencies: + "@samverschueren/stream-to-observable" "^0.3.0" + cli-truncate "^0.2.1" + figures "^1.7.0" + indent-string "^2.1.0" + is-observable "^1.1.0" + is-promise "^2.1.0" + is-stream "^1.1.0" + listr-silent-renderer "^1.1.1" + listr-update-renderer "^0.4.0" + listr-verbose-renderer "^0.4.0" + log-symbols "^1.0.2" + log-update "^1.0.2" + ora "^0.2.3" + p-map "^1.1.1" + rxjs "^6.1.0" + strip-ansi "^3.0.1" + load-json-file@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-1.1.0.tgz#956905708d58b4bab4c2261b04f59f31c99374c0" @@ -6626,6 +6884,12 @@ lodash@=3.10.1: version "3.10.1" resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6" +log-symbols@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-1.0.2.tgz#376ff7b58ea3086a0f09facc74617eca501e1a18" + dependencies: + chalk "^1.0.0" + log-update@2.3.x: version "2.3.0" resolved "https://registry.yarnpkg.com/log-update/-/log-update-2.3.0.tgz#88328fd7d1ce7938b29283746f0b1bc126b24708" @@ -6634,6 +6898,13 @@ log-update@2.3.x: cli-cursor "^2.0.0" wrap-ansi "^3.0.1" +log-update@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/log-update/-/log-update-1.0.2.tgz#19929f64c4093d2d2e7075a1dad8af59c296b8d1" + dependencies: + ansi-escapes "^1.0.0" + cli-cursor "^1.0.2" + lolex@^2.2.0, lolex@^2.3.2, lolex@^2.4.2: version "2.7.1" resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.7.1.tgz#e40a8c4d1f14b536aa03e42a537c7adbaf0c20be" @@ -6668,6 +6939,13 @@ loose-envify@^1.0.0: dependencies: js-tokens "^3.0.0 || ^4.0.0" +loud-rejection@^1.0.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/loud-rejection/-/loud-rejection-1.6.0.tgz#5b46f80147edee578870f086d04821cf998e551f" + dependencies: + currently-unhandled "^0.4.1" + signal-exit "^3.0.0" + lower-case@^1.1.1: version "1.1.4" resolved "https://registry.yarnpkg.com/lower-case/-/lower-case-1.1.4.tgz#9a2cabd1b9e8e0ae993a4bf7d5875c39c42e8eac" @@ -6721,6 +6999,14 @@ map-cache@^0.2.2: version "0.2.2" resolved "https://registry.yarnpkg.com/map-cache/-/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" +map-obj@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-1.0.1.tgz#d933ceb9205d82bdcf4886f6742bdc2b4dea146d" + +map-obj@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-2.0.0.tgz#a65cd29087a92598b8791257a523e021222ac1f9" + map-stream@~0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/map-stream/-/map-stream-0.1.0.tgz#e56aa94c4c8055a16404a0674b78f215f7c8e194" @@ -6808,6 +7094,20 @@ memorystream@^0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/memorystream/-/memorystream-0.3.1.tgz#86d7090b30ce455d63fbae12dda51a47ddcaf9b2" +meow@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/meow/-/meow-5.0.0.tgz#dfc73d63a9afc714a5e371760eb5c88b91078aa4" + dependencies: + camelcase-keys "^4.0.0" + decamelize-keys "^1.0.0" + loud-rejection "^1.0.0" + minimist-options "^3.0.1" + normalize-package-data "^2.3.4" + read-pkg-up "^3.0.0" + redent "^2.0.0" + trim-newlines "^2.0.0" + yargs-parser "^10.0.0" + merge-descriptors@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/merge-descriptors/-/merge-descriptors-1.0.1.tgz#b00aaa556dd8b44568150ec9d1b953f3f90cbb61" @@ -6845,7 +7145,7 @@ merkle-patricia-tree@^2.1.2, merkle-patricia-tree@^2.2.0: rlp "^2.0.0" semaphore ">=1.0.1" -methods@~1.1.2: +methods@^1.1.1, methods@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/methods/-/methods-1.1.2.tgz#5529a4d67654134edcc5266656835b0f851afcee" @@ -6902,6 +7202,10 @@ mime@1.4.1: version "2.3.1" resolved "https://registry.yarnpkg.com/mime/-/mime-2.3.1.tgz#b1621c54d63b97c47d3cfe7f7215f7d64517c369" +mime@^1.4.1: + version "1.6.0" + resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" + mimic-fn@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" @@ -6937,6 +7241,13 @@ minimalistic-crypto-utils@^1.0.0, minimalistic-crypto-utils@^1.0.1: dependencies: brace-expansion "^1.1.7" +minimist-options@^3.0.1: + version "3.0.2" + resolved "https://registry.yarnpkg.com/minimist-options/-/minimist-options-3.0.2.tgz#fba4c8191339e13ecf4d61beb03f070103f3d954" + dependencies: + arrify "^1.0.1" + is-plain-obj "^1.1.0" + minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" @@ -7067,6 +7378,10 @@ moving-average@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/moving-average/-/moving-average-1.0.0.tgz#b1247ba8dd2d7927c619f1eac8036cf933d65adc" +moz-download-url@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/moz-download-url/-/moz-download-url-2.0.0.tgz#69b5d73daa1a2fa068b76bb6a33fb6a634c4bbb0" + ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" @@ -7421,6 +7736,10 @@ node-abi@^2.2.0: dependencies: semver "^5.4.1" +node-fetch@^2.1.2: + version "2.2.0" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.2.0.tgz#4ee79bde909262f9775f731e3656d0db55ced5b5" + node-forge@^0.7.1, node-forge@^0.7.5: version "0.7.5" resolved "https://registry.yarnpkg.com/node-forge/-/node-forge-0.7.5.tgz#6c152c345ce11c52f465c2abd957e8639cd674df" @@ -7506,7 +7825,7 @@ normalize-html-whitespace@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/normalize-html-whitespace/-/normalize-html-whitespace-0.2.0.tgz#101722f6423551c75cdb8f9d104ff850daf1e10e" -normalize-package-data@^2.3.2: +normalize-package-data@^2.3.2, normalize-package-data@^2.3.4: version "2.4.0" resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.4.0.tgz#12f95a307d58352075a04907b84ac8be98ac012f" dependencies: @@ -7741,6 +8060,15 @@ options@>=0.0.5: version "0.0.6" resolved "https://registry.yarnpkg.com/options/-/options-0.0.6.tgz#ec22d312806bb53e731773e7cdaefcf1c643128f" +ora@^0.2.3: + version "0.2.3" + resolved "https://registry.yarnpkg.com/ora/-/ora-0.2.3.tgz#37527d220adcd53c39b73571d754156d5db657a4" + dependencies: + chalk "^1.1.1" + cli-cursor "^1.0.2" + cli-spinners "^0.1.2" + object-assign "^4.0.1" + os-browserify@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/os-browserify/-/os-browserify-0.3.0.tgz#854373c7f5c2315914fc9bfc6bd8238fdda1ec27" @@ -7813,6 +8141,10 @@ p-locate@^3.0.0: dependencies: p-limit "^2.0.0" +p-map@^1.1.1: + version "1.2.0" + resolved "https://registry.yarnpkg.com/p-map/-/p-map-1.2.0.tgz#e4e94f311eabbc8633a1e79908165fca26241b6b" + p-queue@2.4.2, p-queue@^2.4.2: version "2.4.2" resolved "https://registry.yarnpkg.com/p-queue/-/p-queue-2.4.2.tgz#03609826682b743be9a22dba25051bd46724fc34" @@ -8077,7 +8409,7 @@ pez@2.x.x: hoek "4.x.x" nigel "2.x.x" -pify@^2.0.0: +pify@^2.0.0, pify@^2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" @@ -8303,6 +8635,12 @@ promise-timeout@^1.3.0: dependencies: asap "~2.0.3" +promise@^8.0.1: + version "8.0.1" + resolved "https://registry.yarnpkg.com/promise/-/promise-8.0.1.tgz#e45d68b00a17647b6da711bf85ed6ed47208f450" + dependencies: + asap "~2.0.3" + promise@~1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/promise/-/promise-1.3.0.tgz#e5cc9a4c8278e4664ffedc01c7da84842b040175" @@ -8579,7 +8917,7 @@ qs@6.5.1: version "6.5.1" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" -qs@^6.5.2, qs@~6.5.1: +qs@^6.5.1, qs@^6.5.2, qs@~6.5.1: version "6.5.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" @@ -8597,6 +8935,10 @@ quick-format-unescaped@^1.1.2: dependencies: fast-safe-stringify "^1.0.8" +quick-lru@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-1.1.0.tgz#4360b17c61136ad38078397ff11416e186dcfbb8" + randombytes@^2.0.0, randombytes@^2.0.1, randombytes@^2.0.3, randombytes@^2.0.5: version "2.0.6" resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.0.6.tgz#d302c522948588848a8d300c932b44c24231da80" @@ -8652,6 +8994,13 @@ read-pkg-up@^1.0.1: find-up "^1.0.0" read-pkg "^1.0.0" +read-pkg-up@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-3.0.0.tgz#3ed496685dba0f8fe118d0691dc51f4a1ff96f07" + dependencies: + find-up "^2.0.0" + read-pkg "^3.0.0" + read-pkg-up@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-4.0.0.tgz#1b221c6088ba7799601c808f91161c66e58f8978" @@ -8691,7 +9040,7 @@ readable-stream-node-to-web@^1.0.1: string_decoder "~1.1.1" util-deprecate "~1.0.1" -readable-stream@1.1.x, readable-stream@^1.0.33: +readable-stream@1.1.x, "readable-stream@1.x >=1.1.9", readable-stream@^1.0.33: version "1.1.14" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.1.14.tgz#7cf4c54ef648e3813084c636dd2079e166c081d9" dependencies: @@ -8738,6 +9087,13 @@ recursive-readdir@^2.2.2: dependencies: minimatch "3.0.4" +redent@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/redent/-/redent-2.0.0.tgz#c1b2007b42d57eb1389079b3c8333639d5e1ccaa" + dependencies: + indent-string "^3.0.0" + strip-indent "^2.0.0" + regenerate@^1.2.1: version "1.4.0" resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.0.tgz#4a856ec4b56e4077c557589cae85e7a4c8869a11" @@ -9143,6 +9499,12 @@ secure-keys@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/secure-keys/-/secure-keys-1.0.0.tgz#f0c82d98a3b139a8776a8808050b824431087fca" +seek-bzip@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/seek-bzip/-/seek-bzip-1.0.5.tgz#cfe917cb3d274bcffac792758af53173eb1fabdc" + dependencies: + commander "~2.8.1" + semaphore@>=1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/semaphore/-/semaphore-1.1.0.tgz#aaad8b86b20fe8e9b32b16dc2ee682a8cd26a8aa" @@ -9241,6 +9603,13 @@ sha.js@^2.4.0, sha.js@^2.4.8, sha.js@~2.4.4: inherits "^2.0.1" safe-buffer "^5.0.1" +sha@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/sha/-/sha-2.0.1.tgz#6030822fbd2c9823949f8f72ed6411ee5cf25aae" + dependencies: + graceful-fs "^4.1.2" + readable-stream "^2.0.2" + shallow-clone@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/shallow-clone/-/shallow-clone-0.1.2.tgz#5909e874ba77106d73ac414cfec1ffca87d97060" @@ -9431,6 +9800,12 @@ slide@^1.1.5: version "1.1.6" resolved "https://registry.yarnpkg.com/slide/-/slide-1.1.6.tgz#56eb027d65b4d2dce6cb2e2d32c4d4afc9e1d707" +slugid@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/slugid/-/slugid-1.1.0.tgz#e09f00899c09f5a7058edc36dd49f046fd50a82a" + dependencies: + uuid "^2.0.1" + smart-buffer@^1.0.13: version "1.1.15" resolved "https://registry.yarnpkg.com/smart-buffer/-/smart-buffer-1.1.15.tgz#7f114b5b65fab3e2a35aa775bb12f0d1c649bf16" @@ -9954,7 +10329,7 @@ stream-to-array@~2.3.0: dependencies: any-promise "^1.1.0" -stream-to-promise@2.2.0: +stream-to-promise@2.2.0, stream-to-promise@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/stream-to-promise/-/stream-to-promise-2.2.0.tgz#b1edb2e1c8cb11289d1b503c08d3f2aef51e650f" dependencies: @@ -10062,6 +10437,12 @@ strip-bom@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-3.0.0.tgz#2334c18e9c759f7bdd56fdef7e9ae3d588e68ed3" +strip-dirs@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/strip-dirs/-/strip-dirs-2.1.0.tgz#4987736264fc344cf20f6c34aca9d13d1d4ed6c5" + dependencies: + is-natural-number "^4.0.1" + strip-eof@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" @@ -10096,6 +10477,21 @@ subtext@^5.0.0: pez "2.x.x" wreck "12.x.x" +superagent@~3.8.1: + version "3.8.3" + resolved "https://registry.yarnpkg.com/superagent/-/superagent-3.8.3.tgz#460ea0dbdb7d5b11bc4f78deba565f86a178e128" + dependencies: + component-emitter "^1.2.0" + cookiejar "^2.1.0" + debug "^3.1.0" + extend "^3.0.0" + form-data "^2.3.1" + formidable "^1.2.0" + methods "^1.1.1" + mime "^1.4.1" + qs "^6.5.1" + readable-stream "^2.3.5" + supports-color@3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-3.1.2.tgz#72a262894d9d408b956ca05ff37b2ed8a6e2a2d5" @@ -10118,6 +10514,10 @@ supports-color@^3.1.2: dependencies: has-flag "^1.0.0" +symbol-observable@^1.1.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/symbol-observable/-/symbol-observable-1.2.0.tgz#c22688aed4eab3cdc2dfeacbb561660560a00804" + table@4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/table/-/table-4.0.2.tgz#a33447375391e766ad34d3486e6e2aedc84d2e36" @@ -10157,7 +10557,7 @@ tar-fs@^1.13.0: pump "^1.0.0" tar-stream "^1.1.2" -tar-stream@^1.1.2, tar-stream@^1.5.0, tar-stream@^1.6.1: +tar-stream@^1.1.2, tar-stream@^1.5.0, tar-stream@^1.5.2, tar-stream@^1.6.1: version "1.6.1" resolved "https://registry.yarnpkg.com/tar-stream/-/tar-stream-1.6.1.tgz#f84ef1696269d6223ca48f6e1eeede3f7e81f395" dependencies: @@ -10181,6 +10581,23 @@ tar@^4: safe-buffer "^5.1.2" yallist "^3.0.2" +taskcluster-client@^11.0.0: + version "11.0.3" + resolved "https://registry.yarnpkg.com/taskcluster-client/-/taskcluster-client-11.0.3.tgz#f71fd2d75dc4912ecc6c69fc56994eae088265aa" + dependencies: + amqplib "^0.5.1" + debug "^3.1.0" + hawk "^6.0.2" + lodash "^4.17.4" + promise "^8.0.1" + slugid "^1.1.0" + superagent "~3.8.1" + taskcluster-lib-urls "^10.0.0" + +taskcluster-lib-urls@^10.0.0: + version "10.0.0" + resolved "https://registry.yarnpkg.com/taskcluster-lib-urls/-/taskcluster-lib-urls-10.0.0.tgz#ee4c687b4539171d8aef39b38a63c8b9bc82f82e" + tdigest@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/tdigest/-/tdigest-0.1.1.tgz#2e3cb2c39ea449e55d1e6cd91117accca4588021" @@ -10409,6 +10826,10 @@ traverse@^0.6.6, traverse@~0.6.6: version "0.6.6" resolved "https://registry.yarnpkg.com/traverse/-/traverse-0.6.6.tgz#cbdf560fd7b9af632502fed40f918c157ea97137" +trim-newlines@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-2.0.0.tgz#b403d0b91be50c331dfc4b82eeceb22c3de16d20" + trim-right@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" @@ -10522,6 +10943,13 @@ ultron@~1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.1.1.tgz#9fe1536a10a664a65266a1e3ccf85fd36302bc9c" +unbzip2-stream@^1.0.9: + version "1.2.5" + resolved "https://registry.yarnpkg.com/unbzip2-stream/-/unbzip2-stream-1.2.5.tgz#73a033a567bbbde59654b193c44d48a7e4f43c47" + dependencies: + buffer "^3.0.1" + through "^2.3.6" + undefsafe@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/undefsafe/-/undefsafe-2.0.2.tgz#225f6b9e0337663e0d8e7cfd686fc2836ccace76" @@ -10726,6 +11154,10 @@ utils-merge@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/utils-merge/-/utils-merge-1.0.1.tgz#9f95710f50a267947b2ccc124741c1028427e713" +uuid@^2.0.1: + version "2.0.3" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-2.0.3.tgz#67e2e863797215530dff318e5bf9dcebfd47b21a" + uuid@^3.0.0, uuid@^3.0.1, uuid@^3.1.0, uuid@^3.2.1: version "3.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" @@ -11172,7 +11604,7 @@ yallist@^3.0.0, yallist@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.0.2.tgz#8452b4bb7e83c7c188d8041c1a837c773d6d8bb9" -yargs-parser@^10.1.0: +yargs-parser@^10.0.0, yargs-parser@^10.1.0: version "10.1.0" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-10.1.0.tgz#7202265b89f7e9e9f2e5765e0fe735a905edbaa8" dependencies: @@ -11297,6 +11729,13 @@ yauzl@2.9.1: buffer-crc32 "~0.2.3" fd-slicer "~1.0.1" +yauzl@^2.4.2: + version "2.10.0" + resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.10.0.tgz#c7eb17c93e112cb1086fa6d8e51fb0667b79a5f9" + dependencies: + buffer-crc32 "~0.2.3" + fd-slicer "~1.1.0" + yeast@0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/yeast/-/yeast-0.1.2.tgz#008e06d8094320c372dbc2f8ed76a0ca6c8ac419" From f4486de16640652cf22c0f83774c162357f5cbb1 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 3 Aug 2018 10:52:03 -0700 Subject: [PATCH 13/31] fix(libdweb): udpate web-ext to fix addon-lint --- package.json | 2 +- yarn.lock | 696 ++++++++++++++++++--------------------------------- 2 files changed, 249 insertions(+), 449 deletions(-) diff --git a/package.json b/package.json index e35159021..ccf5f315e 100644 --- a/package.json +++ b/package.json @@ -93,7 +93,7 @@ "standard": "10.0.3", "terser": "3.8.0", "transform-loader": "0.2.4", - "web-ext": "2.7.0", + "web-ext": "2.8.0", "webpack": "4.16.1", "webpack-bundle-analyzer": "2.13.1", "webpack-cli": "3.1.0", diff --git a/yarn.lock b/yarn.lock index 86855f916..94962282b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -404,6 +404,12 @@ acorn-jsx@^3.0.0: dependencies: acorn "^3.0.4" +acorn-jsx@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-4.1.1.tgz#e8e41e48ea2fe0c896740610ab6a4ffd8add225e" + dependencies: + acorn "^5.0.3" + acorn-node@^1.3.0: version "1.5.2" resolved "https://registry.yarnpkg.com/acorn-node/-/acorn-node-1.5.2.tgz#2ca723df19d997b05824b69f6c7fb091fc42c322" @@ -416,7 +422,7 @@ acorn@^3.0.4: version "3.3.0" resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" -acorn@^5.0.0, acorn@^5.2.1, acorn@^5.3.0, acorn@^5.5.0, acorn@^5.6.2, acorn@^5.7.1: +acorn@^5.0.0, acorn@^5.0.3, acorn@^5.2.1, acorn@^5.3.0, acorn@^5.5.0, acorn@^5.6.0, acorn@^5.6.2, acorn@^5.7.1: version "5.7.1" resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.1.tgz#f095829297706a7c9776958c0afc8930a9b9d9d8" @@ -442,23 +448,22 @@ adbkit@2.11.0: node-forge "^0.7.1" split "~0.3.3" -addons-linter@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/addons-linter/-/addons-linter-1.0.0.tgz#909bba25c8c58b8b699ebf39266655b1d64e8cc2" +addons-linter@1.2.6: + version "1.2.6" + resolved "https://registry.yarnpkg.com/addons-linter/-/addons-linter-1.2.6.tgz#6bc4bbe37a750978d7e79a15c3dfc61223e3873e" dependencies: - ajv "6.5.0" - ajv-merge-patch "3.0.0" + ajv "6.5.2" + ajv-merge-patch "4.1.0" babel-register "6.26.0" chalk "2.4.0" cheerio "1.0.0-rc.2" columnify "1.5.4" - common-tags "1.7.2" + common-tags "1.8.0" crx-parser "0.1.2" - deepmerge "2.1.0" - dispensary "0.18.0" - doctoc "1.3.1" + deepmerge "2.1.1" + dispensary "0.21.0" es6-promisify "5.0.0" - eslint "4.19.1" + eslint "5.0.1" eslint-plugin-no-unsafe-innerhtml "1.0.16" esprima "3.1.3" first-chunk-stream "2.0.0" @@ -467,22 +472,24 @@ addons-linter@1.0.0: is-mergeable-object "1.1.0" jed "1.1.1" os-locale "2.1.0" - pino "4.16.1" + pino "5.0.0-rc.4" po2json "0.4.5" - postcss "6.0.19" + postcss "6.0.23" probe-image-size "4.0.0" relaxed-json "1.0.1" semver "5.5.0" - shelljs "0.8.1" - snyk "^1.78.1" + shelljs "0.8.2" + snyk "^1.88.2" source-map-support "0.5.6" strip-bom-stream "3.0.0" tosource "1.0.0" - upath "1.0.5" - whatwg-url "6.4.1" + upath "1.1.0" + whatwg-url "6.5.0" xmldom "0.1.27" - yargs "11.0.0" - yauzl "2.9.1" + yargs "12.0.1" + yauzl "2.9.2" + optionalDependencies: + fsevents "1.2.4" adm-zip@~0.4.x: version "0.4.11" @@ -502,28 +509,24 @@ ajv-keywords@^1.0.0: version "1.5.1" resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-1.5.1.tgz#314dd0a4b3368fad3dfcdc54ede6171b886daf3c" -ajv-keywords@^2.1.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" - -ajv-keywords@^3.1.0: +ajv-keywords@^3.0.0, ajv-keywords@^3.1.0: version "3.2.0" resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.2.0.tgz#e86b819c602cf8821ad637413698f1dec021847a" -ajv-merge-patch@3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/ajv-merge-patch/-/ajv-merge-patch-3.0.0.tgz#76f071e391f419fe9fe3fea7e920a1ad824b2b61" +ajv-merge-patch@4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/ajv-merge-patch/-/ajv-merge-patch-4.1.0.tgz#cd580e5860ac53431d6aa901fa3d5e2eb2b74a6c" dependencies: - fast-json-patch "^1.0.0" + fast-json-patch "^2.0.6" json-merge-patch "^0.2.3" -ajv@6.5.0: - version "6.5.0" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.5.0.tgz#4c8affdf80887d8f132c9c52ab8a2dc4d0b7b24c" +ajv@6.5.2, ajv@^6.0.1, ajv@^6.1.0, ajv@^6.5.0: + version "6.5.2" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.5.2.tgz#678495f9b82f7cca6be248dd92f59bff5e1f4360" dependencies: fast-deep-equal "^2.0.1" fast-json-stable-stringify "^2.0.0" - json-schema-traverse "^0.3.0" + json-schema-traverse "^0.4.1" uri-js "^4.2.1" ajv@^4.7.0: @@ -533,7 +536,7 @@ ajv@^4.7.0: co "^4.6.0" json-stable-stringify "^1.0.1" -ajv@^5.1.0, ajv@^5.2.3, ajv@^5.3.0: +ajv@^5.1.0: version "5.5.2" resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" dependencies: @@ -542,15 +545,6 @@ ajv@^5.1.0, ajv@^5.2.3, ajv@^5.3.0: fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.3.0" -ajv@^6.1.0: - version "6.5.2" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.5.2.tgz#678495f9b82f7cca6be248dd92f59bff5e1f4360" - dependencies: - fast-deep-equal "^2.0.1" - fast-json-stable-stringify "^2.0.0" - json-schema-traverse "^0.4.1" - uri-js "^4.2.1" - align-text@^0.1.1, align-text@^0.1.3: version "0.1.4" resolved "https://registry.yarnpkg.com/align-text/-/align-text-0.1.4.tgz#0cd90a561093f35d0a99256c22b7069433fad117" @@ -580,12 +574,6 @@ amqplib@^0.5.1: readable-stream "1.x >=1.1.9" safe-buffer "^5.0.1" -anchor-markdown-header@^0.5.5: - version "0.5.7" - resolved "https://registry.yarnpkg.com/anchor-markdown-header/-/anchor-markdown-header-0.5.7.tgz#045063d76e6a1f9cd327a57a0126aa0fdec371a7" - dependencies: - emoji-regex "~6.1.0" - ansi-align@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ansi-align/-/ansi-align-2.0.0.tgz#c36aeccba563b89ceb556f3690f0b1d9e3547f7f" @@ -704,6 +692,10 @@ arr-union@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" +array-differ@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-1.0.0.tgz#eff52e3758249d33be402b8bb8e564bb2b5d4031" + array-filter@~0.0.0: version "0.0.1" resolved "https://registry.yarnpkg.com/array-filter/-/array-filter-0.0.1.tgz#7da8cf2e26628ed732803581fd21f67cacd2eeec" @@ -898,7 +890,7 @@ b64@3.x.x: version "3.0.3" resolved "https://registry.yarnpkg.com/b64/-/b64-3.0.3.tgz#36afeee0d9345f046387ce6de8a6702afe5bb56e" -babel-code-frame@^6.16.0, babel-code-frame@^6.22.0, babel-code-frame@^6.26.0: +babel-code-frame@^6.16.0, babel-code-frame@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b" dependencies: @@ -1403,10 +1395,6 @@ backo2@1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/backo2/-/backo2-1.0.2.tgz#31ab1ac8b129363463e35b3ebb69f4dfcfba7947" -bail@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/bail/-/bail-1.0.3.tgz#63cfb9ddbac829b02a3128cd53224be78e6c21a3" - balanced-match@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" @@ -1644,10 +1632,6 @@ borc@^2.0.2: ieee754 "^1.1.8" json-text-sequence "^0.1" -boundary@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/boundary/-/boundary-1.0.1.tgz#4d67dc2602c0cc16dd9bce7ebf87e948290f5812" - boxen@^1.2.1: version "1.3.0" resolved "https://registry.yarnpkg.com/boxen/-/boxen-1.3.0.tgz#55c6c39a8ba58d9c61ad22cd877532deb665a20b" @@ -2010,10 +1994,6 @@ catbox@^7.1.5: hoek "4.x.x" joi "10.x.x" -ccount@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/ccount/-/ccount-1.0.3.tgz#f1cec43f332e2ea5a569fd46f9f5bde4e6102aff" - center-align@^0.1.1: version "0.1.3" resolved "https://registry.yarnpkg.com/center-align/-/center-align-0.1.3.tgz#aa0d32629b6ee972200411cbd4461c907bc2b7ad" @@ -2058,7 +2038,7 @@ chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" -chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.0, chalk@^2.3.1, chalk@^2.3.2, chalk@^2.4.1: +chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.0, chalk@^2.4.1: version "2.4.1" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e" dependencies: @@ -2074,22 +2054,6 @@ chalk@~0.4.0: has-color "~0.1.0" strip-ansi "~0.1.0" -character-entities-html4@^1.0.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/character-entities-html4/-/character-entities-html4-1.1.2.tgz#c44fdde3ce66b52e8d321d6c1bf46101f0150610" - -character-entities-legacy@^1.0.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/character-entities-legacy/-/character-entities-legacy-1.1.2.tgz#7c6defb81648498222c9855309953d05f4d63a9c" - -character-entities@^1.0.0: - version "1.2.2" - resolved "https://registry.yarnpkg.com/character-entities/-/character-entities-1.2.2.tgz#58c8f371c0774ef0ba9b2aca5f00d8f100e6e363" - -character-reference-invalid@^1.0.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/character-reference-invalid/-/character-reference-invalid-1.1.2.tgz#21e421ad3d84055952dab4a43a04e73cd425d3ed" - chardet@^0.4.0: version "0.4.2" resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" @@ -2282,10 +2246,6 @@ code-point-at@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" -collapse-white-space@^1.0.0: - version "1.0.4" - resolved "https://registry.yarnpkg.com/collapse-white-space/-/collapse-white-space-1.0.4.tgz#ce05cf49e54c3277ae573036a26851ba430a0091" - collection-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" @@ -2340,11 +2300,9 @@ commander@~2.8.1: dependencies: graceful-readlink ">= 1.0.0" -common-tags@1.7.2: - version "1.7.2" - resolved "https://registry.yarnpkg.com/common-tags/-/common-tags-1.7.2.tgz#24d9768c63d253a56ecff93845b44b4df1d52771" - dependencies: - babel-runtime "^6.26.0" +common-tags@1.8.0: + version "1.8.0" + resolved "https://registry.yarnpkg.com/common-tags/-/common-tags-1.8.0.tgz#8e3153e542d4a39e9b10554434afaaf98956a937" commondir@^1.0.1: version "1.0.1" @@ -2375,7 +2333,7 @@ concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" -concat-stream@^1.4.7, concat-stream@^1.5.0, concat-stream@^1.5.2, concat-stream@^1.6.0, concat-stream@^1.6.2: +concat-stream@^1.4.7, concat-stream@^1.5.0, concat-stream@^1.5.2, concat-stream@^1.6.2: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" dependencies: @@ -2527,7 +2485,7 @@ cross-spawn@^4: lru-cache "^4.0.1" which "^1.2.9" -cross-spawn@^5.0.1, cross-spawn@^5.1.0: +cross-spawn@^5.0.1: version "5.1.0" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-5.1.0.tgz#e8bd0efee58fcff6f8f94510a0a554bbfa235449" dependencies: @@ -2673,7 +2631,7 @@ debug-log@^1.0.0, debug-log@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/debug-log/-/debug-log-1.0.1.tgz#2307632d4c04382b8df8a32f70b895046d52745f" -debug@2, debug@2.6.9, debug@^2.1.1, debug@^2.1.2, debug@^2.1.3, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.8, debug@^2.6.9, debug@~2.6.3: +debug@2, debug@2.6.9, debug@^2.1.1, debug@^2.1.2, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.8, debug@^2.6.9, debug@~2.6.3: version "2.6.9" resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" dependencies: @@ -2772,7 +2730,7 @@ deep-eql@^3.0.0: dependencies: type-detect "^4.0.0" -deep-equal@^1.0.0: +deep-equal@^1.0.0, deep-equal@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/deep-equal/-/deep-equal-1.0.1.tgz#f5d260292b660e084eff4cdbc9f08ad3247448b5" @@ -2788,18 +2746,14 @@ deepcopy@0.6.3: version "0.6.3" resolved "https://registry.yarnpkg.com/deepcopy/-/deepcopy-0.6.3.tgz#634780f2f8656ab771af8fa8431ed1ccee55c7b0" -deepmerge@2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-2.1.0.tgz#511a54fff405fc346f0240bb270a3e9533a31102" +deepmerge@2.1.1, deepmerge@^2.0.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-2.1.1.tgz#e862b4e45ea0555072bf51e7fd0d9845170ae768" deepmerge@^1.5.2: version "1.5.2" resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-1.5.2.tgz#10499d868844cdad4fee0842df8c7f6f0c95a753" -deepmerge@^2.0.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-2.1.1.tgz#e862b4e45ea0555072bf51e7fd0d9845170ae768" - default-require-extensions@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/default-require-extensions/-/default-require-extensions-1.0.0.tgz#f37ea15d3e13ffd9b437d33e1a75b5fb97874cb8" @@ -2957,19 +2911,19 @@ dirty-chai@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/dirty-chai/-/dirty-chai-2.0.1.tgz#6b2162ef17f7943589da840abc96e75bda01aff3" -dispensary@0.18.0: - version "0.18.0" - resolved "https://registry.yarnpkg.com/dispensary/-/dispensary-0.18.0.tgz#ecf4fb672afb1cb16a1d2a50c993beab643af08a" +dispensary@0.21.0: + version "0.21.0" + resolved "https://registry.yarnpkg.com/dispensary/-/dispensary-0.21.0.tgz#da8d625d722a03ced11f3e6b6aec3508d2fc8511" dependencies: array-from "~2.1.1" async "~2.6.0" natural-compare-lite "~1.4.0" - pino "~4.16.1" - request "~2.85.0" + pino "~4.17.3" + request "~2.87.0" semver "~5.5.0" sha.js "~2.4.4" source-map-support "~0.5.4" - yargs "~11.0.0" + yargs "~12.0.1" dns-packet@^4.0.0: version "4.2.0" @@ -2982,17 +2936,6 @@ doc-sniff@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/doc-sniff/-/doc-sniff-1.0.1.tgz#04eef054d8cf8c2d301386abc7fc58b549e398c8" -doctoc@1.3.1: - version "1.3.1" - resolved "https://registry.yarnpkg.com/doctoc/-/doctoc-1.3.1.tgz#f012e3603e3156254c2ef22ac88c7190f55426ba" - dependencies: - anchor-markdown-header "^0.5.5" - htmlparser2 "~3.9.2" - markdown-to-ast "~3.4.0" - minimist "~1.2.0" - underscore "~1.8.3" - update-section "^0.3.0" - doctrine@1.5.0, doctrine@^1.2.2: version "1.5.0" resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-1.5.0.tgz#379dce730f6166f76cefa4e6707a159b02c5a6fa" @@ -3150,10 +3093,6 @@ email-validator@^2.0.3: version "2.0.4" resolved "https://registry.yarnpkg.com/email-validator/-/email-validator-2.0.4.tgz#b8dfaa5d0dae28f1b03c95881d904d4e40bfe7ed" -emoji-regex@~6.1.0: - version "6.1.3" - resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-6.1.3.tgz#ec79a3969b02d2ecf2b72254279bf99bc7a83932" - emojis-list@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/emojis-list/-/emojis-list-2.1.0.tgz#4daa4d9db00f9819880c79fa457ae5b09a1fd389" @@ -3257,7 +3196,7 @@ error-ex@^1.2.0, error-ex@^1.3.1: dependencies: is-arrayish "^0.2.1" -es-abstract@^1.4.3, es-abstract@^1.7.0: +es-abstract@^1.10.0, es-abstract@^1.4.3, es-abstract@^1.7.0: version "1.12.0" resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.12.0.tgz#9dbbdd27c6856f0001421ca18782d786bf8a6165" dependencies: @@ -3461,13 +3400,6 @@ eslint-scope@3.7.1: esrecurse "^4.1.0" estraverse "^4.1.1" -eslint-scope@^3.7.1: - version "3.7.3" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.3.tgz#bb507200d3d17f60247636160b4826284b108535" - dependencies: - esrecurse "^4.1.0" - estraverse "^4.1.1" - eslint-scope@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-4.0.0.tgz#50bf3071e9338bcdc43331794a0cb533f0136172" @@ -3479,48 +3411,48 @@ eslint-visitor-keys@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" -eslint@4.19.1: - version "4.19.1" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.19.1.tgz#32d1d653e1d90408854bfb296f076ec7e186a300" +eslint@5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-5.0.1.tgz#109b90ab7f7a736f54e0f341c8bb9d09777494c3" dependencies: - ajv "^5.3.0" - babel-code-frame "^6.22.0" + ajv "^6.5.0" + babel-code-frame "^6.26.0" chalk "^2.1.0" - concat-stream "^1.6.0" - cross-spawn "^5.1.0" + cross-spawn "^6.0.5" debug "^3.1.0" doctrine "^2.1.0" - eslint-scope "^3.7.1" + eslint-scope "^4.0.0" eslint-visitor-keys "^1.0.0" - espree "^3.5.4" - esquery "^1.0.0" + espree "^4.0.0" + esquery "^1.0.1" esutils "^2.0.2" file-entry-cache "^2.0.0" functional-red-black-tree "^1.0.1" glob "^7.1.2" - globals "^11.0.1" + globals "^11.5.0" ignore "^3.3.3" imurmurhash "^0.1.4" - inquirer "^3.0.6" - is-resolvable "^1.0.0" - js-yaml "^3.9.1" + inquirer "^5.2.0" + is-resolvable "^1.1.0" + js-yaml "^3.11.0" json-stable-stringify-without-jsonify "^1.0.1" levn "^0.3.0" - lodash "^4.17.4" - minimatch "^3.0.2" + lodash "^4.17.5" + minimatch "^3.0.4" mkdirp "^0.5.1" natural-compare "^1.4.0" optionator "^0.8.2" path-is-inside "^1.0.2" pluralize "^7.0.0" progress "^2.0.0" - regexpp "^1.0.1" + regexpp "^1.1.0" require-uncached "^1.0.3" - semver "^5.3.0" + semver "^5.5.0" + string.prototype.matchall "^2.0.0" strip-ansi "^4.0.0" - strip-json-comments "~2.0.1" - table "4.0.2" - text-table "~0.2.0" + strip-json-comments "^2.0.1" + table "^4.0.3" + text-table "^0.2.0" eslint@^3.7.1, eslint@~3.19.0: version "3.19.0" @@ -3562,13 +3494,20 @@ eslint@^3.7.1, eslint@~3.19.0: text-table "~0.2.0" user-home "^2.0.0" -espree@^3.4.0, espree@^3.5.4: +espree@^3.4.0: version "3.5.4" resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.4.tgz#b0f447187c8a8bed944b815a660bddf5deb5d1a7" dependencies: acorn "^5.5.0" acorn-jsx "^3.0.0" +espree@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/espree/-/espree-4.0.0.tgz#253998f20a0f82db5d866385799d912a83a36634" + dependencies: + acorn "^5.6.0" + acorn-jsx "^4.1.1" + esprima@3.1.3, esprima@3.x.x, esprima@^3.1.3: version "3.1.3" resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633" @@ -3577,7 +3516,7 @@ esprima@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" -esquery@^1.0.0: +esquery@^1.0.0, esquery@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" dependencies: @@ -3771,7 +3710,7 @@ extend@3, extend@^3.0.0, extend@~3.0.1: version "3.0.2" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" -external-editor@^2.0.4: +external-editor@^2.0.4, external-editor@^2.1.0: version "2.2.0" resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.2.0.tgz#045511cfd8d133f3846673d1047c154e214ad3d5" dependencies: @@ -3830,9 +3769,11 @@ fast-json-parse@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/fast-json-parse/-/fast-json-parse-1.0.3.tgz#43e5c61ee4efa9265633046b770fb682a7577c4d" -fast-json-patch@^1.0.0: - version "1.2.2" - resolved "https://registry.yarnpkg.com/fast-json-patch/-/fast-json-patch-1.2.2.tgz#d377d97c6911dbdd2a1c80bfacda048a4f83bbf9" +fast-json-patch@^2.0.6: + version "2.0.6" + resolved "https://registry.yarnpkg.com/fast-json-patch/-/fast-json-patch-2.0.6.tgz#86fff8f8662391aa819722864d632e603e6ee605" + dependencies: + deep-equal "^1.0.1" fast-json-stable-stringify@^2.0.0: version "2.0.0" @@ -3842,15 +3783,17 @@ fast-levenshtein@~2.0.4: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" +fast-redact@^1.1.13: + version "1.1.13" + resolved "https://registry.yarnpkg.com/fast-redact/-/fast-redact-1.1.13.tgz#b74ed0dbe3c9f5e1f82350dc467db92389548a06" + fast-safe-stringify@^1.0.8, fast-safe-stringify@^1.2.3: version "1.2.3" resolved "https://registry.yarnpkg.com/fast-safe-stringify/-/fast-safe-stringify-1.2.3.tgz#9fe22c37fb2f7f86f06b8f004377dbf8f1ee7bc1" -fd-slicer@~1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/fd-slicer/-/fd-slicer-1.0.1.tgz#8b5bcbd9ec327c5041bf9ab023fd6750f1177e65" - dependencies: - pend "~1.2.0" +fast-safe-stringify@^2.0.4: + version "2.0.5" + resolved "https://registry.yarnpkg.com/fast-safe-stringify/-/fast-safe-stringify-2.0.5.tgz#cdb2d02d41329afbe67eff073598811d482609e3" fd-slicer@~1.1.0: version "1.1.0" @@ -4214,7 +4157,7 @@ fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" -fsevents@^1.2.2: +fsevents@1.2.4, fsevents@^1.2.2: version "1.2.4" resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.4.tgz#f41dcb1af2582af3692da36fc55cbd8e1041c426" dependencies: @@ -4441,7 +4384,7 @@ global@^4.3.1, global@^4.3.2: min-document "^2.19.0" process "~0.5.1" -globals@^11.0.1, globals@^11.1.0: +globals@^11.1.0, globals@^11.5.0: version "11.7.0" resolved "https://registry.yarnpkg.com/globals/-/globals-11.7.0.tgz#a583faa43055b1aca771914bf68258e2fc125673" @@ -4650,7 +4593,7 @@ hashlru@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/hashlru/-/hashlru-2.2.1.tgz#10f2099a0d7c05a40f2beaf5c1d39cf2f7dabf36" -hawk@^6.0.2, hawk@~6.0.2: +hawk@^6.0.2: version "6.0.2" resolved "https://registry.yarnpkg.com/hawk/-/hawk-6.0.2.tgz#af4d914eb065f9b5ce4d9d11c1cb2126eecc3038" dependencies: @@ -4706,7 +4649,7 @@ html-comment-regex@^1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/html-comment-regex/-/html-comment-regex-1.1.1.tgz#668b93776eaae55ebde8f3ad464b307a4963625e" -htmlparser2@^3.9.1, htmlparser2@~3.9.2: +htmlparser2@^3.9.1: version "3.9.2" resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-3.9.2.tgz#1bdf87acca0f3f9e53fa4fcceb0f4b4cbb00b338" dependencies: @@ -4904,7 +4847,7 @@ inquirer@^0.12.0: strip-ansi "^3.0.0" through "^2.3.6" -inquirer@^3.0.0, inquirer@^3.0.6: +inquirer@^3.0.0: version "3.3.0" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-3.3.0.tgz#9dd2f2ad765dcab1ff0443b491442a20ba227dc9" dependencies: @@ -4923,6 +4866,24 @@ inquirer@^3.0.0, inquirer@^3.0.6: strip-ansi "^4.0.0" through "^2.3.6" +inquirer@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-5.2.0.tgz#db350c2b73daca77ff1243962e9f22f099685726" + dependencies: + ansi-escapes "^3.0.0" + chalk "^2.0.0" + cli-cursor "^2.1.0" + cli-width "^2.0.0" + external-editor "^2.1.0" + figures "^2.0.0" + lodash "^4.3.0" + mute-stream "0.0.7" + run-async "^2.2.0" + rxjs "^5.5.2" + string-width "^2.1.0" + strip-ansi "^4.0.0" + through "^2.3.6" + inquirer@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-6.0.0.tgz#e8c20303ddc15bbfc2c12a6213710ccd9e1413d8" @@ -5460,17 +5421,6 @@ is-accessor-descriptor@^1.0.0: dependencies: kind-of "^6.0.0" -is-alphabetical@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-alphabetical/-/is-alphabetical-1.0.2.tgz#1fa6e49213cb7885b75d15862fb3f3d96c884f41" - -is-alphanumerical@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-alphanumerical/-/is-alphanumerical-1.0.2.tgz#1138e9ae5040158dc6ff76b820acd6b7a181fd40" - dependencies: - is-alphabetical "^1.0.0" - is-decimal "^1.0.0" - is-arrayish@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" @@ -5529,10 +5479,6 @@ is-date-object@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.1.tgz#9aa20eb6aeebbff77fbd33e74ca01b33581d3a16" -is-decimal@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-decimal/-/is-decimal-1.0.2.tgz#894662d6a8709d307f3a276ca4339c8fa5dff0ff" - is-descriptor@^0.1.0: version "0.1.6" resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-0.1.6.tgz#366d8240dde487ca51823b1ab9f07a10a78251ca" @@ -5595,10 +5541,6 @@ is-hex-prefixed@1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz#7d8d37e6ad77e5d127148913c573e082d777f554" -is-hexadecimal@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-hexadecimal/-/is-hexadecimal-1.0.2.tgz#b6e710d7d07bb66b98cb8cece5c9b4921deeb835" - is-installed-globally@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/is-installed-globally/-/is-installed-globally-0.1.0.tgz#0dfd98f5a9111716dd535dda6492f67bf3d25a80" @@ -5721,7 +5663,7 @@ is-relative@^0.1.0: version "0.1.3" resolved "https://registry.yarnpkg.com/is-relative/-/is-relative-0.1.3.tgz#905fee8ae86f45b3ec614bc3c15c869df0876e82" -is-resolvable@^1.0.0: +is-resolvable@^1.0.0, is-resolvable@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88" @@ -5921,7 +5863,7 @@ js-tokens@^3.0.0, js-tokens@^3.0.2: version "4.0.0" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" -js-yaml@^3.5.1, js-yaml@^3.5.3, js-yaml@^3.9.1: +js-yaml@^3.11.0, js-yaml@^3.5.1, js-yaml@^3.5.3: version "3.12.0" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.12.0.tgz#eaed656ec8344f10f527c6bfa1b6e2244de167d1" dependencies: @@ -6917,10 +6859,6 @@ long@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/long/-/long-3.2.0.tgz#d821b7138ca1cb581c172990ef14db200b5c474b" -longest-streak@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/longest-streak/-/longest-streak-1.0.0.tgz#d06597c4d4c31b52ccb1f5d8f8fe7148eafd6965" - longest@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/longest/-/longest-1.0.1.tgz#30a0b2da38f73770e8294a0d22e6625ed77d0097" @@ -7017,19 +6955,6 @@ map-visit@^1.0.0: dependencies: object-visit "^1.0.0" -markdown-table@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/markdown-table/-/markdown-table-0.4.0.tgz#890c2c1b3bfe83fb00e4129b8e4cfe645270f9d1" - -markdown-to-ast@~3.4.0: - version "3.4.0" - resolved "https://registry.yarnpkg.com/markdown-to-ast/-/markdown-to-ast-3.4.0.tgz#0e2cba81390b0549a9153ec3b0d915b61c164be7" - dependencies: - debug "^2.1.3" - remark "^5.0.1" - structured-source "^3.0.2" - traverse "^0.6.6" - md5-hex@^1.2.0: version "1.3.0" resolved "https://registry.yarnpkg.com/md5-hex/-/md5-hex-1.3.0.tgz#d2c4afe983c4370662179b8cad145219135046c4" @@ -7235,7 +7160,7 @@ minimalistic-crypto-utils@^1.0.0, minimalistic-crypto-utils@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz#f6c00c1c0b082246e5c4d99dfb8c7c083b2b582a" -"minimatch@2 || 3", minimatch@3.0.4, minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: +"minimatch@2 || 3", minimatch@3.0.4, minimatch@^3.0.0, minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" dependencies: @@ -7252,7 +7177,7 @@ minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" -minimist@^1.1.0, minimist@^1.1.1, minimist@^1.2.0, minimist@~1.2.0: +minimist@^1.1.0, minimist@^1.1.1, minimist@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" @@ -7470,6 +7395,15 @@ multihashing-async@~0.5.1: murmurhash3js "^3.0.1" nodeify "^1.0.1" +multimatch@2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/multimatch/-/multimatch-2.1.0.tgz#9c7906a22fb4c02919e2f5f75161b4cdbd4b2a2b" + dependencies: + array-differ "^1.0.0" + array-union "^1.0.1" + arrify "^1.0.0" + minimatch "^3.0.0" + multistream-select@^0.14.1, multistream-select@~0.14.2: version "0.14.2" resolved "https://registry.yarnpkg.com/multistream-select/-/multistream-select-0.14.2.tgz#f31e0993d6109e3fbfb7902806acb0de1a16f3e5" @@ -7996,7 +7930,7 @@ on-load@^3.3.4: global "^4.3.2" nanoassert "^1.1.0" -once@^1.3.0, once@^1.3.1, once@^1.3.3, once@^1.4.0: +once@^1.3.0, once@^1.3.1, once@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" dependencies: @@ -8211,17 +8145,6 @@ parse-asn1@^5.0.0: evp_bytestokey "^1.0.0" pbkdf2 "^3.0.3" -parse-entities@^1.0.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/parse-entities/-/parse-entities-1.1.2.tgz#9eaf719b29dc3bd62246b4332009072e01527777" - dependencies: - character-entities "^1.0.0" - character-entities-legacy "^1.0.0" - character-reference-invalid "^1.0.0" - is-alphanumerical "^1.0.0" - is-decimal "^1.0.0" - is-hexadecimal "^1.0.0" - parse-json@4.0.0, parse-json@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0" @@ -8435,11 +8358,24 @@ pino-std-serializers@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/pino-std-serializers/-/pino-std-serializers-2.1.0.tgz#01953dcaecd5f43b331ecf2e312a49c9fd64851c" -pino@4.16.1, pino@~4.16.1: - version "4.16.1" - resolved "https://registry.yarnpkg.com/pino/-/pino-4.16.1.tgz#8bcb6b685ee4d4e26adfe79a05f12f6b46962d40" +pino@5.0.0-rc.4: + version "5.0.0-rc.4" + resolved "https://registry.yarnpkg.com/pino/-/pino-5.0.0-rc.4.tgz#33f669a98972bdf6666508888d08a891841f6c3b" dependencies: - chalk "^2.3.2" + fast-json-parse "^1.0.3" + fast-redact "^1.1.13" + fast-safe-stringify "^2.0.4" + flatstr "^1.0.5" + pino-std-serializers "^2.0.0" + pump "^3.0.0" + quick-format-unescaped "^3.0.0" + sonic-boom "^0.5.0" + +pino@~4.17.3: + version "4.17.6" + resolved "https://registry.yarnpkg.com/pino/-/pino-4.17.6.tgz#8c237f3a29f4104f89321c25037deab6a7998fb4" + dependencies: + chalk "^2.4.1" fast-json-parse "^1.0.3" fast-safe-stringify "^1.2.3" flatstr "^1.0.5" @@ -8512,13 +8448,13 @@ posix-character-classes@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" -postcss@6.0.19: - version "6.0.19" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-6.0.19.tgz#76a78386f670b9d9494a655bf23ac012effd1555" +postcss@6.0.23: + version "6.0.23" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-6.0.23.tgz#61c82cc328ac60e677645f979054eb98bc0e3324" dependencies: - chalk "^2.3.1" + chalk "^2.4.1" source-map "^0.6.1" - supports-color "^5.2.0" + supports-color "^5.4.0" postmsg-rpc@^2.4.0: version "2.4.0" @@ -8935,6 +8871,10 @@ quick-format-unescaped@^1.1.2: dependencies: fast-safe-stringify "^1.0.8" +quick-format-unescaped@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/quick-format-unescaped/-/quick-format-unescaped-3.0.0.tgz#21e7fdc5b08b079ef71ed0728ed0725e58671e41" + quick-lru@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-1.1.0.tgz#4360b17c61136ad38078397ff11416e186dcfbb8" @@ -9125,7 +9065,13 @@ regex-not@^1.0.0, regex-not@^1.0.2: extend-shallow "^3.0.2" safe-regex "^1.1.0" -regexpp@^1.0.1: +regexp.prototype.flags@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/regexp.prototype.flags/-/regexp.prototype.flags-1.2.0.tgz#6b30724e306a27833eeb171b66ac8890ba37e41c" + dependencies: + define-properties "^1.1.2" + +regexpp@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-1.1.0.tgz#0e3516dd0b7904f413d2d4193dce4618c3a689ab" @@ -9171,41 +9117,6 @@ relaxed-json@1.0.1: chalk "^1.0.0" commander "^2.6.0" -remark-parse@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/remark-parse/-/remark-parse-1.1.0.tgz#c3ca10f9a8da04615c28f09aa4e304510526ec21" - dependencies: - collapse-white-space "^1.0.0" - extend "^3.0.0" - parse-entities "^1.0.2" - repeat-string "^1.5.4" - trim "0.0.1" - trim-trailing-lines "^1.0.0" - unherit "^1.0.4" - unist-util-remove-position "^1.0.0" - vfile-location "^2.0.0" - -remark-stringify@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/remark-stringify/-/remark-stringify-1.1.0.tgz#a7105e25b9ee2bf9a49b75d2c423f11b06ae2092" - dependencies: - ccount "^1.0.0" - extend "^3.0.0" - longest-streak "^1.0.0" - markdown-table "^0.4.0" - parse-entities "^1.0.2" - repeat-string "^1.5.4" - stringify-entities "^1.0.1" - unherit "^1.0.4" - -remark@^5.0.1: - version "5.1.0" - resolved "https://registry.yarnpkg.com/remark/-/remark-5.1.0.tgz#cb463bd3dbcb4b99794935eee1cf71d7a8e3068c" - dependencies: - remark-parse "^1.1.0" - remark-stringify "^1.1.0" - unified "^4.1.1" - "remedial@>= 1.0.7", remedial@^1.0.7: version "1.0.8" resolved "https://registry.yarnpkg.com/remedial/-/remedial-1.0.8.tgz#a5e4fd52a0e4956adbaf62da63a5a46a78c578a0" @@ -9222,7 +9133,7 @@ repeat-element@^1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.2.tgz#ef089a178d1483baae4d93eb98b4f9e4e11d990a" -repeat-string@^1.5.2, repeat-string@^1.5.4, repeat-string@^1.6.1: +repeat-string@^1.5.2, repeat-string@^1.6.1: version "1.6.1" resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" @@ -9232,7 +9143,7 @@ repeating@^2.0.0: dependencies: is-finite "^1.0.0" -request@2.87.0, request@^2.83.0, request@^2.87.0: +request@2.87.0, request@^2.83.0, request@^2.87.0, request@~2.87.0: version "2.87.0" resolved "https://registry.yarnpkg.com/request/-/request-2.87.0.tgz#32f00235cd08d482b4d0d68db93a829c0ed5756e" dependencies: @@ -9257,33 +9168,6 @@ request@2.87.0, request@^2.83.0, request@^2.87.0: tunnel-agent "^0.6.0" uuid "^3.1.0" -request@~2.85.0: - version "2.85.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.85.0.tgz#5a03615a47c61420b3eb99b7dba204f83603e1fa" - dependencies: - aws-sign2 "~0.7.0" - aws4 "^1.6.0" - caseless "~0.12.0" - combined-stream "~1.0.5" - extend "~3.0.1" - forever-agent "~0.6.1" - form-data "~2.3.1" - har-validator "~5.0.3" - hawk "~6.0.2" - http-signature "~1.2.0" - is-typedarray "~1.0.0" - isstream "~0.1.2" - json-stringify-safe "~5.0.1" - mime-types "~2.1.17" - oauth-sign "~0.8.2" - performance-now "^2.1.0" - qs "~6.5.1" - safe-buffer "^5.1.1" - stringstream "~0.0.5" - tough-cookie "~2.3.3" - tunnel-agent "^0.6.0" - uuid "^3.1.0" - require-directory@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" @@ -9429,6 +9313,12 @@ rx-lite@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-3.1.2.tgz#19ce502ca572665f3b647b10939f97fd1615f102" +rxjs@^5.5.2: + version "5.5.11" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-5.5.11.tgz#f733027ca43e3bec6b994473be4ab98ad43ced87" + dependencies: + symbol-observable "1.0.1" + rxjs@^6.1.0: version "6.2.2" resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.2.2.tgz#eb75fa3c186ff5289907d06483a77884586e1cf9" @@ -9646,9 +9536,9 @@ shelljs@0.7.7: interpret "^1.0.0" rechoir "^0.6.2" -shelljs@0.8.1: - version "0.8.1" - resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.8.1.tgz#729e038c413a2254c4078b95ed46e0397154a9f1" +shelljs@0.8.2, shelljs@^0.8.1: + version "0.8.2" + resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.8.2.tgz#345b7df7763f4c2340d584abb532c5f752ca9e35" dependencies: glob "^7.0.0" interpret "^1.0.0" @@ -9662,14 +9552,6 @@ shelljs@^0.7.5: interpret "^1.0.0" rechoir "^0.6.2" -shelljs@^0.8.1: - version "0.8.2" - resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.8.2.tgz#345b7df7763f4c2340d584abb532c5f752ca9e35" - dependencies: - glob "^7.0.0" - interpret "^1.0.0" - rechoir "^0.6.2" - shellwords@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b" @@ -9921,9 +9803,9 @@ snyk-policy@1.12.0: snyk-try-require "^1.1.1" then-fs "^2.0.0" -snyk-python-plugin@1.6.1: - version "1.6.1" - resolved "https://registry.yarnpkg.com/snyk-python-plugin/-/snyk-python-plugin-1.6.1.tgz#eb3194b37b4710edebee3406a2adea4a0159e89f" +snyk-python-plugin@1.8.0: + version "1.8.0" + resolved "https://registry.yarnpkg.com/snyk-python-plugin/-/snyk-python-plugin-1.8.0.tgz#e38c57521616cfb36743fca0f1d777c8994cb8d0" dependencies: tmp "0.0.33" @@ -9974,9 +9856,9 @@ snyk-try-require@1.3.1, snyk-try-require@^1.1.1: lru-cache "^4.0.0" then-fs "^2.0.0" -snyk@^1.78.1: - version "1.89.0" - resolved "https://registry.yarnpkg.com/snyk/-/snyk-1.89.0.tgz#254fa9bef8bbf0e1d5b10540312fcce4aa71507c" +snyk@^1.88.2: + version "1.90.0" + resolved "https://registry.yarnpkg.com/snyk/-/snyk-1.90.0.tgz#ba37f66484e18a56fc98f64d565a517a53fc8562" dependencies: abbrev "^1.1.1" ansi-escapes "^3.1.0" @@ -10002,7 +9884,7 @@ snyk@^1.78.1: snyk-nuget-plugin "1.6.3" snyk-php-plugin "1.5.1" snyk-policy "1.12.0" - snyk-python-plugin "1.6.1" + snyk-python-plugin "1.8.0" snyk-resolve "1.0.1" snyk-resolve-deps "3.1.0" snyk-sbt-plugin "1.3.0" @@ -10078,6 +9960,12 @@ socks@^1.1.10: ip "^1.1.4" smart-buffer "^1.0.13" +sonic-boom@^0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/sonic-boom/-/sonic-boom-0.5.0.tgz#06b28c5bde0703c2ae5009ab2ef3f4749052ff73" + dependencies: + flatstr "^1.0.5" + source-list-map@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/source-list-map/-/source-list-map-2.0.0.tgz#aaa47403f7b245a92fbc97ea08f250d6087ed085" @@ -10367,6 +10255,16 @@ string-width@^1.0.1, string-width@^1.0.2: is-fullwidth-code-point "^2.0.0" strip-ansi "^4.0.0" +string.prototype.matchall@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/string.prototype.matchall/-/string.prototype.matchall-2.0.0.tgz#2af8fe3d2d6dc53ca2a59bd376b089c3c152b3c8" + dependencies: + define-properties "^1.1.2" + es-abstract "^1.10.0" + function-bind "^1.1.1" + has-symbols "^1.0.0" + regexp.prototype.flags "^1.2.0" + string.prototype.padend@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/string.prototype.padend/-/string.prototype.padend-3.0.0.tgz#f3aaef7c1719f170c5eab1c32bf780d96e21f2f0" @@ -10385,19 +10283,6 @@ string_decoder@~0.10.x: version "0.10.31" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" -stringify-entities@^1.0.1: - version "1.3.2" - resolved "https://registry.yarnpkg.com/stringify-entities/-/stringify-entities-1.3.2.tgz#a98417e5471fd227b3e45d3db1861c11caf668f7" - dependencies: - character-entities-html4 "^1.0.0" - character-entities-legacy "^1.0.0" - is-alphanumerical "^1.0.0" - is-hexadecimal "^1.0.0" - -stringstream@~0.0.5: - version "0.0.6" - resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.6.tgz#7880225b0d4ad10e30927d167a1d6f2fd3b33a72" - strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" @@ -10457,16 +10342,10 @@ strip-indent@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/strip-indent/-/strip-indent-2.0.0.tgz#5ef8db295d01e6ed6cbf7aab96998d7822527b68" -strip-json-comments@2.0.1, strip-json-comments@~2.0.1: +strip-json-comments@2.0.1, strip-json-comments@^2.0.1, strip-json-comments@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" -structured-source@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/structured-source/-/structured-source-3.0.2.tgz#dd802425e0f53dc4a6e7aca3752901a1ccda7af5" - dependencies: - boundary "^1.0.1" - subtext@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/subtext/-/subtext-5.0.0.tgz#9c3f083018bb1586b167ad8cfd87083f5ccdfe0f" @@ -10498,7 +10377,7 @@ supports-color@3.1.2: dependencies: has-flag "^1.0.0" -supports-color@5.4.0, supports-color@^5.1.0, supports-color@^5.2.0, supports-color@^5.3.0, supports-color@^5.4.0: +supports-color@5.4.0, supports-color@^5.1.0, supports-color@^5.3.0, supports-color@^5.4.0: version "5.4.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54" dependencies: @@ -10514,21 +10393,14 @@ supports-color@^3.1.2: dependencies: has-flag "^1.0.0" +symbol-observable@1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/symbol-observable/-/symbol-observable-1.0.1.tgz#8340fc4702c3122df5d22288f88283f513d3fdd4" + symbol-observable@^1.1.0: version "1.2.0" resolved "https://registry.yarnpkg.com/symbol-observable/-/symbol-observable-1.2.0.tgz#c22688aed4eab3cdc2dfeacbb561660560a00804" -table@4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/table/-/table-4.0.2.tgz#a33447375391e766ad34d3486e6e2aedc84d2e36" - dependencies: - ajv "^5.2.3" - ajv-keywords "^2.1.0" - chalk "^2.1.0" - lodash "^4.17.4" - slice-ansi "1.0.0" - string-width "^2.1.1" - table@^3.7.8: version "3.8.3" resolved "https://registry.yarnpkg.com/table/-/table-3.8.3.tgz#2bbc542f0fda9861a755d3947fefd8b3f513855f" @@ -10540,6 +10412,17 @@ table@^3.7.8: slice-ansi "0.0.4" string-width "^2.0.0" +table@^4.0.3: + version "4.0.3" + resolved "https://registry.yarnpkg.com/table/-/table-4.0.3.tgz#00b5e2b602f1794b9acaf9ca908a76386a7813bc" + dependencies: + ajv "^6.0.1" + ajv-keywords "^3.0.0" + chalk "^2.1.0" + lodash "^4.17.4" + slice-ansi "1.0.0" + string-width "^2.1.1" + tachyons@4.9.1: version "4.9.1" resolved "https://registry.yarnpkg.com/tachyons/-/tachyons-4.9.1.tgz#f88d7059d6e53c833bf9351a26f18314c8fdc76a" @@ -10651,7 +10534,7 @@ text-encoding@^0.6.4: version "0.6.4" resolved "https://registry.yarnpkg.com/text-encoding/-/text-encoding-0.6.4.tgz#e399a982257a276dae428bb92845cb71bdc26d19" -text-table@~0.2.0: +text-table@^0.2.0, text-table@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" @@ -10822,7 +10705,7 @@ traverse@0.4.x: version "0.4.6" resolved "https://registry.yarnpkg.com/traverse/-/traverse-0.4.6.tgz#d04b2280e4c792a5815429ef7b8b60c64c9ccc34" -traverse@^0.6.6, traverse@~0.6.6: +traverse@~0.6.6: version "0.6.6" resolved "https://registry.yarnpkg.com/traverse/-/traverse-0.6.6.tgz#cbdf560fd7b9af632502fed40f918c157ea97137" @@ -10834,18 +10717,6 @@ trim-right@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" -trim-trailing-lines@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/trim-trailing-lines/-/trim-trailing-lines-1.1.1.tgz#e0ec0810fd3c3f1730516b45f49083caaf2774d9" - -trim@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/trim/-/trim-0.0.1.tgz#5858547f6b290757ee95cccc666fb50084c460dd" - -trough@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/trough/-/trough-1.0.2.tgz#7f1663ec55c480139e2de5e486c6aef6cc24a535" - truncate-utf8-bytes@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/truncate-utf8-bytes/-/truncate-utf8-bytes-1.0.2.tgz#405923909592d56f78a5818434b0b78489ca5f2b" @@ -10960,28 +10831,6 @@ underscore@~1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.6.0.tgz#8b38b10cacdef63337b8b24e4ff86d45aea529a8" -underscore@~1.8.3: - version "1.8.3" - resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.8.3.tgz#4f3fb53b106e6097fcf9cb4109f2a5e9bdfa5022" - -unherit@^1.0.4: - version "1.1.1" - resolved "https://registry.yarnpkg.com/unherit/-/unherit-1.1.1.tgz#132748da3e88eab767e08fabfbb89c5e9d28628c" - dependencies: - inherits "^2.0.1" - xtend "^4.0.1" - -unified@^4.1.1: - version "4.2.1" - resolved "https://registry.yarnpkg.com/unified/-/unified-4.2.1.tgz#76ff43aa8da430f6e7e4a55c84ebac2ad2cfcd2e" - dependencies: - bail "^1.0.0" - extend "^3.0.0" - has "^1.0.1" - once "^1.3.3" - trough "^1.0.0" - vfile "^1.0.0" - union-value@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.0.tgz#5c71c34cb5bad5dcebe3ea0cd08207ba5aa1aea4" @@ -11013,22 +10862,6 @@ unique-string@^1.0.0: dependencies: crypto-random-string "^1.0.0" -unist-util-is@^2.1.1: - version "2.1.2" - resolved "https://registry.yarnpkg.com/unist-util-is/-/unist-util-is-2.1.2.tgz#1193fa8f2bfbbb82150633f3a8d2eb9a1c1d55db" - -unist-util-remove-position@^1.0.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/unist-util-remove-position/-/unist-util-remove-position-1.1.2.tgz#86b5dad104d0bbfbeb1db5f5c92f3570575c12cb" - dependencies: - unist-util-visit "^1.1.0" - -unist-util-visit@^1.1.0: - version "1.3.1" - resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-1.3.1.tgz#c019ac9337a62486be58531bc27e7499ae7d55c7" - dependencies: - unist-util-is "^2.1.1" - universalify@^0.1.0: version "0.1.2" resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66" @@ -11048,11 +10881,7 @@ unzip-response@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/unzip-response/-/unzip-response-2.0.1.tgz#d2f0f737d16b0615e72a6935ed04214572d56f97" -upath@1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/upath/-/upath-1.0.5.tgz#02cab9ecebe95bbec6d5fc2566325725ab6d1a73" - -upath@^1.0.5: +upath@1.1.0, upath@^1.0.5: version "1.1.0" resolved "https://registry.yarnpkg.com/upath/-/upath-1.1.0.tgz#35256597e46a581db4793d0ce47fa9aebfc9fabd" @@ -11085,10 +10914,6 @@ update-notifier@^2.5.0: semver-diff "^2.0.0" xdg-basedir "^3.0.0" -update-section@^0.3.0: - version "0.3.3" - resolved "https://registry.yarnpkg.com/update-section/-/update-section-0.3.3.tgz#458f17820d37820dc60e20b86d94391b00123158" - upper-case@^1.1.1: version "1.1.3" resolved "https://registry.yarnpkg.com/upper-case/-/upper-case-1.1.3.tgz#f6b4501c2ec4cdd26ba78be7222961de77621598" @@ -11201,14 +11026,6 @@ verror@1.10.0: core-util-is "1.0.2" extsprintf "^1.2.0" -vfile-location@^2.0.0: - version "2.0.3" - resolved "https://registry.yarnpkg.com/vfile-location/-/vfile-location-2.0.3.tgz#083ba80e50968e8d420be49dd1ea9a992131df77" - -vfile@^1.0.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/vfile/-/vfile-1.4.0.tgz#c0fd6fa484f8debdb771f68c31ed75d88da97fe7" - vise@2.x.x: version "2.0.2" resolved "https://registry.yarnpkg.com/vise/-/vise-2.0.2.tgz#6b08e8fb4cb76e3a50cd6dd0ec37338e811a0d39" @@ -11249,14 +11066,14 @@ wcwidth@^1.0.0: dependencies: defaults "^1.0.3" -web-ext@2.7.0: - version "2.7.0" - resolved "https://registry.yarnpkg.com/web-ext/-/web-ext-2.7.0.tgz#bcfac53f0416e15cf7be6ff532e690f67fac865c" +web-ext@2.8.0: + version "2.8.0" + resolved "https://registry.yarnpkg.com/web-ext/-/web-ext-2.8.0.tgz#5ac19121805a321d6122f82fac65b6a082bb47c5" dependencies: "@cliqz-oss/firefox-client" "0.3.1" "@cliqz-oss/node-firefox-connect" "1.2.1" adbkit "2.11.0" - addons-linter "1.0.0" + addons-linter "1.2.6" babel-polyfill "6.26.0" babel-runtime "6.26.0" bunyan "1.8.12" @@ -11269,8 +11086,8 @@ web-ext@2.7.0: firefox-profile "1.1.0" fx-runner "1.0.9" git-rev-sync "1.9.1" - minimatch "3.0.4" mkdirp "0.5.1" + multimatch "2.1.0" mz "2.7.0" node-notifier "5.2.1" opn "5.3.0" @@ -11379,9 +11196,9 @@ webpack@4.16.1: version "2.2.0" resolved "https://codeload.github.com/ipfs/webrtcsupport/tar.gz/0669f576582c53a3a42aa5ac014fcc5966809615" -whatwg-url@6.4.1: - version "6.4.1" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-6.4.1.tgz#fdb94b440fd4ad836202c16e9737d511f012fd67" +whatwg-url@6.5.0: + version "6.5.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-6.5.0.tgz#f2df02bff176fd65070df74ad5ccbb5a199965a8" dependencies: lodash.sortby "^4.7.0" tr46 "^1.0.1" @@ -11632,9 +11449,9 @@ yargs-promise@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/yargs-promise/-/yargs-promise-1.1.0.tgz#97ebb5198df734bb3b11745133ae5b501b16ab1f" -yargs@11.0.0, yargs@~11.0.0: - version "11.0.0" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-11.0.0.tgz#c052931006c5eee74610e5fc0354bedfd08a201b" +yargs@11.1.0: + version "11.1.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-11.1.0.tgz#90b869934ed6e871115ea2ff58b03f4724ed2d77" dependencies: cliui "^4.0.0" decamelize "^1.1.1" @@ -11649,13 +11466,13 @@ yargs@11.0.0, yargs@~11.0.0: y18n "^3.2.1" yargs-parser "^9.0.2" -yargs@11.1.0: - version "11.1.0" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-11.1.0.tgz#90b869934ed6e871115ea2ff58b03f4724ed2d77" +yargs@12.0.1, yargs@^12.0.1, yargs@~12.0.1: + version "12.0.1" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-12.0.1.tgz#6432e56123bb4e7c3562115401e98374060261c2" dependencies: cliui "^4.0.0" - decamelize "^1.1.1" - find-up "^2.1.0" + decamelize "^2.0.0" + find-up "^3.0.0" get-caller-file "^1.0.1" os-locale "^2.0.0" require-directory "^2.1.1" @@ -11663,8 +11480,8 @@ yargs@11.1.0: set-blocking "^2.0.0" string-width "^2.0.0" which-module "^2.0.0" - y18n "^3.2.1" - yargs-parser "^9.0.2" + y18n "^3.2.1 || ^4.0.0" + yargs-parser "^10.1.0" yargs@6.6.0: version "6.6.0" @@ -11684,23 +11501,6 @@ yargs@6.6.0: y18n "^3.2.1" yargs-parser "^4.2.0" -yargs@^12.0.1: - version "12.0.1" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-12.0.1.tgz#6432e56123bb4e7c3562115401e98374060261c2" - dependencies: - cliui "^4.0.0" - decamelize "^2.0.0" - find-up "^3.0.0" - get-caller-file "^1.0.1" - os-locale "^2.0.0" - require-directory "^2.1.1" - require-main-filename "^1.0.1" - set-blocking "^2.0.0" - string-width "^2.0.0" - which-module "^2.0.0" - y18n "^3.2.1 || ^4.0.0" - yargs-parser "^10.1.0" - yargs@^3.19.0: version "3.32.0" resolved "https://registry.yarnpkg.com/yargs/-/yargs-3.32.0.tgz#03088e9ebf9e756b69751611d2a5ef591482c995" @@ -11722,12 +11522,12 @@ yargs@~3.10.0: decamelize "^1.0.0" window-size "0.1.0" -yauzl@2.9.1: - version "2.9.1" - resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.9.1.tgz#a81981ea70a57946133883f029c5821a89359a7f" +yauzl@2.9.2: + version "2.9.2" + resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.9.2.tgz#4fb1bc7ae1fc2f57037b54af6acc8fe1031c5b77" dependencies: buffer-crc32 "~0.2.3" - fd-slicer "~1.0.1" + fd-slicer "~1.1.0" yauzl@^2.4.2: version "2.10.0" From 8beea27a3a4dad45effb8bf6f15ab8bbd9fd9cbc Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 3 Aug 2018 10:58:18 -0700 Subject: [PATCH 14/31] feat(libdweb): run libdweb:build on win as a part of CI We want npm run libdweb work on MS Windows as well. --- ci/Jenkinsfile | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/ci/Jenkinsfile b/ci/Jenkinsfile index 179e67655..050016c21 100644 --- a/ci/Jenkinsfile +++ b/ci/Jenkinsfile @@ -78,6 +78,36 @@ parallel( }} }}}} }, + // run libdweb:build under windows as a smoke-test to ensure it can be built on that platform + "windows-libdweb": { + node(label: 'windows') { ansiColor('xterm') { withEnv(['CI=true']) { ws("${env.JOB_NAME}/windows-libdweb") { + def ciContext = 'continuous-integration/jenkins/windows/' + githubNotify description: 'Build in progress', status: 'PENDING', context: ciContext + cleanWs() + bat 'git config --global core.autocrlf input' + checkout scm + fileExists 'package.json' + nodejs(nodeVersion) { try { + stage('win:libdweb:build') { + // remove node_modules if any + bat 'del /s /q node_modules >nul 2>&1' + // https://github.com/yarnpkg/yarn/issues/3110#issuecomment-293347341 + bat 'npx yarn@1.7.0 config set msvs_version 2015 --global' + // run libdweb developer build as a smoke-test for windows + bat 'npm run ci:install' + bat 'npm run libdweb:build' + bat 'dir /s /b /o:gn build' + } + githubNotify description: 'Dev build looks good', status: 'SUCCESS', context: ciContext + } catch (err) { + echo "Caught: ${err}" + currentBuild.result = 'FAILURE' + githubNotify description: 'Dev build failed', status: 'FAILURE', context: ciContext + } finally { + cleanWs() + }} + }}}} + }, // run dev-build under macos as a smoke-test to ensure it can be built on that platform "macos": { node(label: 'macos') { ansiColor('xterm') { withEnv(['CI=true']) { ws("${env.JOB_NAME}/macos") { From 1d18fc50477bb65f7a08d21488499b68498c2b55 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 3 Aug 2018 11:06:59 -0700 Subject: [PATCH 15/31] feat(libdweb): run libdweb:build on mac during CI --- ci/Jenkinsfile | 38 ++++++-------------------------------- 1 file changed, 6 insertions(+), 32 deletions(-) diff --git a/ci/Jenkinsfile b/ci/Jenkinsfile index 050016c21..f31d9da9d 100644 --- a/ci/Jenkinsfile +++ b/ci/Jenkinsfile @@ -62,7 +62,9 @@ parallel( // https://github.com/yarnpkg/yarn/issues/3110#issuecomment-293347341 bat 'npx yarn@1.7.0 config set msvs_version 2015 --global' // run developer build as a smoke-test for windows - bat 'npm run dev-build' + // bat 'npm run dev-build' + bat 'npm run ci:install' + bat 'npm run libdweb:build' bat 'dir /s /b /o:gn build' } stage('win:test') { @@ -78,36 +80,6 @@ parallel( }} }}}} }, - // run libdweb:build under windows as a smoke-test to ensure it can be built on that platform - "windows-libdweb": { - node(label: 'windows') { ansiColor('xterm') { withEnv(['CI=true']) { ws("${env.JOB_NAME}/windows-libdweb") { - def ciContext = 'continuous-integration/jenkins/windows/' - githubNotify description: 'Build in progress', status: 'PENDING', context: ciContext - cleanWs() - bat 'git config --global core.autocrlf input' - checkout scm - fileExists 'package.json' - nodejs(nodeVersion) { try { - stage('win:libdweb:build') { - // remove node_modules if any - bat 'del /s /q node_modules >nul 2>&1' - // https://github.com/yarnpkg/yarn/issues/3110#issuecomment-293347341 - bat 'npx yarn@1.7.0 config set msvs_version 2015 --global' - // run libdweb developer build as a smoke-test for windows - bat 'npm run ci:install' - bat 'npm run libdweb:build' - bat 'dir /s /b /o:gn build' - } - githubNotify description: 'Dev build looks good', status: 'SUCCESS', context: ciContext - } catch (err) { - echo "Caught: ${err}" - currentBuild.result = 'FAILURE' - githubNotify description: 'Dev build failed', status: 'FAILURE', context: ciContext - } finally { - cleanWs() - }} - }}}} - }, // run dev-build under macos as a smoke-test to ensure it can be built on that platform "macos": { node(label: 'macos') { ansiColor('xterm') { withEnv(['CI=true']) { ws("${env.JOB_NAME}/macos") { @@ -120,7 +92,9 @@ parallel( stage('mac:dev-build') { sh 'rm -rf node_modules/' // run developer build as a smoke-test - sh 'npm run dev-build' + // sh 'npm run dev-build' + sh 'npm run ci:install' + sh 'npm run libdweb:build' sh 'ls -Rlh build' } stage('mac:test') { From 3133ad0423bf7ec11be7b744813c0c28302ace73 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 3 Aug 2018 11:20:36 -0700 Subject: [PATCH 16/31] fix(libdweb/ci): switch to dev yarn build --- ci/Jenkinsfile | 7 +- package.json | 2 +- yarn.lock | 197 +++++++++++++++++++++++++++++++------------------ 3 files changed, 132 insertions(+), 74 deletions(-) diff --git a/ci/Jenkinsfile b/ci/Jenkinsfile index f31d9da9d..fcb6d265a 100644 --- a/ci/Jenkinsfile +++ b/ci/Jenkinsfile @@ -1,6 +1,7 @@ import groovy.transform.Field // Global for which node version to use on macos and windows -@Field final String nodeVersion = '9.2.0' +// When in doubt, should follow https://github.com/ipfs/jenkins-libs/blob/master/vars/javascript.groovy +@Field final String nodeVersion = '8.11.3' // Run targets in parallel parallel( @@ -63,7 +64,7 @@ parallel( bat 'npx yarn@1.7.0 config set msvs_version 2015 --global' // run developer build as a smoke-test for windows // bat 'npm run dev-build' - bat 'npm run ci:install' + bat 'npx yarn@1.7.0' bat 'npm run libdweb:build' bat 'dir /s /b /o:gn build' } @@ -93,7 +94,7 @@ parallel( sh 'rm -rf node_modules/' // run developer build as a smoke-test // sh 'npm run dev-build' - sh 'npm run ci:install' + sh 'npx yarn@1.7.0' sh 'npm run libdweb:build' sh 'ls -Rlh build' } diff --git a/package.json b/package.json index ccf5f315e..0c109ab04 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,7 @@ "precommit": "run-s lint:standard", "prepush": "run-s clean build lint test", "firefox": "web-ext run --browser-console --url about:debugging", - "libdweb": "npm run ci:install && npm run libdweb:build && npm run libdweb:firefox", + "libdweb": "npx yarn@1.7.0 && npm run libdweb:build && npm run libdweb:firefox", "libdweb:build": "git submodule update --init --checkout --depth 1 libdweb && cross-env-shell RELEASE_CHANNEL=libdweb npm run dev-build", "libdweb:firefox": "npm run get-firefox-nightly && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=./firefox/firefox --browser-console --url about:debugging", "get-firefox-nightly": "shx test -e ./firefox/firefox || get-firefox -b nightly -e", diff --git a/yarn.lock b/yarn.lock index 94962282b..9d753b6d6 100644 --- a/yarn.lock +++ b/yarn.lock @@ -191,8 +191,8 @@ samsam "1.3.0" "@types/node@*": - version "10.5.2" - resolved "https://registry.yarnpkg.com/@types/node/-/node-10.5.2.tgz#f19f05314d5421fe37e74153254201a7bf00a707" + version "10.5.5" + resolved "https://registry.yarnpkg.com/@types/node/-/node-10.5.5.tgz#8e84d24e896cd77b0d4f73df274027e3149ec2ba" "@webassemblyjs/ast@1.5.13": version "1.5.13" @@ -779,8 +779,10 @@ asn1.js@^5.0.0: minimalistic-assert "^1.0.0" asn1@~0.2.3: - version "0.2.3" - resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.3.tgz#dac8787713c9966849fc8180777ebe9c1ddf3b86" + version "0.2.4" + resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.4.tgz#8d2475dfab553bb33e77b54e59e880bb8ce23136" + dependencies: + safer-buffer "~2.1.0" assert-plus@1.0.0, assert-plus@^1.0.0: version "1.0.0" @@ -1753,11 +1755,12 @@ bs58@=2.0.0: resolved "https://registry.yarnpkg.com/bs58/-/bs58-2.0.0.tgz#72b713bed223a0ac518bbda0e3ce3f4817f39eb5" bs58check@<3.0.0, bs58check@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/bs58check/-/bs58check-2.1.1.tgz#8a5d0e587af97b784bf9cbf1b29f454d82bc0222" + version "2.1.2" + resolved "https://registry.yarnpkg.com/bs58check/-/bs58check-2.1.2.tgz#53b018291228d82a5aa08e7d796fdafda54aebfc" dependencies: bs58 "^4.0.0" create-hash "^1.1.0" + safe-buffer "^5.1.2" buffer-alloc-unsafe@^1.0.0, buffer-alloc-unsafe@^1.1.0: version "1.1.0" @@ -1787,8 +1790,8 @@ buffer-fill@^1.0.0: resolved "https://registry.yarnpkg.com/buffer-fill/-/buffer-fill-1.0.0.tgz#f8f78b76789888ef39f205cd637f68e702122b2c" buffer-from@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.0.tgz#87fcaa3a298358e0ade6e442cfce840740d1ad04" + version "1.1.1" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz#32713bc028f75c02fdb710d7c7bcec1f2c6070ef" buffer-indexof@~0.0.0: version "0.0.2" @@ -1833,8 +1836,8 @@ buffer@^4.3.0: isarray "^1.0.0" buffer@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.1.0.tgz#c913e43678c7cb7c8bd16afbcddb6c5505e8f9fe" + version "5.2.0" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.2.0.tgz#53cf98241100099e9eeae20ee6d51d21b16e541e" dependencies: base64-js "^1.0.2" ieee754 "^1.1.4" @@ -1969,8 +1972,8 @@ camelcase@^3.0.0: resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" caniuse-lite@^1.0.30000844: - version "1.0.30000865" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000865.tgz#70026616e8afe6e1442f8bb4e1092987d81a2f25" + version "1.0.30000874" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000874.tgz#a641b1f1c420d58d9b132920ef6ba87bbdcd2223" capture-stack-trace@^1.0.0: version "1.0.0" @@ -2432,8 +2435,8 @@ crc32-stream@^2.0.0: readable-stream "^2.0.0" crc@^3.4.4: - version "3.7.0" - resolved "https://registry.yarnpkg.com/crc/-/crc-3.7.0.tgz#58b7083e32ba4b276e1f4cbce1a78b39a6ab63f9" + version "3.8.0" + resolved "https://registry.yarnpkg.com/crc/-/crc-3.8.0.tgz#ad60269c2c856f8c299e2c4cc0de4556914056c6" dependencies: buffer "^5.1.0" @@ -3034,10 +3037,11 @@ duplexify@^3.4.2, duplexify@^3.6.0: stream-shift "^1.0.0" ecc-jsbn@~0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.1.tgz#0fc73a9ed5f0d53c38193398523ef7e543777505" + version "0.1.2" + resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" dependencies: jsbn "~0.1.0" + safer-buffer "^2.1.0" ecdsa-sig-formatter@1.0.10: version "1.0.10" @@ -3061,8 +3065,8 @@ ejs@^2.5.7: resolved "https://registry.yarnpkg.com/ejs/-/ejs-2.6.1.tgz#498ec0d495655abc6f23cd61868d926464071aa0" electron-to-chromium@^1.3.47: - version "1.3.52" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.52.tgz#d2d9f1270ba4a3b967b831c40ef71fb4d9ab5ce0" + version "1.3.55" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.55.tgz#f150e10b20b77d9d41afcca312efe0c3b1a7fdce" elegant-spinner@^1.0.1: version "1.0.1" @@ -3567,8 +3571,8 @@ ethereumjs-block@^1.7.1: merkle-patricia-tree "^2.1.2" ethereumjs-tx@^1.2.2, ethereumjs-tx@^1.3.3: - version "1.3.6" - resolved "https://registry.yarnpkg.com/ethereumjs-tx/-/ethereumjs-tx-1.3.6.tgz#d581c1703b7b250b2e54892031626534d53e0a79" + version "1.3.7" + resolved "https://registry.yarnpkg.com/ethereumjs-tx/-/ethereumjs-tx-1.3.7.tgz#88323a2d875b10549b8347e09f4862b546f3d89a" dependencies: ethereum-common "^0.0.18" ethereumjs-util "^5.0.0" @@ -4374,8 +4378,8 @@ global-dirs@^0.1.0: ini "^1.3.4" global-modules-path@^2.1.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/global-modules-path/-/global-modules-path-2.2.0.tgz#24648267c65d02604c5549f04b46ac8973b4ba40" + version "2.3.0" + resolved "https://registry.yarnpkg.com/global-modules-path/-/global-modules-path-2.3.0.tgz#b0e2bac6beac39745f7db5c59d26a36a0b94f7dc" global@^4.3.1, global@^4.3.2: version "4.3.2" @@ -4719,8 +4723,8 @@ husky@0.14.3: strip-indent "^2.0.0" hyperscript-attribute-to-property@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/hyperscript-attribute-to-property/-/hyperscript-attribute-to-property-1.0.1.tgz#06ecb885bd64424de889df545899fcf0015e4787" + version "1.0.2" + resolved "https://registry.yarnpkg.com/hyperscript-attribute-to-property/-/hyperscript-attribute-to-property-1.0.2.tgz#66ad4164f88beefacf46ec884bd3d1173c1c382a" hyperx@^2.3.2: version "2.4.0" @@ -4948,11 +4952,11 @@ ip@^1.1.4, ip@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/ip/-/ip-1.1.5.tgz#bdded70114290828c0a039e72ef25f5aaec4354a" -ipaddr.js@1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.6.0.tgz#e3fa357b773da619f26e95f049d055c72796f86b" +ipaddr.js@1.8.0: + version "1.8.0" + resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.8.0.tgz#eaa33d6ddd7ace8f7f6fe0c9ca0440e706738b1e" -ipfs-api@22.2.4, ipfs-api@^22.2.4: +ipfs-api@22.2.4: version "22.2.4" resolved "https://registry.yarnpkg.com/ipfs-api/-/ipfs-api-22.2.4.tgz#226ebe5caffb5c58ae8d96d1ed3870a694b24cc7" dependencies: @@ -4993,6 +4997,47 @@ ipfs-api@22.2.4, ipfs-api@^22.2.4: streamifier "~0.1.1" tar-stream "^1.6.1" +ipfs-api@^22.2.4: + version "22.3.0" + resolved "https://registry.yarnpkg.com/ipfs-api/-/ipfs-api-22.3.0.tgz#29935c5d9ca533cefef62288e00a8b7eab412ab7" + dependencies: + async "^2.6.1" + big.js "^5.1.2" + bs58 "^4.0.1" + cids "~0.5.3" + concat-stream "^1.6.2" + debug "^3.1.0" + detect-node "^2.0.3" + flatmap "0.0.3" + glob "^7.1.2" + ipfs-block "~0.7.1" + ipfs-unixfs "~0.1.15" + ipld-dag-cbor "~0.12.1" + ipld-dag-pb "~0.14.6" + is-ipfs "~0.4.2" + is-pull-stream "0.0.0" + is-stream "^1.1.0" + libp2p-crypto "~0.13.0" + lru-cache "^4.1.3" + multiaddr "^5.0.0" + multibase "~0.4.0" + multihashes "~0.4.13" + ndjson "^1.5.0" + once "^1.4.0" + peer-id "~0.11.0" + peer-info "~0.14.1" + promisify-es6 "^1.0.3" + pull-defer "~0.2.2" + 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" + stream-http "^2.8.3" + stream-to-pull-stream "^1.7.2" + streamifier "~0.1.1" + tar-stream "^1.6.1" + ipfs-bitswap@~0.20.3: version "0.20.3" resolved "https://registry.yarnpkg.com/ipfs-bitswap/-/ipfs-bitswap-0.20.3.tgz#eb7f5e959da9d0e841a5aaef725fddea186a4e51" @@ -5042,7 +5087,7 @@ ipfs-css@0.5.2: version "0.5.2" resolved "https://registry.yarnpkg.com/ipfs-css/-/ipfs-css-0.5.2.tgz#5aa5620bd6df1b838b0f0fbce7e18b5ec4b39f6d" -ipfs-http-response@0.1.2, ipfs-http-response@~0.1.2: +ipfs-http-response@0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/ipfs-http-response/-/ipfs-http-response-0.1.2.tgz#4a131892fc0394b8d0255b0538da22155add4148" dependencies: @@ -5057,9 +5102,25 @@ ipfs-http-response@0.1.2, ipfs-http-response@~0.1.2: promisify-es6 "^1.0.3" readable-stream-node-to-web "^1.0.1" +ipfs-http-response@~0.1.2: + version "0.1.4" + resolved "https://registry.yarnpkg.com/ipfs-http-response/-/ipfs-http-response-0.1.4.tgz#b27303bb7430978b0a182379189900a034bda9d9" + dependencies: + async "^2.6.0" + cids "^0.5.3" + debug "^3.1.0" + file-type "^8.0.0" + filesize "^3.6.1" + get-stream "^3.0.0" + ipfs-unixfs "^0.1.14" + mime-types "^2.1.18" + multihashes "^0.4.13" + promisify-es6 "^1.0.3" + stream-to-blob "^1.0.1" + ipfs-mfs@~0.2.3: - version "0.2.3" - resolved "https://registry.yarnpkg.com/ipfs-mfs/-/ipfs-mfs-0.2.3.tgz#56e680abdea7dce644d08103fd878dfa110b0061" + version "0.2.5" + resolved "https://registry.yarnpkg.com/ipfs-mfs/-/ipfs-mfs-0.2.5.tgz#d093c6d2dd5060b2ac29febe0dbae98bc2460ec8" dependencies: async "^2.6.1" blob "~0.0.4" @@ -5290,24 +5351,7 @@ ipld-dag-cbor@~0.12.1: multihashing-async "~0.5.1" traverse "~0.6.6" -ipld-dag-pb@^0.14.4, ipld-dag-pb@~0.14.5: - version "0.14.5" - resolved "https://registry.yarnpkg.com/ipld-dag-pb/-/ipld-dag-pb-0.14.5.tgz#bec6417401b32a80818190636a08edc0048dccec" - dependencies: - async "^2.6.1" - bs58 "^4.0.1" - buffer-loader "~0.0.1" - cids "~0.5.3" - class-is "^1.1.0" - is-ipfs "~0.3.2" - multihashes "~0.4.13" - multihashing-async "~0.5.1" - protons "^1.0.1" - pull-stream "^3.6.8" - pull-traverse "^1.0.3" - stable "~0.1.8" - -ipld-dag-pb@~0.14.6: +ipld-dag-pb@^0.14.4, ipld-dag-pb@~0.14.5, ipld-dag-pb@~0.14.6: version "0.14.6" resolved "https://registry.yarnpkg.com/ipld-dag-pb/-/ipld-dag-pb-0.14.6.tgz#1b0357c7db8c1a75f8eef6e89505ddc614a7faaa" dependencies: @@ -5760,8 +5804,8 @@ istanbul-lib-hook@^1.1.0: append-transform "^0.4.0" istanbul-lib-instrument@^2.1.0: - version "2.3.1" - resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-2.3.1.tgz#406406730a395acb2e50f0d98137ace16bd4a970" + version "2.3.2" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-2.3.2.tgz#b287cbae2b5f65f3567b05e2e29b275eaf92d25e" dependencies: "@babel/generator" "7.0.0-beta.51" "@babel/parser" "7.0.0-beta.51" @@ -5837,8 +5881,8 @@ joi@^11.1.0: topo "2.x.x" joi@^13.4.0: - version "13.4.0" - resolved "https://registry.yarnpkg.com/joi/-/joi-13.4.0.tgz#afc359ee3d8bc5f9b9ba6cdc31b46d44af14cecc" + version "13.5.2" + resolved "https://registry.yarnpkg.com/joi/-/joi-13.5.2.tgz#32207c85fa76d889f1e971c7eaaf69b232259a91" dependencies: hoek "5.x.x" isemail "3.x.x" @@ -6444,8 +6488,8 @@ libp2p-switch@~0.40.7: pull-stream "^3.6.7" libp2p-tcp@~0.12.0: - version "0.12.0" - resolved "https://registry.yarnpkg.com/libp2p-tcp/-/libp2p-tcp-0.12.0.tgz#a41737cb999485299df9fff3f692750f0428adea" + version "0.12.1" + resolved "https://registry.yarnpkg.com/libp2p-tcp/-/libp2p-tcp-0.12.1.tgz#fcb7ade07d95dd3552e9c71402edf34f00c37102" dependencies: class-is "^1.1.0" debug "^3.1.0" @@ -7107,13 +7151,13 @@ mime-db@~1.33.0: version "1.33.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.33.0.tgz#a3492050a5cb9b63450541e39d9788d2272783db" -mime-types@2.1.18, mime-types@^2.1.12, mime-types@^2.1.18, mime-types@~2.1.17, mime-types@~2.1.18: +mime-types@2.1.18: version "2.1.18" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.18.tgz#6f323f60a83d11146f831ff11fd66e2fe5503bb8" dependencies: mime-db "~1.33.0" -mime-types@^2.1.19: +mime-types@^2.1.12, mime-types@^2.1.18, mime-types@^2.1.19, mime-types@~2.1.17, mime-types@~2.1.18: version "2.1.19" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.19.tgz#71e464537a7ef81c15f2db9d97e913fc0ff606f0" dependencies: @@ -7783,8 +7827,8 @@ npm-bundled@^1.0.1: resolved "https://registry.yarnpkg.com/npm-bundled/-/npm-bundled-1.0.3.tgz#7e71703d973af3370a9591bafe3a63aca0be2308" npm-packlist@^1.1.6: - version "1.1.10" - resolved "https://registry.yarnpkg.com/npm-packlist/-/npm-packlist-1.1.10.tgz#1039db9e985727e464df066f4cf0ab6ef85c398a" + version "1.1.11" + resolved "https://registry.yarnpkg.com/npm-packlist/-/npm-packlist-1.1.11.tgz#84e8c683cbe7867d34b1d357d893ce29e28a02de" dependencies: ignore-walk "^3.0.1" npm-bundled "^1.0.1" @@ -7930,7 +7974,7 @@ on-load@^3.3.4: global "^4.3.2" nanoassert "^1.1.0" -once@^1.3.0, once@^1.3.1, once@^1.4.0: +once@^1.3.0, once@^1.3.1, once@^1.3.3, once@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" dependencies: @@ -8601,11 +8645,11 @@ protons@^1.0.0, protons@^1.0.1: varint "^5.0.0" proxy-addr@~2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.3.tgz#355f262505a621646b3130a728eb647e22055341" + version "2.0.4" + resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.4.tgz#ecfc733bf22ff8c6f407fa275327b9ab67e48b93" dependencies: forwarded "~0.1.2" - ipaddr.js "1.6.0" + ipaddr.js "1.8.0" proxy-agent@^2.0.0: version "2.3.1" @@ -9343,7 +9387,7 @@ safe-regex@^1.1.0: dependencies: ret "~0.1.10" -"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2: +"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" @@ -10185,8 +10229,8 @@ stream-combiner@~0.0.4: duplexer "~0.1.1" stream-each@^1.1.0: - version "1.2.2" - resolved "https://registry.yarnpkg.com/stream-each/-/stream-each-1.2.2.tgz#8e8c463f91da8991778765873fe4d960d8f616bd" + version "1.2.3" + resolved "https://registry.yarnpkg.com/stream-each/-/stream-each-1.2.3.tgz#ebe27a0c389b04fbcc233642952e10731afa9bae" dependencies: end-of-stream "^1.1.0" stream-shift "^1.0.0" @@ -10217,6 +10261,12 @@ stream-to-array@~2.3.0: dependencies: any-promise "^1.1.0" +stream-to-blob@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/stream-to-blob/-/stream-to-blob-1.0.1.tgz#2dc1e09b71677a234d00445f8eb7ff70c4fe9948" + dependencies: + once "^1.3.3" + stream-to-promise@2.2.0, stream-to-promise@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/stream-to-promise/-/stream-to-promise-2.2.0.tgz#b1edb2e1c8cb11289d1b503c08d3f2aef51e650f" @@ -10453,8 +10503,8 @@ tar-stream@^1.1.2, tar-stream@^1.5.0, tar-stream@^1.5.2, tar-stream@^1.6.1: xtend "^4.0.0" tar@^4: - version "4.4.4" - resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.4.tgz#ec8409fae9f665a4355cc3b4087d0820232bb8cd" + version "4.4.6" + resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.6.tgz#63110f09c00b4e60ac8bcfe1bf3c8660235fbc9b" dependencies: chownr "^1.0.1" fs-minipass "^1.2.5" @@ -10511,8 +10561,7 @@ term-size@^1.2.0: dependencies: execa "^0.7.0" -terser@3.8.0, uglify-es@^3.3.4, "uglify-es@npm:terser": - name uglify-es +terser@3.8.0: version "3.8.0" resolved "https://registry.yarnpkg.com/terser/-/terser-3.8.0.tgz#66a4f4f500d2c829faab840f318c49cc471d73ae" dependencies: @@ -10780,6 +10829,14 @@ typeforce@^1.11.3: version "1.12.0" resolved "https://registry.yarnpkg.com/typeforce/-/typeforce-1.12.0.tgz#ca40899919f1466d7819e37be039406beb912a2e" +uglify-es@^3.3.4, "uglify-es@npm:terser": + version "3.8.1" + resolved "https://registry.yarnpkg.com/terser/-/terser-3.8.1.tgz#cb70070ac9e0a71add169dfb63c0a64fca2738ac" + dependencies: + commander "~2.16.0" + source-map "~0.6.1" + source-map-support "~0.5.6" + uglify-js@^2.6: version "2.8.29" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.8.29.tgz#29c5733148057bb4e1f75df35b7a9cb72e6a59dd" From 34eafa4e7a4e2f7b9b99b591a060e89d62160349 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 3 Aug 2018 11:35:17 -0700 Subject: [PATCH 17/31] fix(libdweb/ci): network lock and submodule sync --- ci/Jenkinsfile | 6 +++--- package.json | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ci/Jenkinsfile b/ci/Jenkinsfile index fcb6d265a..640cd6787 100644 --- a/ci/Jenkinsfile +++ b/ci/Jenkinsfile @@ -1,7 +1,7 @@ import groovy.transform.Field // Global for which node version to use on macos and windows // When in doubt, should follow https://github.com/ipfs/jenkins-libs/blob/master/vars/javascript.groovy -@Field final String nodeVersion = '8.11.3' +@Field final String nodeVersion = '10.4.1' // Run targets in parallel parallel( @@ -64,7 +64,7 @@ parallel( bat 'npx yarn@1.7.0 config set msvs_version 2015 --global' // run developer build as a smoke-test for windows // bat 'npm run dev-build' - bat 'npx yarn@1.7.0' + bat 'npx yarn@1.7.0 --mutex network --no-lockfile' bat 'npm run libdweb:build' bat 'dir /s /b /o:gn build' } @@ -94,7 +94,7 @@ parallel( sh 'rm -rf node_modules/' // run developer build as a smoke-test // sh 'npm run dev-build' - sh 'npx yarn@1.7.0' + sh 'npx yarn@1.7.0 --mutex network --no-lockfile' sh 'npm run libdweb:build' sh 'ls -Rlh build' } diff --git a/package.json b/package.json index 0c109ab04..ff1b592a6 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "build:js": "run-p build:js:*", "build:js:webpack": "webpack -p", "build:minimize-dist": "shx rm -rf add-on/dist/lib add-on/dist/contentScripts/ add-on/dist/bundles/ipfsProxyContentScriptPayload.bundle.js", - "build:bundle-all": "RELEASE_CHANNEL=${RELEASE_CHANNEL:=dev} npm run bundle:generic && cross-env-shell npm run bundle:firefox:$RELEASE_CHANNEL", + "build:bundle-all": "cross-env-shell RELEASE_CHANNEL=${RELEASE_CHANNEL:=dev} npm run bundle:generic && cross-env-shell npm run bundle:firefox:$RELEASE_CHANNEL", "bundle": "run-s bundle:*", "bundle:generic": "shx cp add-on/manifest.common.json add-on/manifest.json && web-ext build -a build/generic", "bundle:firefox": "shx cat add-on/manifest.common.json add-on/manifest.firefox.json | json --deep-merge > add-on/manifest.json && web-ext build -a build/firefox/", @@ -46,7 +46,7 @@ "prepush": "run-s clean build lint test", "firefox": "web-ext run --browser-console --url about:debugging", "libdweb": "npx yarn@1.7.0 && npm run libdweb:build && npm run libdweb:firefox", - "libdweb:build": "git submodule update --init --checkout --depth 1 libdweb && cross-env-shell RELEASE_CHANNEL=libdweb npm run dev-build", + "libdweb:build": "git submodule sync && git submodule init && git submodule update && cross-env-shell RELEASE_CHANNEL=libdweb npm run dev-build", "libdweb:firefox": "npm run get-firefox-nightly && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=./firefox/firefox --browser-console --url about:debugging", "get-firefox-nightly": "shx test -e ./firefox/firefox || get-firefox -b nightly -e", "ci": "run-s ci:*", From 0a0b6853197a5f2bb7b67c7f564722f36879e30e Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 3 Aug 2018 17:07:54 -0700 Subject: [PATCH 18/31] feat(libdweb): remove dependency on git submodule --- .gitmodules | 3 --- add-on/manifest.firefox-libdweb.json | 6 +++--- docs/libdweb.md | 24 ++++++++++-------------- libdweb | 1 - package.json | 5 +++-- yarn.lock | 4 ++++ 6 files changed, 20 insertions(+), 23 deletions(-) delete mode 100644 .gitmodules delete mode 160000 libdweb diff --git a/.gitmodules b/.gitmodules deleted file mode 100644 index dcc708702..000000000 --- a/.gitmodules +++ /dev/null @@ -1,3 +0,0 @@ -[submodule "libdweb"] - path = libdweb - url = https://github.com/mozilla/libdweb.git diff --git a/add-on/manifest.firefox-libdweb.json b/add-on/manifest.firefox-libdweb.json index c2668a874..ebb66fd8f 100644 --- a/add-on/manifest.firefox-libdweb.json +++ b/add-on/manifest.firefox-libdweb.json @@ -7,17 +7,17 @@ "protocol_handlers": [], "experiment_apis": { "protocol": { - "schema": "../libdweb/src/protocol/protocol.json", + "schema": "../node_modules/libdweb/src/protocol/protocol.json", "child": { "scopes": ["addon_child"], "paths": [["protocol"]], - "script": "../libdweb/src/protocol/client.js" + "script": "../node_modules/libdweb/src/protocol/client.js" }, "parent": { "events": ["startup"], "scopes": ["addon_parent"], "paths": [["protocol"]], - "script": "../libdweb/src/protocol/host.js" + "script": "../node_modules/libdweb/src/protocol/host.js" } } } diff --git a/docs/libdweb.md b/docs/libdweb.md index a5cbd2ab2..b8b2d787f 100644 --- a/docs/libdweb.md +++ b/docs/libdweb.md @@ -11,15 +11,17 @@ See also: ## TL;DR -1. Having `firefox-nightly` in `$PATH`, execute commands below to checkout, build and run Companion extension in libdweb-enabled context: +1. Execute commands below to fetch Firefox Nightly, build and run Companion extension in libdweb-enabled context: ``` - git clone -b libdweb --recurse-submodules --depth 1 https://github.com/ipfs-shipyard/ipfs-companion.git + git clone -b libdweb --depth 1 https://github.com/ipfs-shipyard/ipfs-companion.git + cd ipfs-companion npm run libdweb ``` 2. Optional Smoke-Test: - Open `ipfs://bafkreickb4yq3sr3q2xqn3z3wzimilsa4wkbx25azqbvcnihq65moyjcvi` - Open `ipns://docs.ipfs.io` + - Open `ipns://tr.wikipedia-on-ipfs.org` - Confirm `ipfs://` protocol remains in Location Bar ([example](https://ipfs.io/ipfs/bafybeie5gq4jxvzmsym6hjlwxej4rwdoxt7wadqvmmwbqi7r27fclha2va)) ## Developer Notes @@ -35,35 +37,29 @@ See also: ``` # checkout libdweb branch into a new directory # including submodules (namely ./libdweb) -git clone -b libdweb --recurse-submodules --depth 1 https://github.com/ipfs-shipyard/ipfs-companion.git +git clone -b libdweb --depth 1 https://github.com/ipfs-shipyard/ipfs-companion.git +cd ipfs-companion # install deps and build npm run libdweb:build -# run (assumes firefox-nightly on PATH) +# run in firefox-nightly npm run libdweb:firefox ``` -### Manually Deploy in Firefox with libdweb APIs ✂️ +### Manually run with different firefox binary✂️ To run your extension in libdweb context: ``` +npm run libdweb:build export MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=/path/to/nightly/firefox-bin --browser-console --url about:debugging ``` -or use alias: - -``` -npm run libdweb:firefox -``` - - Additional notes: -- If you want `libdweb:firefox` to work, ensure `firefox-nightly` is on your `$PATH` - - if `firefox-nightly` is missing, create it in unpacked directory via `ln -s firefox firefox-nightly` +- Script `libdweb:firefox` will download latest Firefox Nightly to `./firefox/firefox` - After initially running `libdweb:build` it is ok to use `yarn watch` – it will work as expected ## Appendix: Smoke-Testing libdweb APIs diff --git a/libdweb b/libdweb deleted file mode 160000 index fbff435b3..000000000 --- a/libdweb +++ /dev/null @@ -1 +0,0 @@ -Subproject commit fbff435b33542b02bc35c0bb8c27bc203e6d4e6e diff --git a/package.json b/package.json index ff1b592a6..12140a965 100644 --- a/package.json +++ b/package.json @@ -45,8 +45,8 @@ "precommit": "run-s lint:standard", "prepush": "run-s clean build lint test", "firefox": "web-ext run --browser-console --url about:debugging", - "libdweb": "npx yarn@1.7.0 && npm run libdweb:build && npm run libdweb:firefox", - "libdweb:build": "git submodule sync && git submodule init && git submodule update && cross-env-shell RELEASE_CHANNEL=libdweb npm run dev-build", + "libdweb": "npm run libdweb:build && npm run libdweb:firefox", + "libdweb:build": "npx yarn@1.7.0 && cross-env-shell RELEASE_CHANNEL=libdweb npm run dev-build", "libdweb:firefox": "npm run get-firefox-nightly && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=./firefox/firefox --browser-console --url about:debugging", "get-firefox-nightly": "shx test -e ./firefox/firefox || get-firefox -b nightly -e", "ci": "run-s ci:*", @@ -115,6 +115,7 @@ "is-ipfs": "0.4.2", "is-stream": "1.1.0", "is-svg": "3.0.0", + "libdweb": "mozilla/libdweb.git#fbff435b33542b02bc35c0bb8c27bc203e6d4e6e", "lru_map": "0.3.3", "mime-types": "2.1.18", "p-queue": "2.4.2", diff --git a/yarn.lock b/yarn.lock index 9d753b6d6..d2df20e61 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6255,6 +6255,10 @@ levn@^0.3.0, levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" +libdweb@mozilla/libdweb.git#fbff435b33542b02bc35c0bb8c27bc203e6d4e6e: + version "0.0.0" + resolved "https://codeload.github.com/mozilla/libdweb/tar.gz/fbff435b33542b02bc35c0bb8c27bc203e6d4e6e" + libp2p-bootstrap@~0.9.3: version "0.9.3" resolved "https://registry.yarnpkg.com/libp2p-bootstrap/-/libp2p-bootstrap-0.9.3.tgz#90d68f890ebdc6aa54e14bb1f257173ad20575f9" From 9a91aca9e5276cfc8b135130a519eb1fd414439b Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Wed, 8 Aug 2018 15:26:43 +0200 Subject: [PATCH 19/31] fix(libdweb/ci): ipfs-protocol-muon-brave.test.js --- .../{ipfs-protocol.test.js => ipfs-protocol-muon-brave.test.js} | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename test/functional/lib/{ipfs-protocol.test.js => ipfs-protocol-muon-brave.test.js} (97%) diff --git a/test/functional/lib/ipfs-protocol.test.js b/test/functional/lib/ipfs-protocol-muon-brave.test.js similarity index 97% rename from test/functional/lib/ipfs-protocol.test.js rename to test/functional/lib/ipfs-protocol-muon-brave.test.js index 9a619efa2..2d2c6fe53 100644 --- a/test/functional/lib/ipfs-protocol.test.js +++ b/test/functional/lib/ipfs-protocol-muon-brave.test.js @@ -1,7 +1,7 @@ 'use strict' const { describe, it } = require('mocha') const { expect } = require('chai') -const { createIpfsUrlProtocolHandler } = require('../../../add-on/src/lib/ipfs-protocol') +const { createIpfsUrlProtocolHandler } = require('../../../add-on/src/lib/ipfs-protocol-muon-brave.js') describe('ipfs-protocol', () => { it('should serve an IPFS file', async () => { From 1a830dd037fc510a7a89fea0a297204c1a07b818 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Wed, 8 Aug 2018 16:38:20 +0200 Subject: [PATCH 20/31] feat(libdweb): reuse dnslink cache for ipns:// --- add-on/src/lib/ipfs-companion.js | 4 +- add-on/src/lib/ipfs-protocol-libdweb.js | 56 ++++++++++++------------- 2 files changed, 28 insertions(+), 32 deletions(-) diff --git a/add-on/src/lib/ipfs-companion.js b/add-on/src/lib/ipfs-companion.js index 8537b1ece..c80c78f48 100644 --- a/add-on/src/lib/ipfs-companion.js +++ b/add-on/src/lib/ipfs-companion.js @@ -106,8 +106,8 @@ module.exports = async function init () { } else if (runtime.hasNativeProtocolHandler && browser.protocol.registerProtocol) { console.log('[ipfs-companion] registerProtocol from mozilla/libdweb is available. Adding ipfs:// handler') const { createIpfsUrlProtocolHandler } = require('./ipfs-protocol-libdweb') - browser.protocol.registerProtocol('ipfs', createIpfsUrlProtocolHandler(getIpfs)) - browser.protocol.registerProtocol('ipns', createIpfsUrlProtocolHandler(getIpfs)) + browser.protocol.registerProtocol('ipfs', createIpfsUrlProtocolHandler(getIpfs, dnsLink)) + browser.protocol.registerProtocol('ipns', createIpfsUrlProtocolHandler(getIpfs, dnsLink)) } else { console.log('[ipfs-companion] browser.protocol.registerStringProtocol not available, native protocol will not be registered') } diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 5933e0e4c..70cb73699 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -12,20 +12,11 @@ const isStream = require('is-stream') /* protocol handler for mozilla/libdweb */ -exports.createIpfsUrlProtocolHandler = (getIpfs) => { +exports.createIpfsUrlProtocolHandler = (getIpfs, dnsLink) => { return request => { console.time('[ipfs-companion] LibdwebProtocolHandler') console.log(`[ipfs-companion] handling ${request.url}`) - let path - if (request.url.startsWith('ipfs:')) { - path = request.url.replace('ipfs://', '/') - path = path.startsWith('/ipfs') ? path : `/ipfs${path}` - } else if (request.url.startsWith('ipns:')) { - path = request.url.replace('ipns://', '/') - path = path.startsWith('/ipns') ? path : `/ipns${path}` - } - try { return { // Notes: @@ -33,22 +24,24 @@ exports.createIpfsUrlProtocolHandler = (getIpfs) => { // // TODO: // - detect invalid addrs and display error page - // - support streaming - content: streamRespond(getIpfs, path, request) + content: streamRespond(getIpfs, dnsLink, request) } } catch (err) { - console.error('[ipfs-companion] failed to get data for ' + request.url, err) + console.error(`[ipfs-companion] failed to get data for ${request.url}`, err) } - console.timeEnd('[ipfs-companion] LibdwebProtocolHandler') } } -async function * streamRespond (getIpfs, path, request) { +async function * streamRespond (getIpfs, dnsLink, request) { let response try { const ipfs = getIpfs() - response = await getResponse(ipfs, path) + const url = request.url + // Get /ipfs/ path for URL (resolve to immutable snapshot if ipns://) + const path = immutableIpfsPath(url, dnsLink) + // Then, fetch response from IPFS + response = await getResponse(ipfs, url, path) } catch (error) { yield toErrorResponse(request, error) return @@ -81,15 +74,24 @@ function toErrorResponse (request, error) { return textBuffer(`Unable to produce IPFS response for "${request.url}": ${error}`) } -async function getResponse (ipfs, path) { - // TODO: move IPNS resolv just before cat, so that directory listing uses correct protocol +function immutableIpfsPath (url, dnsLink) { + // Move protocol to IPFS-like path + let path = url.replace(/^([^:]+):\/\/*/, '/$1/') + // Handle IPNS (if present) if (path.startsWith('/ipns/')) { + // js-ipfs does not implement ipfs.name.resolve yet, so we only do dnslink lookup // const response = await ipfs.name.resolve(path, {recursive: true, nocache: false}) - const fqdn = path.replace(/^\/ipns\//, '') - const response = await ipfs.dns(fqdn) - path = response.Path ? response.Path : response + const fqdn = path.split('/')[2] + const dnslinkRecord = dnsLink.cachedDnslinkLookup(fqdn) + if (!dnslinkRecord) { + throw new Error(`Missing DNS TXT with dnslink for '${fqdn}'`) + } + path = path.replace(`/ipns/${fqdn}`, dnslinkRecord) } + return path +} +async function getResponse (ipfs, url, path) { // We're using ipfs.ls to figure out if a path is a file or a directory. // // If the listing is empty then it's (likely) a file @@ -109,7 +111,7 @@ async function getResponse (ipfs, path) { const listing = await ipfs.ls(path) if (isDirectory(listing)) { - return getDirectoryListingOrIndexResponse(ipfs, path, listing) + return getDirectoryListingOrIndexResponse(ipfs, url, path, listing) } // Efficient mime-sniff over initial bytes @@ -135,7 +137,7 @@ function isDirectory (listing) { return !listing.every(f => f.path === path) } -function getDirectoryListingOrIndexResponse (ipfs, path, listing) { +function getDirectoryListingOrIndexResponse (ipfs, url, path, listing) { const indexFileNames = ['index', 'index.html', 'index.htm'] const index = listing.find((l) => indexFileNames.includes(l.name)) @@ -149,12 +151,6 @@ function getDirectoryListingOrIndexResponse (ipfs, path, listing) { return ipfs.files.catReadableStream(PathUtils.joinURLParts(path, index.name)) } - // TODO: deuglify ;-) - if (path.startsWith('/ipfs/')) { - path = path.replace(/^\/ipfs\//, 'ipfs://') - } else if (path.startsWith('/ipns/')) { - path = path.replace(/^\/ipns\//, 'ipns://') - } - const response = dirView.render(path, listing) + const response = dirView.render(url, listing) return new TextEncoder('utf-8').encode(response).buffer } From 0ea698e2db32b07b823ebf9edb40a55307321fb7 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 10 Aug 2018 13:16:03 +0200 Subject: [PATCH 21/31] refactor(libdweb): reuse dir listing from js-ipfs --- add-on/src/lib/ipfs-protocol-libdweb.js | 79 ++++------ package.json | 2 +- yarn.lock | 191 ++++++++++++++++++++++-- 3 files changed, 210 insertions(+), 62 deletions(-) diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 70cb73699..fc2ddc0b2 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -3,10 +3,11 @@ import {asyncIterateStream} from 'async-iterate-stream/asyncIterateStream' +const { resolver } = require('ipfs-http-response') const { mimeSniff } = require('./mime-sniff') const toArrayBuffer = require('to-arraybuffer') const peek = require('buffer-peek-stream') -const dirView = require('./dir-view') +// const dirView = require('./dir-view') const PathUtils = require('ipfs/src/http/gateway/utils/path') const isStream = require('is-stream') @@ -92,34 +93,39 @@ function immutableIpfsPath (url, dnsLink) { } async function getResponse (ipfs, url, path) { - // We're using ipfs.ls to figure out if a path is a file or a directory. - // - // If the listing is empty then it's (likely) a file - // If the listing has 1 entry then it's a directory - // If the listing has > 1 entry && all the paths are the same then directory - // else file - // - // It's not pretty, but the alternative is to use the object or dag API's - // and inspect the data returned by them to see if it's a file or dir. - // - // Right now we can't use either of these because: - // 1. js-ipfs object API does not take paths (only cid) - // 2. js-ipfs-api does not support dag API at all - // - // The second alternative would be to resolve the path ourselves using the - // object API, but that could take a while for long paths. - const listing = await ipfs.ls(path) - - if (isDirectory(listing)) { - return getDirectoryListingOrIndexResponse(ipfs, url, path, listing) + let cid + try { + // try direct resolver + const dag = await resolver.cid(ipfs, path) + // console.log('resolver.cid: ', dag) + cid = dag.cid + } catch (err) { + const errorToString = err.toString() + // handle directories + if (errorToString === 'Error: This dag node is a directory') { + const dirCid = err.cid + const data = await resolver.directory(ipfs, url, dirCid) + // console.log('resolver.directory', data) + // TODO: redirect so directory always end with `/` + if (typeof data === 'string') { + // return HTML with directory listing + return new TextEncoder('utf-8').encode(data).buffer + } else if (Array.isArray(data)) { + // return first index file + path = PathUtils.joinURLParts(path, data[0].name) + return getResponse(ipfs, url, path) + } + throw new Error('Invalid output of resolver.directory') + } + throw err } // Efficient mime-sniff over initial bytes // TODO: rignt now it is only logged, use contentType somehow const { stream, contentType } = await new Promise((resolve, reject) => { - peek(ipfs.files.catReadableStream(path), 512, (err, data, stream) => { + peek(ipfs.files.catReadableStream(cid), 512, (err, data, stream) => { if (err) return reject(err) - const contentType = mimeSniff(data, path) || 'text/plain' + const contentType = mimeSniff(data, url) || 'application/octet-stream' resolve({ stream, contentType }) }) }) @@ -127,30 +133,3 @@ async function getResponse (ipfs, url, path) { // return stream } - -function isDirectory (listing) { - if (!listing.length) return false - if (listing.length === 1) return true - // If every path in the listing is the same, IPFS has listed blocks for a file - // if not then it is a directory listing. - const path = listing[0].path - return !listing.every(f => f.path === path) -} - -function getDirectoryListingOrIndexResponse (ipfs, url, path, listing) { - const indexFileNames = ['index', 'index.html', 'index.htm'] - const index = listing.find((l) => indexFileNames.includes(l.name)) - - if (index) { - /* TODO: pass mime-type to libdweb somehow? - let contentType = 'text/plain' - if (index.name.endsWith('.html') || index.name.endsWith('.htm')) { - contentType = 'text/html' - } - */ - return ipfs.files.catReadableStream(PathUtils.joinURLParts(path, index.name)) - } - - const response = dirView.render(url, listing) - return new TextEncoder('utf-8').encode(response).buffer -} diff --git a/package.json b/package.json index fd29fa7b5..75e8ad8ca 100644 --- a/package.json +++ b/package.json @@ -110,7 +110,7 @@ "ipfs": "0.31.2", "ipfs-api": "22.3.0", "ipfs-css": "0.7.0", - "ipfs-http-response": "0.1.4", + "ipfs-http-response": "lidel/js-ipfs-http-response.git#7382681983809d6661e33664fc9b9adac0b9d201", "ipfs-postmsg-proxy": "3.0.0", "is-ipfs": "0.4.2", "is-stream": "1.1.0", diff --git a/yarn.lock b/yarn.lock index f8c3e0907..d0e7da7ca 100644 --- a/yarn.lock +++ b/yarn.lock @@ -556,6 +556,15 @@ ajv@^4.7.0: co "^4.6.0" json-stable-stringify "^1.0.1" +ajv@^5.1.0: + version "5.5.2" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" + dependencies: + co "^4.6.0" + fast-deep-equal "^1.0.0" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.3.0" + ajv@^6.1.0: version "6.5.0" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.5.0.tgz#4c8affdf80887d8f132c9c52ab8a2dc4d0b7b24c" @@ -798,6 +807,16 @@ asn1.js@^5.0.0: inherits "^2.0.1" minimalistic-assert "^1.0.0" +asn1@~0.2.3: + version "0.2.4" + resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.4.tgz#8d2475dfab553bb33e77b54e59e880bb8ce23136" + dependencies: + safer-buffer "~2.1.0" + +assert-plus@1.0.0, assert-plus@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" + assert@^1.1.1, assert@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/assert/-/assert-1.4.1.tgz#99912d591836b5a6f5b345c0f07eefc08fc65d91" @@ -890,6 +909,14 @@ atob@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.1.tgz#ae2d5a729477f289d60dd7f96a6314a22dd6c22a" +aws-sign2@~0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" + +aws4@^1.6.0: + version "1.8.0" + resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz#f0e003d9ca9e7f59c7a508945d7b2ef9a04a542f" + b64@3.x.x: version "3.0.3" resolved "https://registry.yarnpkg.com/b64/-/b64-3.0.3.tgz#36afeee0d9345f046387ce6de8a6702afe5bb56e" @@ -1445,6 +1472,12 @@ base@^0.11.1: mixin-deep "^1.2.0" pascalcase "^0.1.1" +bcrypt-pbkdf@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" + dependencies: + tweetnacl "^0.14.3" + bech32@^1.1.2: version "1.1.3" resolved "https://registry.yarnpkg.com/bech32/-/bech32-1.1.3.tgz#bd47a8986bbb3eec34a56a097a84b8d3e9a2dfcd" @@ -1975,6 +2008,10 @@ capture-stack-trace@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/capture-stack-trace/-/capture-stack-trace-1.0.0.tgz#4a6fa07399c26bba47f0b2496b4d0fb408c5550d" +caseless@~0.12.0: + version "0.12.0" + resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" + catbox-memory@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/catbox-memory/-/catbox-memory-2.0.4.tgz#433e255902caf54233d1286429c8f4df14e822d5" @@ -2268,7 +2305,7 @@ columnify@1.5.4: strip-ansi "^3.0.0" wcwidth "^1.0.0" -combined-stream@1.0.6: +combined-stream@1.0.6, combined-stream@~1.0.5: version "1.0.6" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.6.tgz#723e7df6e801ac5613113a7e445a9b69cb632818" dependencies: @@ -2422,7 +2459,7 @@ core-js@^2.4.0, core-js@^2.5.0, core-js@^2.5.1: version "2.5.7" resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.7.tgz#f972608ff0cead68b841a16a932d0b183791814e" -core-util-is@~1.0.0: +core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" @@ -2568,6 +2605,12 @@ dash-ast@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/dash-ast/-/dash-ast-1.0.0.tgz#12029ba5fb2f8aa6f0a861795b23c1b4b6c27d37" +dashdash@^1.12.0: + version "1.14.1" + resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" + dependencies: + assert-plus "^1.0.0" + data-queue@0.0.3: version "0.0.3" resolved "https://registry.yarnpkg.com/data-queue/-/data-queue-0.0.3.tgz#47ab5b634d4a3bbf7bb4ab625a4175b8cf9d44b1" @@ -3029,6 +3072,13 @@ duplexify@^3.4.2, duplexify@^3.6.0: readable-stream "^2.0.0" stream-shift "^1.0.0" +ecc-jsbn@~0.1.1: + version "0.1.2" + resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" + dependencies: + jsbn "~0.1.0" + safer-buffer "^2.1.0" + ecdsa-sig-formatter@1.0.10: version "1.0.10" resolved "https://registry.yarnpkg.com/ecdsa-sig-formatter/-/ecdsa-sig-formatter-1.0.10.tgz#1c595000f04a8897dfb85000892a0f4c33af86c3" @@ -3700,7 +3750,7 @@ extend@3: version "3.0.1" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" -extend@^3.0.0: +extend@^3.0.0, extend@~3.0.1: version "3.0.2" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" @@ -3733,12 +3783,24 @@ extglob@^2.0.4: snapdragon "^0.8.1" to-regex "^3.0.1" +extsprintf@1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" + +extsprintf@^1.2.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.0.tgz#e2689f8f356fad62cca65a3a91c5df5f9551692f" + fakefile@0.0.9: version "0.0.9" resolved "https://registry.yarnpkg.com/fakefile/-/fakefile-0.0.9.tgz#411c9c23eb3b1c98cf7925a7e2d69e2e70c23ca8" dependencies: fs-extra "0.26.5" +fast-deep-equal@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz#c053477817c86b51daa853c81e059b733d023614" + fast-deep-equal@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz#7b05218ddf9667bf7f370bf7fdb2cb15fdd0aa49" @@ -4012,7 +4074,11 @@ foreground-child@^1.5.3, foreground-child@^1.5.6: cross-spawn "^4" signal-exit "^3.0.0" -form-data@^2.3.1: +forever-agent@~0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" + +form-data@^2.3.1, form-data@~2.3.1: version "2.3.2" resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.2.tgz#4970498be604c20c005d4f5c23aecd21d6b49099" dependencies: @@ -4274,6 +4340,12 @@ get-value@^2.0.3, get-value@^2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/get-value/-/get-value-2.0.6.tgz#dc15ca1c672387ca76bd37ac0a395ba2042a2c28" +getpass@^0.1.1: + version "0.1.7" + resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" + dependencies: + assert-plus "^1.0.0" + gettext-parser@1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/gettext-parser/-/gettext-parser-1.1.0.tgz#2c5a6638d893934b9b55037d0ad82cb7004b2679" @@ -4457,6 +4529,17 @@ hapi@^16.6.2: subtext "^5.0.0" topo "^2.0.2" +har-schema@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" + +har-validator@~5.0.3: + version "5.0.3" + resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.0.3.tgz#ba402c266194f15956ef15e0fcf242993f6a7dfd" + dependencies: + ajv "^5.1.0" + har-schema "^2.0.0" + has-ansi@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" @@ -4642,6 +4725,14 @@ http-proxy-agent@^2.1.0: agent-base "4" debug "3.1.0" +http-signature@~1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" + dependencies: + assert-plus "^1.0.0" + jsprim "^1.2.2" + sshpk "^1.7.0" + https-browserify@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/https-browserify/-/https-browserify-1.0.0.tgz#ec06c10e0a34c0f2faf199f7fd7fc78fffd03c73" @@ -4991,7 +5082,23 @@ ipfs-css@0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/ipfs-css/-/ipfs-css-0.7.0.tgz#d612d4f85535268483859663b4bf6326edaae1a3" -ipfs-http-response@0.1.4, ipfs-http-response@~0.1.2: +ipfs-http-response@lidel/js-ipfs-http-response.git#7382681983809d6661e33664fc9b9adac0b9d201: + version "0.1.4" + resolved "https://codeload.github.com/lidel/js-ipfs-http-response/tar.gz/7382681983809d6661e33664fc9b9adac0b9d201" + dependencies: + async "^2.6.0" + cids "^0.5.3" + debug "^3.1.0" + file-type "^8.0.0" + filesize "^3.6.1" + get-stream "^3.0.0" + ipfs-unixfs "^0.1.14" + mime-types "^2.1.19" + multihashes "^0.4.13" + promisify-es6 "^1.0.3" + stream-to-blob "^1.0.1" + +ipfs-http-response@~0.1.2: version "0.1.4" resolved "https://registry.yarnpkg.com/ipfs-http-response/-/ipfs-http-response-0.1.4.tgz#b27303bb7430978b0a182379189900a034bda9d9" dependencies: @@ -5618,7 +5725,7 @@ is-symbol@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.1.tgz#3cc59f00025194b6ab2e38dbae6689256b660572" -is-typedarray@^1.0.0: +is-typedarray@^1.0.0, is-typedarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" @@ -5674,6 +5781,10 @@ isobject@^3.0.0, isobject@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/isobject/-/isobject-3.0.1.tgz#4e431e92b11a9731636aa1f9c8d1ccbcfdab78df" +isstream@~0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" + istanbul-lib-coverage@^1.1.2, istanbul-lib-coverage@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-1.2.0.tgz#f7d8f2e42b97e37fe796114cb0f9d68b5e3a4341" @@ -5810,6 +5921,10 @@ jsbn@1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-1.1.0.tgz#b01307cb29b618a1ed26ec79e911f803c4da0040" +jsbn@~0.1.0: + version "0.1.1" + resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" + jsesc@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-1.3.0.tgz#46c3fec8c1892b12b0833db9bc7622176dbab34b" @@ -5840,6 +5955,10 @@ json-schema-traverse@^0.4.1: version "0.4.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" +json-schema@0.2.3: + version "0.2.3" + resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" + json-stable-stringify-without-jsonify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" @@ -5850,7 +5969,7 @@ json-stable-stringify@^1.0.0, json-stable-stringify@^1.0.1: dependencies: jsonify "~0.0.0" -json-stringify-safe@^5.0.1: +json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" @@ -5907,6 +6026,15 @@ jsonwebtoken@8.2.1: ms "^2.1.1" xtend "^4.0.1" +jsprim@^1.2.2: + version "1.4.1" + resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" + dependencies: + assert-plus "1.0.0" + extsprintf "1.3.0" + json-schema "0.2.3" + verror "1.10.0" + jsx-ast-utils@^1.3.4: version "1.4.1" resolved "https://registry.yarnpkg.com/jsx-ast-utils/-/jsx-ast-utils-1.4.1.tgz#3867213e8dd79bf1e8f2300c0cfc1efb182c0df1" @@ -7034,7 +7162,7 @@ mime-db@~1.33.0: version "1.33.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.33.0.tgz#a3492050a5cb9b63450541e39d9788d2272783db" -mime-types@2.1.19, mime-types@^2.1.19: +mime-types@2.1.19, mime-types@^2.1.19, mime-types@~2.1.17: version "2.1.19" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.19.tgz#71e464537a7ef81c15f2db9d97e913fc0ff606f0" dependencies: @@ -7791,6 +7919,10 @@ nyc@12.0.2: yargs "11.1.0" yargs-parser "^8.0.0" +oauth-sign@~0.8.2: + version "0.8.2" + resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43" + object-assign@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-2.1.1.tgz#43c36e5d569ff8e4816c4efa8be02d26967c18aa" @@ -8245,6 +8377,10 @@ pend@~1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/pend/-/pend-1.2.0.tgz#7a57eb550a6783f9115331fcf4663d5c8e007a50" +performance-now@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" + pez@2.x.x: version "2.1.5" resolved "https://registry.yarnpkg.com/pez/-/pez-2.1.5.tgz#5ec2cc62500cc3eb4236d4a414cf5a17b5eb5007" @@ -8762,7 +8898,7 @@ punycode@2.x.x, punycode@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" -punycode@^1.2.4: +punycode@^1.2.4, punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" @@ -8776,7 +8912,7 @@ qs@6.5.1: version "6.5.1" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" -qs@^6.5.1, qs@^6.5.2: +qs@^6.5.1, qs@^6.5.2, qs@~6.5.1: version "6.5.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" @@ -9262,7 +9398,7 @@ safe-regex@^1.1.0: dependencies: ret "~0.1.10" -"safer-buffer@>= 2.1.2 < 3": +"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" @@ -10026,6 +10162,21 @@ sprintf-js@~1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" +sshpk@^1.7.0: + version "1.14.2" + resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.14.2.tgz#c6fc61648a3d9c4e764fd3fcdf4ea105e492ba98" + dependencies: + asn1 "~0.2.3" + assert-plus "^1.0.0" + dashdash "^1.12.0" + getpass "^0.1.1" + safer-buffer "^2.0.2" + optionalDependencies: + bcrypt-pbkdf "^1.0.0" + ecc-jsbn "~0.1.1" + jsbn "~0.1.0" + tweetnacl "~0.14.0" + ssri@^5.2.4: version "5.3.0" resolved "https://registry.yarnpkg.com/ssri/-/ssri-5.3.0.tgz#ba3872c9c6d33a0704a7d71ff045e5ec48999d06" @@ -10590,6 +10741,12 @@ tosource@1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/tosource/-/tosource-1.0.0.tgz#42d88dd116618bcf00d6106dd5446f3427902ff1" +tough-cookie@~2.3.3: + version "2.3.4" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.4.tgz#ec60cee38ac675063ffc97a5c18970578ee83655" + dependencies: + punycode "^1.4.1" + tr46@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/tr46/-/tr46-1.0.1.tgz#a8b13fd6bfd2489519674ccde55ba3693b706d09" @@ -10654,6 +10811,10 @@ tunnel-agent@^0.6.0: dependencies: safe-buffer "^5.0.1" +tweetnacl@^0.14.3, tweetnacl@~0.14.0: + version "0.14.5" + resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" + tweetnacl@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-1.0.0.tgz#713d8b818da42068740bf68386d0479e66fc8a7b" @@ -10935,6 +11096,14 @@ vary@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/vary/-/vary-1.1.2.tgz#2299f02c6ded30d4a5961b0b9f74524a18f634fc" +verror@1.10.0: + version "1.10.0" + resolved "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz#3a105ca17053af55d6e270c1f8288682e18da400" + dependencies: + assert-plus "^1.0.0" + core-util-is "1.0.2" + extsprintf "^1.2.0" + vise@2.x.x: version "2.0.2" resolved "https://registry.yarnpkg.com/vise/-/vise-2.0.2.tgz#6b08e8fb4cb76e3a50cd6dd0ec37338e811a0d39" From a986ddbb316265801a5c47d0e7ab05aaacc271fe Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Mon, 13 Aug 2018 01:23:34 +0200 Subject: [PATCH 22/31] feat(libdweb): switch to async handler It enables us to detect and provide custom contentType and encoding based on first 512 bytes of received IPFS data. --- add-on/src/lib/ipfs-protocol-libdweb.js | 124 +++++++++++++------ add-on/src/lib/mime-sniff.js | 3 + package.json | 12 +- yarn.lock | 152 +++++++++++++++++------- 4 files changed, 204 insertions(+), 87 deletions(-) diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index fc2ddc0b2..006866acf 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -2,51 +2,54 @@ /* eslint-env browser, webextensions */ import {asyncIterateStream} from 'async-iterate-stream/asyncIterateStream' +// import streamHead from 'stream-head' const { resolver } = require('ipfs-http-response') const { mimeSniff } = require('./mime-sniff') +// const detectContentType = require('ipfs-http-response/src/utils/content-type') const toArrayBuffer = require('to-arraybuffer') const peek = require('buffer-peek-stream') // const dirView = require('./dir-view') const PathUtils = require('ipfs/src/http/gateway/utils/path') const isStream = require('is-stream') +const textBuffer = (data) => new TextEncoder('utf-8').encode(data).buffer + /* protocol handler for mozilla/libdweb */ exports.createIpfsUrlProtocolHandler = (getIpfs, dnsLink) => { - return request => { + return async (request) => { console.time('[ipfs-companion] LibdwebProtocolHandler') console.log(`[ipfs-companion] handling ${request.url}`) - try { + const ipfs = getIpfs() + const url = request.url + // Get /ipfs/ path for URL (resolve to immutable snapshot if ipns://) + const path = immutableIpfsPath(url, dnsLink) + // Then, fetch response from IPFS + const {content, contentType, contentEncoding} = await getResponse(ipfs, url, path) + + // console.log(`contentType=${contentType}, contentEncoding=${contentEncoding}, content`, content) + return { - // Notes: - // - omitted contentType on purpose to enable mime-sniffing by browser - // - // TODO: - // - detect invalid addrs and display error page - content: streamRespond(getIpfs, dnsLink, request) + contentEncoding, + contentType, + content: streamRespond(content) } } catch (err) { console.error(`[ipfs-companion] failed to get data for ${request.url}`, err) + return { + contentEncoding: 'utf-8', + contentType: 'text/plain', + content: streamRespond(toErrorResponse(request, err)) + } + } finally { + console.timeEnd('[ipfs-companion] LibdwebProtocolHandler') } - console.timeEnd('[ipfs-companion] LibdwebProtocolHandler') } } -async function * streamRespond (getIpfs, dnsLink, request) { - let response - try { - const ipfs = getIpfs() - const url = request.url - // Get /ipfs/ path for URL (resolve to immutable snapshot if ipns://) - const path = immutableIpfsPath(url, dnsLink) - // Then, fetch response from IPFS - response = await getResponse(ipfs, url, path) - } catch (error) { - yield toErrorResponse(request, error) - return - } +async function * streamRespond (response) { if (isStream(response)) { for await (const chunk of asyncIterateStream(response, false)) { // Buffer to ArrayBuffer @@ -60,11 +63,10 @@ async function * streamRespond (getIpfs, dnsLink, request) { // Prepare response with a meaningful error function toErrorResponse (request, error) { - console.error(`IPFS Error while getting response for ${request.url}`, error) + // console.error(`IPFS Error while getting response for ${request.url}`, error) // TODO // - create proper error page // - find a way to communicate common errors (eg. not found, invalid CID, timeout) - const textBuffer = text => new TextEncoder('utf-8').encode(text).buffer if (error.message === 'file does not exist') { // eg. when trying to access a non-existing file in a directory (basically http 404) return textBuffer('Not found') @@ -76,6 +78,9 @@ function toErrorResponse (request, error) { } function immutableIpfsPath (url, dnsLink) { + // TODO: + // - detect invalid addrs and display error page + // Move protocol to IPFS-like path let path = url.replace(/^([^:]+):\/\/*/, '/$1/') // Handle IPNS (if present) @@ -95,41 +100,82 @@ function immutableIpfsPath (url, dnsLink) { async function getResponse (ipfs, url, path) { let cid try { - // try direct resolver + // try direct resolver, then fallback to manual one const dag = await resolver.cid(ipfs, path) - // console.log('resolver.cid: ', dag) cid = dag.cid + console.log('resolver.cid', cid.toBaseEncodedString()) } catch (err) { - const errorToString = err.toString() + // console.error('error in resolver.cid', err) // handle directories - if (errorToString === 'Error: This dag node is a directory') { + if (err.cid && err.dagDirType) { const dirCid = err.cid + console.log('resolver.directory', dirCid.toBaseEncodedString()) const data = await resolver.directory(ipfs, url, dirCid) - // console.log('resolver.directory', data) + console.log('resolver.directory', data) // TODO: redirect so directory always end with `/` if (typeof data === 'string') { // return HTML with directory listing - return new TextEncoder('utf-8').encode(data).buffer + return { + content: textBuffer(data), + contentType: 'text/html', + contentEncoding: 'utf-8' + } } else if (Array.isArray(data)) { + console.log('resolver.directory.indexes', data) // return first index file path = PathUtils.joinURLParts(path, data[0].name) return getResponse(ipfs, url, path) } throw new Error('Invalid output of resolver.directory') + } else if (err.parentDagNode && err.missingLinkName) { + // It may be legitimate error, but it could also be a part of hamt-sharded-directory + // (example: ipns://tr.wikipedia-on-ipfs.org/wiki/Anasayfa.html) + // which is not supported by resolver.cid from ipfs-http-response at this time. + // Until ipfs.resolve support with sharding is added upstream, we use fallback below. + // TODO remove this after ipfs-http-response switch to ipfs.resolve + // or sharding is supported by some other means + try { + const matchingLinks = (await ipfs.ls(err.parentDagNode)).filter(item => item.name === err.missingLinkName) + if (matchingLinks.length > 0) { + cid = path + } else { + throw err + } + } catch (err) { + if (err.message === 'invalid node type') { + throw new Error('hamt-sharded-directory support is spotty with js-ipfs at this time, try go-ipfs until a fix is found') + } else { + // TODO: investigate issue with js-ipfs and ipns://tr.wikipedia-on-ipfs.org/wiki/Anasayfa.html + // (probably edge case relate to sharding) + // For now we fallback to ipfs.files.catReadableStream(full path) + cid = path + } + } + } else { + // unexpected issue, return error + throw err } - throw err } // Efficient mime-sniff over initial bytes - // TODO: rignt now it is only logged, use contentType somehow + // const { stream, head } = await streamHead(ipfs.files.catReadableStream(cid), {bytes: 512}) + // const contentType = mimeSniff(head, new URL(url).pathname) || undefined + // below old version with buffer-peek-stream const { stream, contentType } = await new Promise((resolve, reject) => { - peek(ipfs.files.catReadableStream(cid), 512, (err, data, stream) => { - if (err) return reject(err) - const contentType = mimeSniff(data, url) || 'application/octet-stream' - resolve({ stream, contentType }) - }) + try { + console.log(`ipfs.files.catReadableStream(${cid})`) + const catStream = ipfs.files.catReadableStream(cid) + peek(catStream, 512, (err, data, stream) => { + if (err) return reject(err) + const contentType = mimeSniff(data, new URL(url).pathname) || undefined + // TODO: switch to upstream const contentType = detectContentType(new URL(url).pathname, data) || 'application/octet-stream' + resolve({ stream, contentType }) + }) + } catch (err) { + reject(err) + } }) console.log(`[ipfs-companion] [ipfs://] handler read ${path} and internally mime-sniffed it as ${contentType}`) - // - return stream + + return {content: stream, contentType} } diff --git a/add-on/src/lib/mime-sniff.js b/add-on/src/lib/mime-sniff.js index cc068ec5a..8aaa60a90 100644 --- a/add-on/src/lib/mime-sniff.js +++ b/add-on/src/lib/mime-sniff.js @@ -1,3 +1,6 @@ +'use strict' +/* eslint-env browser, webextensions */ + const docSniff = require('doc-sniff') const fileType = require('file-type') const isSvg = require('is-svg') diff --git a/package.json b/package.json index 75e8ad8ca..5570801d8 100644 --- a/package.json +++ b/package.json @@ -76,7 +76,7 @@ "cross-env": "5.2.0", "fakefile": "0.0.9", "fs-promise": "2.0.3", - "get-firefox": "2.1.1", + "get-firefox": "2.2.0", "husky": "0.14.3", "ignore-styles": "5.0.1", "json": "9.0.6", @@ -91,7 +91,7 @@ "sinon": "6.1.4", "sinon-chrome": "2.3.2", "standard": "10.0.3", - "terser": "3.8.0", + "terser": "3.8.1", "transform-loader": "0.2.4", "web-ext": "2.8.0", "webpack": "4.16.5", @@ -107,15 +107,15 @@ "file-type": "8.1.0", "filereader-pull-stream": "1.0.0", "filesize": "3.6.1", - "ipfs": "0.31.2", - "ipfs-api": "22.3.0", + "ipfs": "0.31.4", + "ipfs-api": "23.0.0", "ipfs-css": "0.7.0", - "ipfs-http-response": "lidel/js-ipfs-http-response.git#7382681983809d6661e33664fc9b9adac0b9d201", + "ipfs-http-response": "github:lidel/js-ipfs-http-response.git#65f22ad654843946fdff8f26c7b3a69e2905bdaf", "ipfs-postmsg-proxy": "3.0.0", "is-ipfs": "0.4.2", "is-stream": "1.1.0", "is-svg": "3.0.0", - "libdweb": "mozilla/libdweb.git#fbff435b33542b02bc35c0bb8c27bc203e6d4e6e", + "libdweb": "github:mozilla/libdweb.git#185290fb35dc2846e7f31b0a52d0afbb412ab7b5", "lru_map": "0.3.3", "mime-types": "2.1.19", "p-queue": "2.4.2", diff --git a/yarn.lock b/yarn.lock index d0e7da7ca..fefae702c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4285,19 +4285,20 @@ get-caller-file@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" -get-firefox@2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/get-firefox/-/get-firefox-2.1.1.tgz#1dbafe1e357fb292e816d4c64b6fc7a5153bf7a7" +get-firefox@2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/get-firefox/-/get-firefox-2.2.0.tgz#7ea8fc874bb952295de33705aea21db14ce2a55e" dependencies: chalk "^2.4.1" decompress "^4.2.0" + is-ci "^1.1.0" listr "^0.14.0" meow "^5.0.0" moz-download-url "^2.0.0" - node-fetch "^2.1.2" + node-fetch "^2.2.0" sha "^2.0.1" stream-to-promise "^2.2.0" - taskcluster-client "^11.0.0" + taskcluster-client "^11.0.3" get-folder-size@^2.0.0: version "2.0.0" @@ -4992,7 +4993,48 @@ ipaddr.js@1.8.0: version "1.8.0" resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.8.0.tgz#eaa33d6ddd7ace8f7f6fe0c9ca0440e706738b1e" -ipfs-api@22.3.0, ipfs-api@^22.2.4: +ipfs-api@23.0.0: + version "23.0.0" + resolved "https://registry.yarnpkg.com/ipfs-api/-/ipfs-api-23.0.0.tgz#112207ea421d4aeda3724de91a0319b9fe303f3e" + dependencies: + async "^2.6.1" + big.js "^5.1.2" + bs58 "^4.0.1" + cids "~0.5.3" + concat-stream "^1.6.2" + debug "^3.1.0" + detect-node "^2.0.3" + flatmap "0.0.3" + glob "^7.1.2" + ipfs-block "~0.7.1" + ipfs-unixfs "~0.1.15" + ipld-dag-cbor "~0.12.1" + ipld-dag-pb "~0.14.6" + is-ipfs "~0.4.2" + is-pull-stream "0.0.0" + is-stream "^1.1.0" + libp2p-crypto "~0.13.0" + lru-cache "^4.1.3" + multiaddr "^5.0.0" + multibase "~0.4.0" + multihashes "~0.4.13" + ndjson "^1.5.0" + once "^1.4.0" + peer-id "~0.11.0" + peer-info "~0.14.1" + promisify-es6 "^1.0.3" + pull-defer "~0.2.2" + 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" + stream-http "^2.8.3" + stream-to-pull-stream "^1.7.2" + streamifier "~0.1.1" + tar-stream "^1.6.1" + +ipfs-api@^22.2.4: version "22.3.0" resolved "https://registry.yarnpkg.com/ipfs-api/-/ipfs-api-22.3.0.tgz#29935c5d9ca533cefef62288e00a8b7eab412ab7" dependencies: @@ -5082,9 +5124,9 @@ ipfs-css@0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/ipfs-css/-/ipfs-css-0.7.0.tgz#d612d4f85535268483859663b4bf6326edaae1a3" -ipfs-http-response@lidel/js-ipfs-http-response.git#7382681983809d6661e33664fc9b9adac0b9d201: +"ipfs-http-response@github:lidel/js-ipfs-http-response.git#65f22ad654843946fdff8f26c7b3a69e2905bdaf": version "0.1.4" - resolved "https://codeload.github.com/lidel/js-ipfs-http-response/tar.gz/7382681983809d6661e33664fc9b9adac0b9d201" + resolved "https://codeload.github.com/lidel/js-ipfs-http-response/tar.gz/65f22ad654843946fdff8f26c7b3a69e2905bdaf" dependencies: async "^2.6.0" cids "^0.5.3" @@ -5114,9 +5156,9 @@ ipfs-http-response@~0.1.2: promisify-es6 "^1.0.3" stream-to-blob "^1.0.1" -ipfs-mfs@~0.2.3: - version "0.2.5" - resolved "https://registry.yarnpkg.com/ipfs-mfs/-/ipfs-mfs-0.2.5.tgz#d093c6d2dd5060b2ac29febe0dbae98bc2460ec8" +ipfs-mfs@~0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/ipfs-mfs/-/ipfs-mfs-0.3.0.tgz#2da1d98832b3140d40d9e79dd89c29bb925b7edd" dependencies: async "^2.6.1" blob "~0.0.4" @@ -5126,7 +5168,7 @@ ipfs-mfs@~0.2.3: filereader-stream "^2.0.0" interface-datastore "~0.4.2" ipfs-unixfs "~0.1.15" - ipfs-unixfs-engine "~0.31.3" + ipfs-unixfs-engine "~0.32.1" is-pull-stream "~0.0.0" is-stream "^1.1.0" joi "^13.4.0" @@ -5135,6 +5177,7 @@ ipfs-mfs@~0.2.3: once "^1.4.0" promisify-es6 "^1.0.3" pull-cat "^1.1.11" + pull-defer "~0.2.2" pull-paramap "^1.2.2" pull-pushable "^2.2.0" pull-stream "^3.6.8" @@ -5194,20 +5237,18 @@ ipfs-repo@~0.22.1: multiaddr "^4.0.0" pull-stream "^3.6.7" -ipfs-unixfs-engine@~0.31.3: - version "0.31.3" - resolved "https://registry.yarnpkg.com/ipfs-unixfs-engine/-/ipfs-unixfs-engine-0.31.3.tgz#79e220395c3f30476cacfa481220623110b20429" +ipfs-unixfs-engine@~0.32.1: + version "0.32.1" + resolved "https://registry.yarnpkg.com/ipfs-unixfs-engine/-/ipfs-unixfs-engine-0.32.1.tgz#21a5f01147a6db116ea580681e095df5ddf4063e" dependencies: async "^2.6.1" - bs58 "^4.0.1" cids "~0.5.3" deep-extend "~0.6.0" ipfs-unixfs "~0.1.15" - ipld "~0.17.2" - ipld-dag-pb "~0.14.5" + ipld "~0.17.3" + ipld-dag-pb "~0.14.6" left-pad "^1.3.0" lodash "^4.17.10" - multihashes "~0.4.13" multihashing-async "~0.5.1" pull-batch "^1.0.0" pull-block "^1.4.0" @@ -5220,7 +5261,9 @@ ipfs-unixfs-engine@~0.31.3: pull-through "^1.0.18" pull-traverse "^1.0.3" pull-write "^1.1.4" + rabin "^1.6.0" sparse-array "^1.3.1" + stream-to-pull-stream "^1.7.2" ipfs-unixfs@^0.1.14, ipfs-unixfs@~0.1.15: version "0.1.15" @@ -5228,9 +5271,9 @@ ipfs-unixfs@^0.1.14, ipfs-unixfs@~0.1.15: dependencies: protons "^1.0.0" -ipfs@0.31.2: - version "0.31.2" - resolved "https://registry.yarnpkg.com/ipfs/-/ipfs-0.31.2.tgz#d297122d23a379ebee0a65d0df7b9540ccb6445a" +ipfs@0.31.4: + version "0.31.4" + resolved "https://registry.yarnpkg.com/ipfs/-/ipfs-0.31.4.tgz#3b55c6b051b500e491cddfac9e9509b82a80beaa" dependencies: "@nodeutils/defaults-deep" "^1.1.0" async "^2.6.1" @@ -5258,11 +5301,11 @@ ipfs@0.31.2: ipfs-block "~0.7.1" ipfs-block-service "~0.14.0" ipfs-http-response "~0.1.2" - ipfs-mfs "~0.2.3" + ipfs-mfs "~0.3.0" ipfs-multipart "~0.1.0" ipfs-repo "~0.22.1" ipfs-unixfs "~0.1.15" - ipfs-unixfs-engine "~0.31.3" + ipfs-unixfs-engine "~0.32.1" ipld "~0.17.3" ipld-dag-cbor "~0.12.1" ipld-dag-pb "~0.14.6" @@ -5408,7 +5451,7 @@ ipld-zcash@~0.1.4: multihashing-async "~0.5.1" zcash-bitcore-lib "~0.13.20-rc3" -ipld@~0.17.2, ipld@~0.17.3: +ipld@~0.17.3: version "0.17.3" resolved "https://registry.yarnpkg.com/ipld/-/ipld-0.17.3.tgz#ede5440a5b8469b1f0280502e21a5d83011d8630" dependencies: @@ -5493,7 +5536,7 @@ is-callable@^1.1.1, is-callable@^1.1.3: version "1.1.4" resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.4.tgz#1e1adf219e1eeb684d691f9d6a05ff0d30a24d75" -is-ci@^1.0.10: +is-ci@^1.0.10, is-ci@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-ci/-/is-ci-1.1.0.tgz#247e4162e7860cebbdaf30b774d6b0ac7dcfe7a5" dependencies: @@ -6262,9 +6305,9 @@ levn@^0.3.0, levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" -libdweb@mozilla/libdweb.git#fbff435b33542b02bc35c0bb8c27bc203e6d4e6e: +"libdweb@github:mozilla/libdweb.git#185290fb35dc2846e7f31b0a52d0afbb412ab7b5": version "0.0.0" - resolved "https://codeload.github.com/mozilla/libdweb/tar.gz/fbff435b33542b02bc35c0bb8c27bc203e6d4e6e" + resolved "https://codeload.github.com/mozilla/libdweb/tar.gz/185290fb35dc2846e7f31b0a52d0afbb412ab7b5" libp2p-bootstrap@~0.9.3: version "0.9.3" @@ -7515,7 +7558,7 @@ mz@2.7.0, mz@^2.6.0: object-assign "^4.0.1" thenify-all "^1.0.0" -nan@^2.10.0, nan@^2.2.1, nan@^2.9.2, nan@~2.10.0: +nan@^2.1.0, nan@^2.10.0, nan@^2.2.1, nan@^2.9.2, nan@~2.10.0: version "2.10.0" resolved "https://registry.yarnpkg.com/nan/-/nan-2.10.0.tgz#96d0cd610ebd58d4b4de9cc0c6828cda99c7548f" @@ -7729,7 +7772,7 @@ node-abi@^2.2.0: dependencies: semver "^5.4.1" -node-fetch@^2.1.2: +node-fetch@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.2.0.tgz#4ee79bde909262f9775f731e3656d0db55ced5b5" @@ -8521,6 +8564,26 @@ postmsg-rpc@^2.4.0: dependencies: shortid "^2.2.8" +prebuild-install@^2.1.0: + version "2.5.3" + resolved "https://registry.yarnpkg.com/prebuild-install/-/prebuild-install-2.5.3.tgz#9f65f242782d370296353710e9bc843490c19f69" + dependencies: + detect-libc "^1.0.3" + expand-template "^1.0.2" + github-from-package "0.0.0" + minimist "^1.2.0" + mkdirp "^0.5.1" + node-abi "^2.2.0" + noop-logger "^0.1.1" + npmlog "^4.0.1" + os-homedir "^1.0.1" + pump "^2.0.1" + rc "^1.1.6" + simple-get "^2.7.0" + tar-fs "^1.13.0" + tunnel-agent "^0.6.0" + which-pm-runs "^1.0.0" + prebuild-install@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/prebuild-install/-/prebuild-install-4.0.0.tgz#206ce8106ce5efa4b6cf062fc8a0a7d93c17f3a8" @@ -8938,6 +9001,18 @@ quick-lru@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-1.1.0.tgz#4360b17c61136ad38078397ff11416e186dcfbb8" +rabin@^1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/rabin/-/rabin-1.6.0.tgz#e05690b13056f08c80098e3ad71b90530038e355" + dependencies: + bindings "^1.2.1" + bl "^1.0.0" + debug "^2.2.0" + minimist "^1.2.0" + nan "^2.1.0" + prebuild-install "^2.1.0" + readable-stream "^2.0.4" + randombytes@^2.0.0, randombytes@^2.0.1, randombytes@^2.0.3, randombytes@^2.0.5: version "2.0.6" resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.0.6.tgz#d302c522948588848a8d300c932b44c24231da80" @@ -10535,7 +10610,7 @@ tar@^4: safe-buffer "^5.1.2" yallist "^3.0.2" -taskcluster-client@^11.0.0: +taskcluster-client@^11.0.3: version "11.0.3" resolved "https://registry.yarnpkg.com/taskcluster-client/-/taskcluster-client-11.0.3.tgz#f71fd2d75dc4912ecc6c69fc56994eae088265aa" dependencies: @@ -10582,9 +10657,10 @@ term-size@^1.2.0: dependencies: execa "^0.7.0" -terser@3.8.0: - version "3.8.0" - resolved "https://registry.yarnpkg.com/terser/-/terser-3.8.0.tgz#66a4f4f500d2c829faab840f318c49cc471d73ae" +terser@3.8.1, uglify-es@^3.3.4, "uglify-es@npm:terser": + name uglify-es + version "3.8.1" + resolved "https://registry.yarnpkg.com/terser/-/terser-3.8.1.tgz#cb70070ac9e0a71add169dfb63c0a64fca2738ac" dependencies: commander "~2.16.0" source-map "~0.6.1" @@ -10850,14 +10926,6 @@ typeforce@^1.11.3: version "1.12.0" resolved "https://registry.yarnpkg.com/typeforce/-/typeforce-1.12.0.tgz#ca40899919f1466d7819e37be039406beb912a2e" -uglify-es@^3.3.4, "uglify-es@npm:terser": - version "3.8.1" - resolved "https://registry.yarnpkg.com/terser/-/terser-3.8.1.tgz#cb70070ac9e0a71add169dfb63c0a64fca2738ac" - dependencies: - commander "~2.16.0" - source-map "~0.6.1" - source-map-support "~0.5.6" - uglify-js@^2.6: version "2.8.29" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.8.29.tgz#29c5733148057bb4e1f75df35b7a9cb72e6a59dd" From b394646308c9ea5ae0c743e9b14527f74e0fcdc6 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Mon, 13 Aug 2018 01:26:31 +0200 Subject: [PATCH 23/31] fix(libdweb): detection of image/svg+xml If we don't return proper contentType SVG images will not be rendered by the browser. Removed is-svg: it did not work anyway, requires entire file but we only had first 512 bytes. This change just fixes already detected application/xml if they are under path with .svg filename. --- add-on/src/lib/mime-sniff.js | 14 ++++++++------ package.json | 5 ++--- yarn.lock | 18 ++++-------------- 3 files changed, 14 insertions(+), 23 deletions(-) diff --git a/add-on/src/lib/mime-sniff.js b/add-on/src/lib/mime-sniff.js index 8aaa60a90..c44afeb31 100644 --- a/add-on/src/lib/mime-sniff.js +++ b/add-on/src/lib/mime-sniff.js @@ -3,13 +3,11 @@ const docSniff = require('doc-sniff') const fileType = require('file-type') -const isSvg = require('is-svg') const mime = require('mime-types') /* * A quick, best effort mime sniffing fn, via: * @see https://github.com/sindresorhus/file-type - * @see https://github.com/sindresorhus/is-svg * @see https://github.com/bitinn/doc-sniff * * buffer => 'mime/type' @@ -19,13 +17,17 @@ const mime = require('mime-types') exports.mimeSniff = function (buff, path) { // deals with buffers, and uses magic number detection const fileTypeRes = fileType(buff) - if (fileTypeRes) return fileTypeRes.mime + if (fileTypeRes) { + const pathSniffRes = mime.lookup(path) + if (fileTypeRes.mime === 'application/xml' && pathSniffRes === 'image/svg+xml') { + // detected SVGs + return pathSniffRes + } + return fileTypeRes.mime + } const str = buff.toString('utf8') - // You gotta read the file to figure out if something is an svg - if (isSvg(str)) return 'image/svg+xml' - // minimal whatwg style doc sniff. const docSniffRes = docSniff(false, str) diff --git a/package.json b/package.json index 5570801d8..67dd4e6a9 100644 --- a/package.json +++ b/package.json @@ -110,12 +110,11 @@ "ipfs": "0.31.4", "ipfs-api": "23.0.0", "ipfs-css": "0.7.0", - "ipfs-http-response": "github:lidel/js-ipfs-http-response.git#65f22ad654843946fdff8f26c7b3a69e2905bdaf", + "ipfs-http-response": "https://github.com/lidel/js-ipfs-http-response/tarball/65f22ad654843946fdff8f26c7b3a69e2905bdaf/js-ipfs-http-response.tar.gz", "ipfs-postmsg-proxy": "3.0.0", "is-ipfs": "0.4.2", "is-stream": "1.1.0", - "is-svg": "3.0.0", - "libdweb": "github:mozilla/libdweb.git#185290fb35dc2846e7f31b0a52d0afbb412ab7b5", + "libdweb": "https://github.com/mozilla/libdweb/tarball/185290fb35dc2846e7f31b0a52d0afbb412ab7b5/libdweb.tar.gz", "lru_map": "0.3.3", "mime-types": "2.1.19", "p-queue": "2.4.2", diff --git a/yarn.lock b/yarn.lock index fefae702c..e09c4d780 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4686,10 +4686,6 @@ hosted-git-info@^2.1.4: version "2.7.1" resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.7.1.tgz#97f236977bd6e125408930ff6de3eec6281ec047" -html-comment-regex@^1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/html-comment-regex/-/html-comment-regex-1.1.1.tgz#668b93776eaae55ebde8f3ad464b307a4963625e" - htmlparser2@^3.9.1: version "3.9.2" resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-3.9.2.tgz#1bdf87acca0f3f9e53fa4fcceb0f4b4cbb00b338" @@ -5124,9 +5120,9 @@ ipfs-css@0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/ipfs-css/-/ipfs-css-0.7.0.tgz#d612d4f85535268483859663b4bf6326edaae1a3" -"ipfs-http-response@github:lidel/js-ipfs-http-response.git#65f22ad654843946fdff8f26c7b3a69e2905bdaf": +"ipfs-http-response@https://github.com/lidel/js-ipfs-http-response/tarball/65f22ad654843946fdff8f26c7b3a69e2905bdaf/js-ipfs-http-response.tar.gz": version "0.1.4" - resolved "https://codeload.github.com/lidel/js-ipfs-http-response/tar.gz/65f22ad654843946fdff8f26c7b3a69e2905bdaf" + resolved "https://github.com/lidel/js-ipfs-http-response/tarball/65f22ad654843946fdff8f26c7b3a69e2905bdaf/js-ipfs-http-response.tar.gz#a63a85c67f2b2564a31f9ce20ca1e80e24cd4dda" dependencies: async "^2.6.0" cids "^0.5.3" @@ -5758,12 +5754,6 @@ is-stream@1.1.0, is-stream@^1.0.0, is-stream@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" -is-svg@3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/is-svg/-/is-svg-3.0.0.tgz#9321dbd29c212e5ca99c4fa9794c714bcafa2f75" - dependencies: - html-comment-regex "^1.1.0" - is-symbol@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.1.tgz#3cc59f00025194b6ab2e38dbae6689256b660572" @@ -6305,9 +6295,9 @@ levn@^0.3.0, levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" -"libdweb@github:mozilla/libdweb.git#185290fb35dc2846e7f31b0a52d0afbb412ab7b5": +"libdweb@https://github.com/mozilla/libdweb/tarball/185290fb35dc2846e7f31b0a52d0afbb412ab7b5/libdweb.tar.gz": version "0.0.0" - resolved "https://codeload.github.com/mozilla/libdweb/tar.gz/185290fb35dc2846e7f31b0a52d0afbb412ab7b5" + resolved "https://github.com/mozilla/libdweb/tarball/185290fb35dc2846e7f31b0a52d0afbb412ab7b5/libdweb.tar.gz#2cbc2efba6ecfdc0afb552e389ecfefff0f0f763" libp2p-bootstrap@~0.9.3: version "0.9.3" From e4c4bec6e557e8774043b820a6e2bdca063e7bb0 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Mon, 13 Aug 2018 12:54:54 +0200 Subject: [PATCH 24/31] fix(libdweb): render markdown as plain text --- add-on/src/lib/mime-sniff.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/add-on/src/lib/mime-sniff.js b/add-on/src/lib/mime-sniff.js index c44afeb31..cf1814e02 100644 --- a/add-on/src/lib/mime-sniff.js +++ b/add-on/src/lib/mime-sniff.js @@ -31,6 +31,11 @@ exports.mimeSniff = function (buff, path) { // minimal whatwg style doc sniff. const docSniffRes = docSniff(false, str) + if (docSniffRes === 'text/plain' && mime.lookup(path) === 'text/markdown') { + // force plain text, otherwise browser triggers download of .md files + return 'text/plain' + } + if (!docSniffRes || docSniffRes === 'text/plain') { // fallback to guessing by file extension return mime.lookup(path) From 31cb6645a1f00479779ee2ad96844d5a504c1c3c Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Mon, 13 Aug 2018 14:42:24 +0200 Subject: [PATCH 25/31] docs(libdweb): add note about fix for yarn caching github deps --- docs/libdweb.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/docs/libdweb.md b/docs/libdweb.md index b8b2d787f..aac127091 100644 --- a/docs/libdweb.md +++ b/docs/libdweb.md @@ -47,7 +47,7 @@ npm run libdweb:build npm run libdweb:firefox ``` -### Manually run with different firefox binary✂️ +### Manually run with different firefox binary To run your extension in libdweb context: @@ -62,6 +62,13 @@ Additional notes: - Script `libdweb:firefox` will download latest Firefox Nightly to `./firefox/firefox` - After initially running `libdweb:build` it is ok to use `yarn watch` – it will work as expected +## Known Issues + +If you are using `yarn` it may not update github-based dependencies and produce bogus `this.content is undefined` errors. + +Fix is to make sure you run the latest versions of `libdweb` and other dev deps by removing yarn cache. +Execute `yarn cache clean`. + ## Appendix: Smoke-Testing libdweb APIs #### Protocol Handler API @@ -73,6 +80,7 @@ Additional notes: ## References - [ipfs-companion/issues/#343](https://github.com/ipfs-shipyard/ipfs-companion/issues/343) – Create WebExtensions Experiments to Prototype Missing APIs + - [ipfs-companion/pr/533](https://github.com/ipfs-shipyard/ipfs-companion/pull/533) - `ipfs://` and `ipns://` protocol handlers with libdweb API - https://github.com/mozilla/libdweb/ – Extension context containing an experimental libdweb APIs - https://github.com/orgs/libdweb – API adapters for seamless libdweb integration - `#dweb` @ [irc.mozilla.org](https://wiki.mozilla.org/IRC#Connect_to_the_Mozilla_IRC_server) From 3e1fd759cab81eddbdab914b23496cb77742b447 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Mon, 13 Aug 2018 14:56:45 +0200 Subject: [PATCH 26/31] fix(libdweb): decodeURI(path) before IPFS lookup Example: ipns://tr.wikipedia-on-ipfs.org/wiki/G%C3%BCne%C5%9F_r%C3%BCzg%C3%A2r%C4%B1.html --- add-on/src/lib/ipfs-protocol-libdweb.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 006866acf..6a03a15ca 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -83,6 +83,8 @@ function immutableIpfsPath (url, dnsLink) { // Move protocol to IPFS-like path let path = url.replace(/^([^:]+):\/\/*/, '/$1/') + // Unescape special characters, eg. ipns://tr.wikipedia-on-ipfs.org/wiki/G%C3%BCne%C5%9F_r%C3%BCzg%C3%A2r%C4%B1.html + path = decodeURI(path) // Handle IPNS (if present) if (path.startsWith('/ipns/')) { // js-ipfs does not implement ipfs.name.resolve yet, so we only do dnslink lookup From 87ef47413e7d86feee1d1444082cb8a3a2d54194 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Thu, 16 Aug 2018 01:07:14 +0200 Subject: [PATCH 27/31] fix(libdweb): allow loading of cross-origin assets --- add-on/manifest.firefox.json | 2 +- add-on/src/lib/ipfs-protocol-libdweb.js | 13 +++++++++---- package.json | 4 ++-- yarn.lock | 4 ++-- 4 files changed, 14 insertions(+), 9 deletions(-) diff --git a/add-on/manifest.firefox.json b/add-on/manifest.firefox.json index 68641ef23..c2d189682 100644 --- a/add-on/manifest.firefox.json +++ b/add-on/manifest.firefox.json @@ -8,7 +8,7 @@ "applications": { "gecko": { "id": "ipfs-firefox-addon@lidel.org", - "strict_min_version": "63" + "strict_min_version": "63.0" } }, "page_action": { diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 6a03a15ca..78ec73bce 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -109,11 +109,11 @@ async function getResponse (ipfs, url, path) { } catch (err) { // console.error('error in resolver.cid', err) // handle directories - if (err.cid && err.dagDirType) { + if (err.cid && err.message === 'This dag node is a directory') { const dirCid = err.cid console.log('resolver.directory', dirCid.toBaseEncodedString()) const data = await resolver.directory(ipfs, url, dirCid) - console.log('resolver.directory', data) + console.log('resolver.directory', Array.isArray(data) ? data : `returned '${typeof data}'`) // TODO: redirect so directory always end with `/` if (typeof data === 'string') { // return HTML with directory listing @@ -137,13 +137,18 @@ async function getResponse (ipfs, url, path) { // TODO remove this after ipfs-http-response switch to ipfs.resolve // or sharding is supported by some other means try { - const matchingLinks = (await ipfs.ls(err.parentDagNode)).filter(item => item.name === err.missingLinkName) - if (matchingLinks.length > 0) { + const matchingLink = (await ipfs.ls(err.parentDagNode, {resolveType: false})).find(item => item.name === err.missingLinkName) + if (matchingLink) { + console.log('resolver.cid.err.matchingLink', matchingLink) + path = path.replace(matchingLink.path, matchingLink.hash) + console.log('resolver.cid.err.path.after.matchingLink', path) cid = path + // return getResponse(ipfs, url, path) } else { throw err } } catch (err) { + console.error('Trying to recover from Error while resolver.cid', err) if (err.message === 'invalid node type') { throw new Error('hamt-sharded-directory support is spotty with js-ipfs at this time, try go-ipfs until a fix is found') } else { diff --git a/package.json b/package.json index 67dd4e6a9..dd1662fa6 100644 --- a/package.json +++ b/package.json @@ -47,7 +47,7 @@ "firefox": "web-ext run --browser-console --url about:debugging", "libdweb": "npm run libdweb:build && npm run libdweb:firefox", "libdweb:build": "npx yarn@1.9.4 && cross-env-shell RELEASE_CHANNEL=libdweb npm run dev-build", - "libdweb:firefox": "npm run get-firefox-nightly && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=./firefox/firefox --browser-console --url about:debugging", + "libdweb:firefox": "npm run get-firefox-nightly && cross-env MOZ_DISABLE_CONTENT_SANDBOX=1 web-ext run --firefox=./firefox/firefox --url about:debugging", "get-firefox-nightly": "shx test -e ./firefox/firefox || get-firefox -b nightly -e", "ci": "run-s ci:*", "ci:install": "npx yarn@1.9.4 install --frozen-lockfile || npx yarn@1.9.4 install --frozen-lockfile", @@ -114,7 +114,7 @@ "ipfs-postmsg-proxy": "3.0.0", "is-ipfs": "0.4.2", "is-stream": "1.1.0", - "libdweb": "https://github.com/mozilla/libdweb/tarball/185290fb35dc2846e7f31b0a52d0afbb412ab7b5/libdweb.tar.gz", + "libdweb": "https://github.com/mozilla/libdweb/tarball/c30af9fcf9ba2e0c03062403a8c8ac54641be586/libdweb.tar.gz", "lru_map": "0.3.3", "mime-types": "2.1.19", "p-queue": "2.4.2", diff --git a/yarn.lock b/yarn.lock index e09c4d780..124818395 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6295,9 +6295,9 @@ levn@^0.3.0, levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" -"libdweb@https://github.com/mozilla/libdweb/tarball/185290fb35dc2846e7f31b0a52d0afbb412ab7b5/libdweb.tar.gz": +"libdweb@https://github.com/mozilla/libdweb/tarball/c30af9fcf9ba2e0c03062403a8c8ac54641be586/libdweb.tar.gz": version "0.0.0" - resolved "https://github.com/mozilla/libdweb/tarball/185290fb35dc2846e7f31b0a52d0afbb412ab7b5/libdweb.tar.gz#2cbc2efba6ecfdc0afb552e389ecfefff0f0f763" + resolved "https://github.com/mozilla/libdweb/tarball/c30af9fcf9ba2e0c03062403a8c8ac54641be586/libdweb.tar.gz#b0e6bd3587a32ad07c6ed7477f702a09c747db80" libp2p-bootstrap@~0.9.3: version "0.9.3" From 8c8783565f9f7caccd2b72e9855529473cf5d695 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Thu, 16 Aug 2018 14:37:42 +0200 Subject: [PATCH 28/31] fix(libdweb): non-unwrappable cross-compartment wrapper promise error https://github.com/mozilla/libdweb/pull/71 --- package.json | 4 ++-- yarn.lock | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index dd1662fa6..f0d48d996 100644 --- a/package.json +++ b/package.json @@ -110,11 +110,11 @@ "ipfs": "0.31.4", "ipfs-api": "23.0.0", "ipfs-css": "0.7.0", - "ipfs-http-response": "https://github.com/lidel/js-ipfs-http-response/tarball/65f22ad654843946fdff8f26c7b3a69e2905bdaf/js-ipfs-http-response.tar.gz", + "ipfs-http-response": "https://github.com/lidel/js-ipfs-http-response/tarball/475aead595fbbd77cfa4a248fc27474e8d604cb1/js-ipfs-http-response.tar.gz", "ipfs-postmsg-proxy": "3.0.0", "is-ipfs": "0.4.2", "is-stream": "1.1.0", - "libdweb": "https://github.com/mozilla/libdweb/tarball/c30af9fcf9ba2e0c03062403a8c8ac54641be586/libdweb.tar.gz", + "libdweb": "https://github.com/mozilla/libdweb/tarball/dbb9697a8dd09a9ad61ce5e2204400f72d16157a/libdweb.tar.gz", "lru_map": "0.3.3", "mime-types": "2.1.19", "p-queue": "2.4.2", diff --git a/yarn.lock b/yarn.lock index 124818395..da1698dd2 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5120,9 +5120,9 @@ ipfs-css@0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/ipfs-css/-/ipfs-css-0.7.0.tgz#d612d4f85535268483859663b4bf6326edaae1a3" -"ipfs-http-response@https://github.com/lidel/js-ipfs-http-response/tarball/65f22ad654843946fdff8f26c7b3a69e2905bdaf/js-ipfs-http-response.tar.gz": +"ipfs-http-response@https://github.com/lidel/js-ipfs-http-response/tarball/475aead595fbbd77cfa4a248fc27474e8d604cb1/js-ipfs-http-response.tar.gz": version "0.1.4" - resolved "https://github.com/lidel/js-ipfs-http-response/tarball/65f22ad654843946fdff8f26c7b3a69e2905bdaf/js-ipfs-http-response.tar.gz#a63a85c67f2b2564a31f9ce20ca1e80e24cd4dda" + resolved "https://github.com/lidel/js-ipfs-http-response/tarball/475aead595fbbd77cfa4a248fc27474e8d604cb1/js-ipfs-http-response.tar.gz#6ef6ffc602e3c6b21ac6e142d55b74bca1487d2b" dependencies: async "^2.6.0" cids "^0.5.3" @@ -6295,9 +6295,9 @@ levn@^0.3.0, levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" -"libdweb@https://github.com/mozilla/libdweb/tarball/c30af9fcf9ba2e0c03062403a8c8ac54641be586/libdweb.tar.gz": +"libdweb@https://github.com/mozilla/libdweb/tarball/dbb9697a8dd09a9ad61ce5e2204400f72d16157a/libdweb.tar.gz": version "0.0.0" - resolved "https://github.com/mozilla/libdweb/tarball/c30af9fcf9ba2e0c03062403a8c8ac54641be586/libdweb.tar.gz#b0e6bd3587a32ad07c6ed7477f702a09c747db80" + resolved "https://github.com/mozilla/libdweb/tarball/dbb9697a8dd09a9ad61ce5e2204400f72d16157a/libdweb.tar.gz#2fcae1f1029940a05c35a8c3ec4293c8a4af6005" libp2p-bootstrap@~0.9.3: version "0.9.3" From 1bf413f70b1ce5b3e35b0cecb6bac5b3f1479ef8 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 14 Sep 2018 20:07:53 +0200 Subject: [PATCH 29/31] fix: missing content-sniffer Context: https://github.com/mozilla/libdweb/issues/82 --- package.json | 2 +- yarn.lock | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index f0d48d996..31f6b21bb 100644 --- a/package.json +++ b/package.json @@ -114,7 +114,7 @@ "ipfs-postmsg-proxy": "3.0.0", "is-ipfs": "0.4.2", "is-stream": "1.1.0", - "libdweb": "https://github.com/mozilla/libdweb/tarball/dbb9697a8dd09a9ad61ce5e2204400f72d16157a/libdweb.tar.gz", + "libdweb": "https://github.com/mozilla/libdweb/tarball/a78b0a0c9a1f1d3d1e3343995de7d4a9b0cb000c/libdweb.tar.gz", "lru_map": "0.3.3", "mime-types": "2.1.19", "p-queue": "2.4.2", diff --git a/yarn.lock b/yarn.lock index da1698dd2..c768f40fe 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6295,9 +6295,9 @@ levn@^0.3.0, levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" -"libdweb@https://github.com/mozilla/libdweb/tarball/dbb9697a8dd09a9ad61ce5e2204400f72d16157a/libdweb.tar.gz": +"libdweb@https://github.com/mozilla/libdweb/tarball/a78b0a0c9a1f1d3d1e3343995de7d4a9b0cb000c/libdweb.tar.gz": version "0.0.0" - resolved "https://github.com/mozilla/libdweb/tarball/dbb9697a8dd09a9ad61ce5e2204400f72d16157a/libdweb.tar.gz#2fcae1f1029940a05c35a8c3ec4293c8a4af6005" + resolved "https://github.com/mozilla/libdweb/tarball/a78b0a0c9a1f1d3d1e3343995de7d4a9b0cb000c/libdweb.tar.gz#fe0fdec69e500f8a191d6d75b5fb51d12d025cb2" libp2p-bootstrap@~0.9.3: version "0.9.3" From 39b2d0e1e28f003a2e05f5bc1bf96719c930c33c Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Thu, 11 Oct 2018 10:36:57 +0100 Subject: [PATCH 30/31] fix: workaround for mused module types We mix different module types for now, this restores branch to buildable state. --- .babelrc | 4 +++- add-on/src/lib/ipfs-protocol-libdweb.js | 2 +- package.json | 1 + yarn.lock | 18 +++++++++++++++++- 4 files changed, 22 insertions(+), 3 deletions(-) diff --git a/.babelrc b/.babelrc index 9b0470a12..93ea6bf23 100644 --- a/.babelrc +++ b/.babelrc @@ -1,13 +1,15 @@ { "plugins": [ + "transform-es2015-modules-commonjs", "syntax-async-generators" ], "presets": [ [ "@babel/preset-env", { + "debug": true, "targets": { - "firefox": 61, + "firefox": 63, "chrome": 67 } } diff --git a/add-on/src/lib/ipfs-protocol-libdweb.js b/add-on/src/lib/ipfs-protocol-libdweb.js index 90e6b2c67..e32305cd4 100644 --- a/add-on/src/lib/ipfs-protocol-libdweb.js +++ b/add-on/src/lib/ipfs-protocol-libdweb.js @@ -90,7 +90,7 @@ function immutableIpfsPath (url, dnslinkResolver) { // js-ipfs does not implement ipfs.name.resolve yet, so we only do dnslink lookup // const response = await ipfs.name.resolve(path, {recursive: true, nocache: false}) const fqdn = path.split('/')[2] - const dnslinkRecord = dnslinkResolver.cachedDnslinkLookup(fqdn) + const dnslinkRecord = dnslinkResolver.readAndCacheDnslink(fqdn) if (!dnslinkRecord) { throw new Error(`Missing DNS TXT with dnslink for '${fqdn}'`) } diff --git a/package.json b/package.json index 9fba10a99..76d1d3afb 100644 --- a/package.json +++ b/package.json @@ -73,6 +73,7 @@ "babel-eslint": "9.0.0", "babel-loader": "8.0.0", "babel-plugin-syntax-async-generators": "6.13.0", + "babel-plugin-transform-es2015-modules-commonjs": "6.26.2", "chai": "4.1.2", "cross-env": "5.2.0", "fakefile": "0.0.9", diff --git a/yarn.lock b/yarn.lock index 400401fbf..e90596176 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1451,6 +1451,22 @@ babel-plugin-syntax-async-generators@6.13.0: version "6.13.0" resolved "https://registry.yarnpkg.com/babel-plugin-syntax-async-generators/-/babel-plugin-syntax-async-generators-6.13.0.tgz#6bc963ebb16eccbae6b92b596eb7f35c342a8b9a" +babel-plugin-transform-es2015-modules-commonjs@6.26.2: + version "6.26.2" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-commonjs/-/babel-plugin-transform-es2015-modules-commonjs-6.26.2.tgz#58a793863a9e7ca870bdc5a881117ffac27db6f3" + dependencies: + babel-plugin-transform-strict-mode "^6.24.1" + babel-runtime "^6.26.0" + babel-template "^6.26.0" + babel-types "^6.26.0" + +babel-plugin-transform-strict-mode@^6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-strict-mode/-/babel-plugin-transform-strict-mode-6.24.1.tgz#d5faf7aa578a65bbe591cf5edae04a0c67020758" + dependencies: + babel-runtime "^6.22.0" + babel-types "^6.24.1" + babel-polyfill@6.16.0: version "6.16.0" resolved "https://registry.yarnpkg.com/babel-polyfill/-/babel-polyfill-6.16.0.tgz#2d45021df87e26a374b6d4d1a9c65964d17f2422" @@ -1510,7 +1526,7 @@ babel-traverse@^6.26.0: invariant "^2.2.2" lodash "^4.17.4" -babel-types@^6.26.0: +babel-types@^6.24.1, babel-types@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-types/-/babel-types-6.26.0.tgz#a3b073f94ab49eb6fa55cd65227a334380632497" dependencies: From d6dfc0cfa74a793695f32888c65845ea46f03444 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Tue, 16 Oct 2018 15:46:53 +0200 Subject: [PATCH 31/31] chore: switch to ipfs-http-response v0.2.0 --- package.json | 2 +- yarn.lock | 17 +++++++++-------- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/package.json b/package.json index dfc4014d1..06dac57e7 100644 --- a/package.json +++ b/package.json @@ -124,7 +124,7 @@ "ipfs": "0.31.7", "ipfs-api": "24.0.2", "ipfs-css": "0.11.0", - "ipfs-http-response": "https://github.com/lidel/js-ipfs-http-response/tarball/475aead595fbbd77cfa4a248fc27474e8d604cb1/js-ipfs-http-response.tar.gz", + "ipfs-http-response": "0.2.0", "ipfs-postmsg-proxy": "3.1.1", "is-ipfs": "0.4.7", "is-stream": "1.1.0", diff --git a/yarn.lock b/yarn.lock index ce18f69f8..7aff83d5a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6199,19 +6199,20 @@ ipfs-css@0.11.0: resolved "https://registry.yarnpkg.com/ipfs-css/-/ipfs-css-0.11.0.tgz#5a54e52cff80346d499b2067077291e9f644d275" integrity sha512-9WHATIPct06Y6n8QvC0gR40M8BHaeChmJXcMYPfMNWZiL480apc303Pg+T1o0q1p+2i69jRYUh7etw1MHO7wOw== -"ipfs-http-response@https://github.com/lidel/js-ipfs-http-response/tarball/475aead595fbbd77cfa4a248fc27474e8d604cb1/js-ipfs-http-response.tar.gz": - version "0.1.4" - resolved "https://github.com/lidel/js-ipfs-http-response/tarball/475aead595fbbd77cfa4a248fc27474e8d604cb1/js-ipfs-http-response.tar.gz#6ef6ffc602e3c6b21ac6e142d55b74bca1487d2b" +ipfs-http-response@0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/ipfs-http-response/-/ipfs-http-response-0.2.0.tgz#2afeea7cfebbe07593c9ea02c25d26ae8219f4e8" + integrity sha512-E4atwGKflYNzynrJQ6VYguREiPWgQDmgXOwEsGOM8EdHHQWOkWsPNl6CGnlHGC2ESj0iUJx1CYMmXNmNzzOlGQ== dependencies: async "^2.6.0" - cids "^0.5.3" + cids "~0.5.5" debug "^3.1.0" file-type "^8.0.0" filesize "^3.6.1" get-stream "^3.0.0" - ipfs-unixfs "^0.1.14" - mime-types "^2.1.19" - multihashes "^0.4.13" + ipfs-unixfs "~0.1.14" + mime-types "^2.1.18" + multihashes "~0.4.13" promisify-es6 "^1.0.3" stream-to-blob "^1.0.1" @@ -6371,7 +6372,7 @@ ipfs-unixfs-engine@~0.32.1: optionalDependencies: rabin "^1.6.0" -ipfs-unixfs@^0.1.14, ipfs-unixfs@~0.1.15: +ipfs-unixfs@^0.1.14, ipfs-unixfs@~0.1.14, ipfs-unixfs@~0.1.15: version "0.1.15" resolved "https://registry.yarnpkg.com/ipfs-unixfs/-/ipfs-unixfs-0.1.15.tgz#c204da10019daa048eea465ce8f9c6f350ecef00" integrity sha512-fjtwBDsIlNags4btHIdAJtE02K4KqEMOhV9GEFVv1M2JO2STS23v2LAtX5qb1EOU5VrjtKlm/JIBH3XDRdAyGQ==