From 5c128a4aacfd82b47e1fce2b87d10d50e4979264 Mon Sep 17 00:00:00 2001 From: Alex Towle Date: Sun, 4 Aug 2019 22:37:32 -0700 Subject: [PATCH 1/3] Update glabal-hooks so that sol-coverage and sol-profiler works again --- contracts/asset-proxy/test/global_hooks.ts | 18 +++++++--- contracts/coordinator/test/global_hooks.ts | 18 +++++++--- contracts/dev-utils/test/global_hooks.ts | 18 +++++++--- contracts/erc1155/test/global_hooks.ts | 18 +++++++--- contracts/erc20/test/global_hooks.ts | 18 +++++++--- contracts/erc721/test/global_hooks.ts | 18 +++++++--- .../exchange-forwarder/test/global_hooks.ts | 18 +++++++--- contracts/exchange-libs/test/global_hooks.ts | 18 +++++++--- contracts/exchange/test/global_hooks.ts | 18 +++++++--- contracts/extensions/test/global_hooks.ts | 18 +++++++--- contracts/multisig/test/global_hooks.ts | 16 +++++++-- contracts/staking/test/global_hooks.ts | 18 +++++++--- contracts/utils/test/global_hooks.ts | 18 +++++++--- yarn.lock | 33 ++----------------- 14 files changed, 183 insertions(+), 82 deletions(-) diff --git a/contracts/asset-proxy/test/global_hooks.ts b/contracts/asset-proxy/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/asset-proxy/test/global_hooks.ts +++ b/contracts/asset-proxy/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/coordinator/test/global_hooks.ts b/contracts/coordinator/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/coordinator/test/global_hooks.ts +++ b/contracts/coordinator/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/dev-utils/test/global_hooks.ts b/contracts/dev-utils/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/dev-utils/test/global_hooks.ts +++ b/contracts/dev-utils/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/erc1155/test/global_hooks.ts b/contracts/erc1155/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/erc1155/test/global_hooks.ts +++ b/contracts/erc1155/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/erc20/test/global_hooks.ts b/contracts/erc20/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/erc20/test/global_hooks.ts +++ b/contracts/erc20/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/erc721/test/global_hooks.ts b/contracts/erc721/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/erc721/test/global_hooks.ts +++ b/contracts/erc721/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/exchange-forwarder/test/global_hooks.ts b/contracts/exchange-forwarder/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/exchange-forwarder/test/global_hooks.ts +++ b/contracts/exchange-forwarder/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/exchange-libs/test/global_hooks.ts b/contracts/exchange-libs/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/exchange-libs/test/global_hooks.ts +++ b/contracts/exchange-libs/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/exchange/test/global_hooks.ts b/contracts/exchange/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/exchange/test/global_hooks.ts +++ b/contracts/exchange/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/extensions/test/global_hooks.ts b/contracts/extensions/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/extensions/test/global_hooks.ts +++ b/contracts/extensions/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/multisig/test/global_hooks.ts b/contracts/multisig/test/global_hooks.ts index 12b942e07a..91d8693e15 100644 --- a/contracts/multisig/test/global_hooks.ts +++ b/contracts/multisig/test/global_hooks.ts @@ -1,18 +1,28 @@ import { coverage, profiler, provider } from '@0x/contracts-test-utils'; import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); - after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/staking/test/global_hooks.ts b/contracts/staking/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/staking/test/global_hooks.ts +++ b/contracts/staking/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/contracts/utils/test/global_hooks.ts b/contracts/utils/test/global_hooks.ts index 2ca47d433b..91d8693e15 100644 --- a/contracts/utils/test/global_hooks.ts +++ b/contracts/utils/test/global_hooks.ts @@ -1,18 +1,28 @@ -import { env, EnvVars } from '@0x/dev-utils'; - import { coverage, profiler, provider } from '@0x/contracts-test-utils'; +import { env, EnvVars } from '@0x/dev-utils'; +import { prependSubprovider } from '@0x/subproviders'; import { providerUtils } from '@0x/utils'; +const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); +const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + +if (env.parseBoolean(EnvVars.SolidityCoverage)) { + prependSubprovider(provider, coverageSubprovider); + provider.stop(); +} +if (env.parseBoolean(EnvVars.SolidityProfiler)) { + prependSubprovider(provider, profilerSubprovider); + provider.stop(); +} + before('start web3 provider', () => { providerUtils.startProviderEngine(provider); }); after('generate coverage report', async () => { if (env.parseBoolean(EnvVars.SolidityCoverage)) { - const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); await coverageSubprovider.writeCoverageAsync(); } if (env.parseBoolean(EnvVars.SolidityProfiler)) { - const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); await profilerSubprovider.writeProfilerOutputAsync(); } provider.stop(); diff --git a/yarn.lock b/yarn.lock index 69342ef56c..bc11be3614 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8653,7 +8653,8 @@ got@^6.7.1: graceful-fs@4.1.15, graceful-fs@^3.0.0, graceful-fs@^4.0.0, graceful-fs@^4.1.10, graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9, graceful-fs@^4.2.0, graceful-fs@~1.2.0: version "4.1.15" - resolved "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00" + integrity sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA== "graceful-readlink@>= 1.0.0": version "1.0.1" @@ -14531,16 +14532,6 @@ react-dom@^16.3.2: object-assign "^4.1.1" prop-types "^15.6.0" -react-dom@^16.4.2: - version "16.8.6" - resolved "https://registry.npmjs.org/react-dom/-/react-dom-16.8.6.tgz#71d6303f631e8b0097f56165ef608f051ff6e10f" - integrity sha512-1nL7PIq9LTL3fthPqwkvr2zY7phIPjYrT0jp4HjyEQrEROnw4dG41VVwi/wfoCneoleqrNX7iAD+pXebJZwrwA== - dependencies: - loose-envify "^1.1.0" - object-assign "^4.1.1" - prop-types "^15.6.2" - scheduler "^0.13.6" - react-dom@^16.5.2: version "16.5.2" resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-16.5.2.tgz#b69ee47aa20bab5327b2b9d7c1fe2a30f2cfa9d7" @@ -14598,8 +14589,6 @@ react-highlight@0xproject/react-highlight#react-peer-deps: dependencies: highlight.js "^9.11.0" highlightjs-solidity "^1.0.5" - react "^16.4.2" - react-dom "^16.4.2" react-hot-loader@^4.3.3: version "4.3.4" @@ -14844,16 +14833,6 @@ react@^16.3.2: object-assign "^4.1.1" prop-types "^15.6.0" -react@^16.4.2: - version "16.8.6" - resolved "https://registry.npmjs.org/react/-/react-16.8.6.tgz#ad6c3a9614fd3a4e9ef51117f54d888da01f2bbe" - integrity sha512-pC0uMkhLaHm11ZSJULfOBqV4tIZkx87ZLvbbQYunNixAAvjnC+snJCg0XQXn9VIsttVsbZP/H/ewzgsd5fxKXw== - dependencies: - loose-envify "^1.1.0" - object-assign "^4.1.1" - prop-types "^15.6.2" - scheduler "^0.13.6" - react@^16.5.2: version "16.5.2" resolved "https://registry.yarnpkg.com/react/-/react-16.5.2.tgz#19f6b444ed139baa45609eee6dc3d318b3895d42" @@ -15751,14 +15730,6 @@ schedule@^0.5.0: dependencies: object-assign "^4.1.1" -scheduler@^0.13.6: - version "0.13.6" - resolved "https://registry.npmjs.org/scheduler/-/scheduler-0.13.6.tgz#466a4ec332467b31a91b9bf74e5347072e4cd889" - integrity sha512-IWnObHt413ucAYKsD9J1QShUKkbKLQQHdxRyw73sw4FN26iWr3DY/H34xGPe4nmL1DwXyWmSWmMrA9TfQbE/XQ== - dependencies: - loose-envify "^1.1.0" - object-assign "^4.1.1" - schema-utils@^0.4.4: version "0.4.7" resolved "https://registry.npmjs.org/schema-utils/-/schema-utils-0.4.7.tgz#ba74f597d2be2ea880131746ee17d0a093c68187" From c51cd1cb8648ce940f589fc8465d5dd14575a985 Mon Sep 17 00:00:00 2001 From: Alex Towle Date: Tue, 6 Aug 2019 09:45:51 -0700 Subject: [PATCH 2/3] `@0x:contracts-exchange` Updated to include all dependencies introduced in tests so that sol-coverage can run --- contracts/exchange/compiler.json | 10 + .../contracts/test/DummyERC20Token.sol | 77 ++++ .../contracts/test/DummyERC721Token.sol | 63 ++++ .../test/DummyNoReturnERC20Token.sol | 115 ++++++ .../contracts/test/ERC1155Mintable.sol | 199 +++++++++++ .../exchange/contracts/test/ERC1155Proxy.sol | 97 +++++ .../exchange/contracts/test/ERC20Proxy.sol | 184 ++++++++++ .../exchange/contracts/test/ERC721Proxy.sol | 171 +++++++++ .../contracts/test/MultiAssetProxy.sol | 335 ++++++++++++++++++ .../contracts/test/StaticCallProxy.sol | 83 +++++ .../contracts/test/TestStaticCallTarget.sol | 82 +++++ contracts/exchange/package.json | 3 +- 12 files changed, 1418 insertions(+), 1 deletion(-) create mode 100644 contracts/exchange/contracts/test/DummyERC20Token.sol create mode 100644 contracts/exchange/contracts/test/DummyERC721Token.sol create mode 100644 contracts/exchange/contracts/test/DummyNoReturnERC20Token.sol create mode 100644 contracts/exchange/contracts/test/ERC1155Mintable.sol create mode 100644 contracts/exchange/contracts/test/ERC1155Proxy.sol create mode 100644 contracts/exchange/contracts/test/ERC20Proxy.sol create mode 100644 contracts/exchange/contracts/test/ERC721Proxy.sol create mode 100644 contracts/exchange/contracts/test/MultiAssetProxy.sol create mode 100644 contracts/exchange/contracts/test/StaticCallProxy.sol create mode 100644 contracts/exchange/contracts/test/TestStaticCallTarget.sol diff --git a/contracts/exchange/compiler.json b/contracts/exchange/compiler.json index 167f1f515a..91846317d8 100644 --- a/contracts/exchange/compiler.json +++ b/contracts/exchange/compiler.json @@ -36,12 +36,22 @@ "src/interfaces/ITransactions.sol", "src/interfaces/IWallet.sol", "src/interfaces/IWrapperFunctions.sol", + "test/DummyERC20Token.sol", + "test/DummyNoReturnERC20Token.sol", + "test/DummyERC721Token.sol", + "test/ERC20Proxy.sol", + "test/ERC721Proxy.sol", + "test/ERC1155Proxy.sol", + "test/ERC1155Mintable.sol", + "test/MultiAssetProxy.sol", + "test/StaticCallProxy.sol", "test/ReentrantERC20Token.sol", "test/TestAssetProxyDispatcher.sol", "test/TestExchangeInternals.sol", "test/TestExchangeMath.sol", "test/TestLibExchangeRichErrorDecoder.sol", "test/TestSignatureValidator.sol", + "test/TestStaticCallTarget.sol", "test/TestValidatorWallet.sol" ] } diff --git a/contracts/exchange/contracts/test/DummyERC20Token.sol b/contracts/exchange/contracts/test/DummyERC20Token.sol new file mode 100644 index 0000000000..a77f6dd351 --- /dev/null +++ b/contracts/exchange/contracts/test/DummyERC20Token.sol @@ -0,0 +1,77 @@ +/* + + Copyright 2019 ZeroEx Intl. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +pragma solidity ^0.5.5; + +import "@0x/contracts-utils/contracts/src/Ownable.sol"; +import "@0x/contracts-erc20/contracts/src/MintableERC20Token.sol"; + + +contract DummyERC20Token is + Ownable, + MintableERC20Token +{ + string public name; + string public symbol; + uint256 public decimals; + uint256 public constant MAX_MINT_AMOUNT = 10000000000000000000000; + + constructor ( + string memory _name, + string memory _symbol, + uint256 _decimals, + uint256 _totalSupply + ) + public + { + name = _name; + symbol = _symbol; + decimals = _decimals; + _totalSupply = _totalSupply; + balances[msg.sender] = _totalSupply; + } + + /// @dev Sets the balance of target address + /// @param _target Address or which balance will be updated + /// @param _value New balance of target address + function setBalance(address _target, uint256 _value) + external + onlyOwner + { + uint256 currBalance = balances[_target]; + if (_value < currBalance) { + _totalSupply = _safeSub(_totalSupply, _safeSub(currBalance, _value)); + } else { + _totalSupply = _safeAdd(_totalSupply, _safeSub(_value, currBalance)); + } + balances[_target] = _value; + } + + /// @dev Mints new tokens for sender + /// @param _value Amount of tokens to mint + function mint(uint256 _value) + external + { + require( + _value <= MAX_MINT_AMOUNT, + "VALUE_TOO_LARGE" + ); + + _mint(msg.sender, _value); + } +} diff --git a/contracts/exchange/contracts/test/DummyERC721Token.sol b/contracts/exchange/contracts/test/DummyERC721Token.sol new file mode 100644 index 0000000000..d7432594a4 --- /dev/null +++ b/contracts/exchange/contracts/test/DummyERC721Token.sol @@ -0,0 +1,63 @@ +/* + + Copyright 2019 ZeroEx Intl. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +pragma solidity ^0.5.5; + +import "@0x/contracts-utils/contracts/src/Ownable.sol"; +import "@0x/contracts-erc721/contracts/src/MintableERC721Token.sol"; + + +// solhint-disable no-empty-blocks +contract DummyERC721Token is + Ownable, + MintableERC721Token +{ + string public name; + string public symbol; + + constructor ( + string memory _name, + string memory _symbol + ) + public + { + name = _name; + symbol = _symbol; + } + + /// @dev Function to mint a new token + /// Reverts if the given token ID already exists + /// @param _to Address of the beneficiary that will own the minted token + /// @param _tokenId ID of the token to be minted by the msg.sender + function mint(address _to, uint256 _tokenId) + external + { + _mint(_to, _tokenId); + } + + /// @dev Function to burn a token + /// Reverts if the given token ID doesn't exist or not called by contract owner + /// @param _owner Owner of token with given token ID + /// @param _tokenId ID of the token to be burned by the msg.sender + function burn(address _owner, uint256 _tokenId) + external + onlyOwner + { + _burn(_owner, _tokenId); + } +} diff --git a/contracts/exchange/contracts/test/DummyNoReturnERC20Token.sol b/contracts/exchange/contracts/test/DummyNoReturnERC20Token.sol new file mode 100644 index 0000000000..ff13815ca2 --- /dev/null +++ b/contracts/exchange/contracts/test/DummyNoReturnERC20Token.sol @@ -0,0 +1,115 @@ +/* + + Copyright 2018 ZeroEx Intl. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +pragma solidity ^0.5.5; + +import "./DummyERC20Token.sol"; + + +// solhint-disable no-empty-blocks +contract DummyNoReturnERC20Token is + DummyERC20Token +{ + constructor ( + string memory _name, + string memory _symbol, + uint256 _decimals, + uint256 _totalSupply + ) + public + DummyERC20Token( + _name, + _symbol, + _decimals, + _totalSupply + ) + {} + + /// @dev send `value` token to `to` from `msg.sender` + /// @param _to The address of the recipient + /// @param _value The amount of token to be transferred + function transfer(address _to, uint256 _value) + external + returns (bool) + { + require( + balances[msg.sender] >= _value, + "ERC20_INSUFFICIENT_BALANCE" + ); + require( + balances[_to] + _value >= balances[_to], + "UINT256_OVERFLOW" + ); + + balances[msg.sender] -= _value; + balances[_to] += _value; + + emit Transfer( + msg.sender, + _to, + _value + ); + + // HACK: This contract will not compile if we remove `returns (bool)`, so we manually return no data + assembly { + return(0, 0) + } + } + + /// @dev send `value` token to `to` from `from` on the condition it is approved by `from` + /// @param _from The address of the sender + /// @param _to The address of the recipient + /// @param _value The amount of token to be transferred + function transferFrom( + address _from, + address _to, + uint256 _value + ) + external + returns (bool) + { + require( + balances[_from] >= _value, + "ERC20_INSUFFICIENT_BALANCE" + ); + require( + allowed[_from][msg.sender] >= _value, + "ERC20_INSUFFICIENT_ALLOWANCE" + ); + require( + balances[_to] + _value >= balances[_to], + "UINT256_OVERFLOW" + ); + + balances[_to] += _value; + balances[_from] -= _value; + allowed[_from][msg.sender] -= _value; + + emit Transfer( + _from, + _to, + _value + ); + + // HACK: This contract will not compile if we remove `returns (bool)`, so we manually return no data + assembly { + return(0, 0) + } + } +} + diff --git a/contracts/exchange/contracts/test/ERC1155Mintable.sol b/contracts/exchange/contracts/test/ERC1155Mintable.sol new file mode 100644 index 0000000000..da1f356ae4 --- /dev/null +++ b/contracts/exchange/contracts/test/ERC1155Mintable.sol @@ -0,0 +1,199 @@ +pragma solidity ^0.5.9; + +import "@0x/contracts-utils/contracts/src/SafeMath.sol"; +import "@0x/contracts-erc1155/contracts/src/ERC1155.sol"; +import "@0x/contracts-erc1155/contracts/src/interfaces/IERC1155Mintable.sol"; + + +/// @dev Mintable form of ERC1155 +/// Shows how easy it is to mint new items +contract ERC1155Mintable is + IERC1155Mintable, + ERC1155 +{ + + /// token nonce + uint256 internal nonce; + + /// mapping from token to creator + mapping (uint256 => address) public creators; + + /// mapping from token to max index + mapping (uint256 => uint256) public maxIndex; + + /// asserts token is owned by msg.sender + modifier creatorOnly(uint256 _id) { + require(creators[_id] == msg.sender); + _; + } + + /// @dev creates a new token + /// @param uri URI of token + /// @param isNF is non-fungible token + /// @return type_ of token (a unique identifier) + function create( + string calldata uri, + bool isNF + ) + external + returns (uint256 type_) + { + // Store the type in the upper 128 bits + type_ = (++nonce << 128); + + // Set a flag if this is an NFI. + if (isNF) { + type_ = type_ | TYPE_NF_BIT; + } + + // This will allow restricted access to creators. + creators[type_] = msg.sender; + + // emit a Transfer event with Create semantic to help with discovery. + emit TransferSingle( + msg.sender, + address(0x0), + address(0x0), + type_, + 0 + ); + + if (bytes(uri).length > 0) { + emit URI(uri, type_); + } + } + + /// @dev creates a new token + /// @param type_ of token + /// @param uri URI of token + function createWithType( + uint256 type_, + string calldata uri + ) + external + { + // This will allow restricted access to creators. + creators[type_] = msg.sender; + + // emit a Transfer event with Create semantic to help with discovery. + emit TransferSingle( + msg.sender, + address(0x0), + address(0x0), + type_, + 0 + ); + + if (bytes(uri).length > 0) { + emit URI(uri, type_); + } + } + + /// @dev mints fungible tokens + /// @param id token type + /// @param to beneficiaries of minted tokens + /// @param quantities amounts of minted tokens + function mintFungible( + uint256 id, + address[] calldata to, + uint256[] calldata quantities + ) + external + creatorOnly(id) + { + // sanity checks + require( + isFungible(id), + "TRIED_TO_MINT_FUNGIBLE_FOR_NON_FUNGIBLE_TOKEN" + ); + + // mint tokens + for (uint256 i = 0; i < to.length; ++i) { + // cache to reduce number of loads + address dst = to[i]; + uint256 quantity = quantities[i]; + + // Grant the items to the caller + balances[id][dst] = _safeAdd(quantity, balances[id][dst]); + + // Emit the Transfer/Mint event. + // the 0x0 source address implies a mint + // It will also provide the circulating supply info. + emit TransferSingle( + msg.sender, + address(0x0), + dst, + id, + quantity + ); + + // if `to` is a contract then trigger its callback + if (dst.isContract()) { + bytes4 callbackReturnValue = IERC1155Receiver(dst).onERC1155Received( + msg.sender, + msg.sender, + id, + quantity, + "" + ); + require( + callbackReturnValue == ERC1155_RECEIVED, + "BAD_RECEIVER_RETURN_VALUE" + ); + } + } + } + + /// @dev mints a non-fungible token + /// @param type_ token type + /// @param to beneficiaries of minted tokens + function mintNonFungible( + uint256 type_, + address[] calldata to + ) + external + creatorOnly(type_) + { + // No need to check this is a nf type rather than an id since + // creatorOnly() will only let a type pass through. + require( + isNonFungible(type_), + "TRIED_TO_MINT_NON_FUNGIBLE_FOR_FUNGIBLE_TOKEN" + ); + + // Index are 1-based. + uint256 index = maxIndex[type_] + 1; + + for (uint256 i = 0; i < to.length; ++i) { + // cache to reduce number of loads + address dst = to[i]; + uint256 id = type_ | index + i; + + nfOwners[id] = dst; + + // You could use base-type id to store NF type balances if you wish. + // balances[_type][dst] = quantity._safeAdd(balances[_type][dst]); + + emit TransferSingle(msg.sender, address(0x0), dst, id, 1); + + // if `to` is a contract then trigger its callback + if (dst.isContract()) { + bytes4 callbackReturnValue = IERC1155Receiver(dst).onERC1155Received( + msg.sender, + msg.sender, + id, + 1, + "" + ); + require( + callbackReturnValue == ERC1155_RECEIVED, + "BAD_RECEIVER_RETURN_VALUE" + ); + } + } + + // record the `maxIndex` of this nft type + // this allows us to mint more nft's of this type in a subsequent call. + maxIndex[type_] = _safeAdd(to.length, maxIndex[type_]); + } +} diff --git a/contracts/exchange/contracts/test/ERC1155Proxy.sol b/contracts/exchange/contracts/test/ERC1155Proxy.sol new file mode 100644 index 0000000000..af3d9e3b4b --- /dev/null +++ b/contracts/exchange/contracts/test/ERC1155Proxy.sol @@ -0,0 +1,97 @@ +/* + + Copyright 2018 ZeroEx Intl. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +pragma solidity ^0.5.9; + +import "@0x/contracts-utils/contracts/src/LibBytes.sol"; +import "@0x/contracts-utils/contracts/src/SafeMath.sol"; +import "@0x/contracts-erc1155/contracts/src/interfaces/IERC1155.sol"; +import "@0x/contracts-asset-proxy/contracts/src/MixinAuthorizable.sol"; +import "@0x/contracts-asset-proxy/contracts/src/interfaces/IAssetProxy.sol"; + + +contract ERC1155Proxy is + MixinAuthorizable, + SafeMath, + IAssetProxy +{ + using LibBytes for bytes; + + // Id of this proxy. + bytes4 constant internal PROXY_ID = bytes4(keccak256("ERC1155Assets(address,uint256[],uint256[],bytes)")); + + /// @dev Transfers batch of ERC1155 assets. Either succeeds or throws. + /// @param assetData Byte array encoded with ERC1155 token address, array of ids, array of values, and callback data. + /// @param from Address to transfer assets from. + /// @param to Address to transfer assets to. + /// @param amount Amount that will be multiplied with each element of `assetData.values` to scale the + /// values that will be transferred. + function transferFrom( + bytes calldata assetData, + address from, + address to, + uint256 amount + ) + external + onlyAuthorized + { + // Decode params from `assetData` + // solhint-disable indent + ( + address erc1155TokenAddress, + uint256[] memory ids, + uint256[] memory values, + bytes memory data + ) = abi.decode( + assetData.sliceDestructive(4, assetData.length), + (address, uint256[], uint256[], bytes) + ); + // solhint-enable indent + + // Scale values up by `amount` + uint256 length = values.length; + uint256[] memory scaledValues = new uint256[](length); + for (uint256 i = 0; i != length; i++) { + // We write the scaled values to an unused location in memory in order + // to avoid copying over `ids` or `data`. This is possible if they are + // identical to `values` and the offsets for each are pointing to the + // same location in the ABI encoded calldata. + scaledValues[i] = _safeMul(values[i], amount); + } + + // Execute `safeBatchTransferFrom` call + // Either succeeds or throws + IERC1155(erc1155TokenAddress).safeBatchTransferFrom( + from, + to, + ids, + scaledValues, + data + ); + } + + /// @dev Gets the proxy id associated with the proxy address. + /// @return Proxy id. + function getProxyId() + external + pure + returns (bytes4) + { + return PROXY_ID; + } +} diff --git a/contracts/exchange/contracts/test/ERC20Proxy.sol b/contracts/exchange/contracts/test/ERC20Proxy.sol new file mode 100644 index 0000000000..8fa75b3de0 --- /dev/null +++ b/contracts/exchange/contracts/test/ERC20Proxy.sol @@ -0,0 +1,184 @@ +/* + + Copyright 2018 ZeroEx Intl. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +pragma solidity ^0.5.9; + +import "@0x/contracts-asset-proxy/contracts/src/MixinAuthorizable.sol"; + + +contract ERC20Proxy is + MixinAuthorizable +{ + // Id of this proxy. + bytes4 constant internal PROXY_ID = bytes4(keccak256("ERC20Token(address)")); + + // solhint-disable-next-line payable-fallback + function () + external + { + assembly { + // The first 4 bytes of calldata holds the function selector + let selector := and(calldataload(0), 0xffffffff00000000000000000000000000000000000000000000000000000000) + + // `transferFrom` will be called with the following parameters: + // assetData Encoded byte array. + // from Address to transfer asset from. + // to Address to transfer asset to. + // amount Amount of asset to transfer. + // bytes4(keccak256("transferFrom(bytes,address,address,uint256)")) = 0xa85e59e4 + if eq(selector, 0xa85e59e400000000000000000000000000000000000000000000000000000000) { + + // To lookup a value in a mapping, we load from the storage location keccak256(k, p), + // where k is the key left padded to 32 bytes and p is the storage slot + let start := mload(64) + mstore(start, and(caller, 0xffffffffffffffffffffffffffffffffffffffff)) + mstore(add(start, 32), authorized_slot) + + // Revert if authorized[msg.sender] == false + if iszero(sload(keccak256(start, 64))) { + // Revert with `Error("SENDER_NOT_AUTHORIZED")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000001553454e4445525f4e4f545f415554484f52495a454400000000000000) + mstore(96, 0) + revert(0, 100) + } + + // `transferFrom`. + // The function is marked `external`, so no abi decodeding is done for + // us. Instead, we expect the `calldata` memory to contain the + // following: + // + // | Area | Offset | Length | Contents | + // |----------|--------|---------|-------------------------------------| + // | Header | 0 | 4 | function selector | + // | Params | | 4 * 32 | function parameters: | + // | | 4 | | 1. offset to assetData (*) | + // | | 36 | | 2. from | + // | | 68 | | 3. to | + // | | 100 | | 4. amount | + // | Data | | | assetData: | + // | | 132 | 32 | assetData Length | + // | | 164 | ** | assetData Contents | + // + // (*): offset is computed from start of function parameters, so offset + // by an additional 4 bytes in the calldata. + // + // (**): see table below to compute length of assetData Contents + // + // WARNING: The ABIv2 specification allows additional padding between + // the Params and Data section. This will result in a larger + // offset to assetData. + + // Asset data itself is encoded as follows: + // + // | Area | Offset | Length | Contents | + // |----------|--------|---------|-------------------------------------| + // | Header | 0 | 4 | function selector | + // | Params | | 1 * 32 | function parameters: | + // | | 4 | 12 + 20 | 1. token address | + + // We construct calldata for the `token.transferFrom` ABI. + // The layout of this calldata is in the table below. + // + // | Area | Offset | Length | Contents | + // |----------|--------|---------|-------------------------------------| + // | Header | 0 | 4 | function selector | + // | Params | | 3 * 32 | function parameters: | + // | | 4 | | 1. from | + // | | 36 | | 2. to | + // | | 68 | | 3. amount | + + /////// Read token address from calldata /////// + // * The token address is stored in `assetData`. + // + // * The "offset to assetData" is stored at offset 4 in the calldata (table 1). + // [assetDataOffsetFromParams = calldataload(4)] + // + // * Notes that the "offset to assetData" is relative to the "Params" area of calldata; + // add 4 bytes to account for the length of the "Header" area (table 1). + // [assetDataOffsetFromHeader = assetDataOffsetFromParams + 4] + // + // * The "token address" is offset 32+4=36 bytes into "assetData" (tables 1 & 2). + // [tokenOffset = assetDataOffsetFromHeader + 36 = calldataload(4) + 4 + 36] + let token := calldataload(add(calldataload(4), 40)) + + /////// Setup Header Area /////// + // This area holds the 4-byte `transferFrom` selector. + // Any trailing data in transferFromSelector will be + // overwritten in the next `mstore` call. + mstore(0, 0x23b872dd00000000000000000000000000000000000000000000000000000000) + + /////// Setup Params Area /////// + // We copy the fields `from`, `to` and `amount` in bulk + // from our own calldata to the new calldata. + calldatacopy(4, 36, 96) + + /////// Call `token.transferFrom` using the calldata /////// + let success := call( + gas, // forward all gas + token, // call address of token contract + 0, // don't send any ETH + 0, // pointer to start of input + 100, // length of input + 0, // write output over input + 32 // output size should be 32 bytes + ) + + /////// Check return data. /////// + // If there is no return data, we assume the token incorrectly + // does not return a bool. In this case we expect it to revert + // on failure, which was handled above. + // If the token does return data, we require that it is a single + // nonzero 32 bytes value. + // So the transfer succeeded if the call succeeded and either + // returned nothing, or returned a non-zero 32 byte value. + success := and(success, or( + iszero(returndatasize), + and( + eq(returndatasize, 32), + gt(mload(0), 0) + ) + )) + if success { + return(0, 0) + } + + // Revert with `Error("TRANSFER_FAILED")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000000f5452414e534645525f4641494c454400000000000000000000000000) + mstore(96, 0) + revert(0, 100) + } + + // Revert if undefined function is called + revert(0, 0) + } + } + + /// @dev Gets the proxy id associated with the proxy address. + /// @return Proxy id. + function getProxyId() + external + pure + returns (bytes4) + { + return PROXY_ID; + } +} diff --git a/contracts/exchange/contracts/test/ERC721Proxy.sol b/contracts/exchange/contracts/test/ERC721Proxy.sol new file mode 100644 index 0000000000..4a0225734e --- /dev/null +++ b/contracts/exchange/contracts/test/ERC721Proxy.sol @@ -0,0 +1,171 @@ +/* + + Copyright 2018 ZeroEx Intl. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +pragma solidity ^0.5.9; + +import "@0x/contracts-asset-proxy/contracts/src/MixinAuthorizable.sol"; + + +contract ERC721Proxy is + MixinAuthorizable +{ + // Id of this proxy. + bytes4 constant internal PROXY_ID = bytes4(keccak256("ERC721Token(address,uint256)")); + + // solhint-disable-next-line payable-fallback + function () + external + { + assembly { + // The first 4 bytes of calldata holds the function selector + let selector := and(calldataload(0), 0xffffffff00000000000000000000000000000000000000000000000000000000) + + // `transferFrom` will be called with the following parameters: + // assetData Encoded byte array. + // from Address to transfer asset from. + // to Address to transfer asset to. + // amount Amount of asset to transfer. + // bytes4(keccak256("transferFrom(bytes,address,address,uint256)")) = 0xa85e59e4 + if eq(selector, 0xa85e59e400000000000000000000000000000000000000000000000000000000) { + + // To lookup a value in a mapping, we load from the storage location keccak256(k, p), + // where k is the key left padded to 32 bytes and p is the storage slot + let start := mload(64) + mstore(start, and(caller, 0xffffffffffffffffffffffffffffffffffffffff)) + mstore(add(start, 32), authorized_slot) + + // Revert if authorized[msg.sender] == false + if iszero(sload(keccak256(start, 64))) { + // Revert with `Error("SENDER_NOT_AUTHORIZED")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000001553454e4445525f4e4f545f415554484f52495a454400000000000000) + mstore(96, 0) + revert(0, 100) + } + + // `transferFrom`. + // The function is marked `external`, so no abi decodeding is done for + // us. Instead, we expect the `calldata` memory to contain the + // following: + // + // | Area | Offset | Length | Contents | + // |----------|--------|---------|-------------------------------------| + // | Header | 0 | 4 | function selector | + // | Params | | 4 * 32 | function parameters: | + // | | 4 | | 1. offset to assetData (*) | + // | | 36 | | 2. from | + // | | 68 | | 3. to | + // | | 100 | | 4. amount | + // | Data | | | assetData: | + // | | 132 | 32 | assetData Length | + // | | 164 | ** | assetData Contents | + // + // (*): offset is computed from start of function parameters, so offset + // by an additional 4 bytes in the calldata. + // + // (**): see table below to compute length of assetData Contents + // + // WARNING: The ABIv2 specification allows additional padding between + // the Params and Data section. This will result in a larger + // offset to assetData. + + // Asset data itself is encoded as follows: + // + // | Area | Offset | Length | Contents | + // |----------|--------|---------|-------------------------------------| + // | Header | 0 | 4 | function selector | + // | Params | | 2 * 32 | function parameters: | + // | | 4 | 12 + 20 | 1. token address | + // | | 36 | | 2. tokenId | + + // We construct calldata for the `token.transferFrom` ABI. + // The layout of this calldata is in the table below. + // + // | Area | Offset | Length | Contents | + // |----------|--------|---------|-------------------------------------| + // | Header | 0 | 4 | function selector | + // | Params | | 3 * 32 | function parameters: | + // | | 4 | | 1. from | + // | | 36 | | 2. to | + // | | 68 | | 3. tokenId | + + // There exists only 1 of each token. + // require(amount == 1, "INVALID_AMOUNT") + if sub(calldataload(100), 1) { + // Revert with `Error("INVALID_AMOUNT")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000000e494e56414c49445f414d4f554e540000000000000000000000000000) + mstore(96, 0) + revert(0, 100) + } + + /////// Setup Header Area /////// + // This area holds the 4-byte `transferFrom` selector. + // Any trailing data in transferFromSelector will be + // overwritten in the next `mstore` call. + mstore(0, 0x23b872dd00000000000000000000000000000000000000000000000000000000) + + /////// Setup Params Area /////// + // We copy the fields `from` and `to` in bulk + // from our own calldata to the new calldata. + calldatacopy(4, 36, 64) + + // Copy `tokenId` field from our own calldata to the new calldata. + let assetDataOffset := calldataload(4) + calldatacopy(68, add(assetDataOffset, 72), 32) + + /////// Call `token.transferFrom` using the calldata /////// + let token := calldataload(add(assetDataOffset, 40)) + let success := call( + gas, // forward all gas + token, // call address of token contract + 0, // don't send any ETH + 0, // pointer to start of input + 100, // length of input + 0, // write output to null + 0 // output size is 0 bytes + ) + if success { + return(0, 0) + } + + // Revert with `Error("TRANSFER_FAILED")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000000f5452414e534645525f4641494c454400000000000000000000000000) + mstore(96, 0) + revert(0, 100) + } + + // Revert if undefined function is called + revert(0, 0) + } + } + + /// @dev Gets the proxy id associated with the proxy address. + /// @return Proxy id. + function getProxyId() + external + pure + returns (bytes4) + { + return PROXY_ID; + } +} diff --git a/contracts/exchange/contracts/test/MultiAssetProxy.sol b/contracts/exchange/contracts/test/MultiAssetProxy.sol new file mode 100644 index 0000000000..f2bb89607c --- /dev/null +++ b/contracts/exchange/contracts/test/MultiAssetProxy.sol @@ -0,0 +1,335 @@ +/* + + Copyright 2018 ZeroEx Intl. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +pragma solidity ^0.5.9; + +import "@0x/contracts-asset-proxy/contracts/src/MixinAssetProxyDispatcher.sol"; +import "@0x/contracts-asset-proxy/contracts/src/MixinAuthorizable.sol"; + + +contract MultiAssetProxy is + MixinAssetProxyDispatcher, + MixinAuthorizable +{ + // Id of this proxy. + bytes4 constant internal PROXY_ID = bytes4(keccak256("MultiAsset(uint256[],bytes[])")); + + // solhint-disable-next-line payable-fallback + function () + external + { + // NOTE: The below assembly assumes that clients do some input validation and that the input is properly encoded according to the AbiV2 specification. + // It is technically possible for inputs with very large lengths and offsets to cause overflows. However, this would make the calldata prohibitively + // expensive and we therefore do not check for overflows in these scenarios. + assembly { + // The first 4 bytes of calldata holds the function selector + let selector := and(calldataload(0), 0xffffffff00000000000000000000000000000000000000000000000000000000) + + // `transferFrom` will be called with the following parameters: + // assetData Encoded byte array. + // from Address to transfer asset from. + // to Address to transfer asset to. + // amount Amount of asset to transfer. + // bytes4(keccak256("transferFrom(bytes,address,address,uint256)")) = 0xa85e59e4 + if eq(selector, 0xa85e59e400000000000000000000000000000000000000000000000000000000) { + + // To lookup a value in a mapping, we load from the storage location keccak256(k, p), + // where k is the key left padded to 32 bytes and p is the storage slot + mstore(0, caller) + mstore(32, authorized_slot) + + // Revert if authorized[msg.sender] == false + if iszero(sload(keccak256(0, 64))) { + // Revert with `Error("SENDER_NOT_AUTHORIZED")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000001553454e4445525f4e4f545f415554484f52495a454400000000000000) + mstore(96, 0) + revert(0, 100) + } + + // `transferFrom`. + // The function is marked `external`, so no abi decoding is done for + // us. Instead, we expect the `calldata` memory to contain the + // following: + // + // | Area | Offset | Length | Contents | + // |----------|--------|---------|-------------------------------------| + // | Header | 0 | 4 | function selector | + // | Params | | 4 * 32 | function parameters: | + // | | 4 | | 1. offset to assetData (*) | + // | | 36 | | 2. from | + // | | 68 | | 3. to | + // | | 100 | | 4. amount | + // | Data | | | assetData: | + // | | 132 | 32 | assetData Length | + // | | 164 | ** | assetData Contents | + // + // (*): offset is computed from start of function parameters, so offset + // by an additional 4 bytes in the calldata. + // + // (**): see table below to compute length of assetData Contents + // + // WARNING: The ABIv2 specification allows additional padding between + // the Params and Data section. This will result in a larger + // offset to assetData. + + // Load offset to `assetData` + let assetDataOffset := add(calldataload(4), 4) + + // Load length in bytes of `assetData` + let assetDataLength := calldataload(assetDataOffset) + + // Asset data itself is encoded as follows: + // + // | Area | Offset | Length | Contents | + // |----------|-------------|---------|-------------------------------------| + // | Header | 0 | 4 | assetProxyId | + // | Params | | 2 * 32 | function parameters: | + // | | 4 | | 1. offset to amounts (*) | + // | | 36 | | 2. offset to nestedAssetData (*) | + // | Data | | | amounts: | + // | | 68 | 32 | amounts Length | + // | | 100 | a | amounts Contents | + // | | | | nestedAssetData: | + // | | 100 + a | 32 | nestedAssetData Length | + // | | 132 + a | b | nestedAssetData Contents (offsets) | + // | | 132 + a + b | | nestedAssetData[0, ..., len] | + + // Assert that the length of asset data: + // 1. Must be at least 68 bytes (see table above) + // 2. Must be a multiple of 32 (excluding the 4-byte selector) + if or(lt(assetDataLength, 68), mod(sub(assetDataLength, 4), 32)) { + // Revert with `Error("INVALID_ASSET_DATA_LENGTH")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x00000019494e56414c49445f41535345545f444154415f4c454e475448000000) + mstore(96, 0) + revert(0, 100) + } + + // End of asset data in calldata + // assetDataOffset + // + 32 (assetData len) + let assetDataEnd := add(assetDataOffset, add(assetDataLength, 32)) + if gt(assetDataEnd, calldatasize()) { + // Revert with `Error("INVALID_ASSET_DATA_END")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x00000016494e56414c49445f41535345545f444154415f454e44000000000000) + mstore(96, 0) + revert(0, 100) + } + + // In order to find the offset to `amounts`, we must add: + // assetDataOffset + // + 32 (assetData len) + // + 4 (assetProxyId) + let amountsOffset := calldataload(add(assetDataOffset, 36)) + + // In order to find the offset to `nestedAssetData`, we must add: + // assetDataOffset + // + 32 (assetData len) + // + 4 (assetProxyId) + // + 32 (amounts offset) + let nestedAssetDataOffset := calldataload(add(assetDataOffset, 68)) + + // In order to find the start of the `amounts` contents, we must add: + // assetDataOffset + // + 32 (assetData len) + // + 4 (assetProxyId) + // + amountsOffset + // + 32 (amounts len) + let amountsContentsStart := add(assetDataOffset, add(amountsOffset, 68)) + + // Load number of elements in `amounts` + let amountsLen := calldataload(sub(amountsContentsStart, 32)) + + // In order to find the start of the `nestedAssetData` contents, we must add: + // assetDataOffset + // + 32 (assetData len) + // + 4 (assetProxyId) + // + nestedAssetDataOffset + // + 32 (nestedAssetData len) + let nestedAssetDataContentsStart := add(assetDataOffset, add(nestedAssetDataOffset, 68)) + + // Load number of elements in `nestedAssetData` + let nestedAssetDataLen := calldataload(sub(nestedAssetDataContentsStart, 32)) + + // Revert if number of elements in `amounts` differs from number of elements in `nestedAssetData` + if sub(amountsLen, nestedAssetDataLen) { + // Revert with `Error("LENGTH_MISMATCH")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000000f4c454e4754485f4d49534d4154434800000000000000000000000000) + mstore(96, 0) + revert(0, 100) + } + + // Copy `transferFrom` selector, offset to `assetData`, `from`, and `to` from calldata to memory + calldatacopy( + 0, // memory can safely be overwritten from beginning + 0, // start of calldata + 100 // length of selector (4) and 3 params (32 * 3) + ) + + // Overwrite existing offset to `assetData` with our own + mstore(4, 128) + + // Load `amount` + let amount := calldataload(100) + + // Calculate number of bytes in `amounts` contents + let amountsByteLen := mul(amountsLen, 32) + + // Initialize `assetProxyId` and `assetProxy` to 0 + let assetProxyId := 0 + let assetProxy := 0 + + // Loop through `amounts` and `nestedAssetData`, calling `transferFrom` for each respective element + for {let i := 0} lt(i, amountsByteLen) {i := add(i, 32)} { + + // Calculate the total amount + let amountsElement := calldataload(add(amountsContentsStart, i)) + let totalAmount := mul(amountsElement, amount) + + // Revert if `amount` != 0 and multiplication resulted in an overflow + if iszero(or( + iszero(amount), + eq(div(totalAmount, amount), amountsElement) + )) { + // Revert with `Error("UINT256_OVERFLOW")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000001055494e543235365f4f564552464c4f57000000000000000000000000) + mstore(96, 0) + revert(0, 100) + } + + // Write `totalAmount` to memory + mstore(100, totalAmount) + + // Load offset to `nestedAssetData[i]` + let nestedAssetDataElementOffset := calldataload(add(nestedAssetDataContentsStart, i)) + + // In order to find the start of the `nestedAssetData[i]` contents, we must add: + // assetDataOffset + // + 32 (assetData len) + // + 4 (assetProxyId) + // + nestedAssetDataOffset + // + 32 (nestedAssetData len) + // + nestedAssetDataElementOffset + // + 32 (nestedAssetDataElement len) + let nestedAssetDataElementContentsStart := add( + assetDataOffset, + add( + nestedAssetDataOffset, + add(nestedAssetDataElementOffset, 100) + ) + ) + + // Load length of `nestedAssetData[i]` + let nestedAssetDataElementLenStart := sub(nestedAssetDataElementContentsStart, 32) + let nestedAssetDataElementLen := calldataload(nestedAssetDataElementLenStart) + + // Revert if the `nestedAssetData` does not contain a 4 byte `assetProxyId` + if lt(nestedAssetDataElementLen, 4) { + // Revert with `Error("LENGTH_GREATER_THAN_3_REQUIRED")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000001e4c454e4754485f475245415445525f5448414e5f335f524551554952) + mstore(96, 0x4544000000000000000000000000000000000000000000000000000000000000) + revert(0, 100) + } + + // Load AssetProxy id + let currentAssetProxyId := and( + calldataload(nestedAssetDataElementContentsStart), + 0xffffffff00000000000000000000000000000000000000000000000000000000 + ) + + // Only load `assetProxy` if `currentAssetProxyId` does not equal `assetProxyId` + // We do not need to check if `currentAssetProxyId` is 0 since `assetProxy` is also initialized to 0 + if sub(currentAssetProxyId, assetProxyId) { + // Update `assetProxyId` + assetProxyId := currentAssetProxyId + // To lookup a value in a mapping, we load from the storage location keccak256(k, p), + // where k is the key left padded to 32 bytes and p is the storage slot + mstore(132, assetProxyId) + mstore(164, assetProxies_slot) + assetProxy := sload(keccak256(132, 64)) + } + + // Revert if AssetProxy with given id does not exist + if iszero(assetProxy) { + // Revert with `Error("ASSET_PROXY_DOES_NOT_EXIST")` + mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) + mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) + mstore(64, 0x0000001a41535345545f50524f58595f444f45535f4e4f545f45584953540000) + mstore(96, 0) + revert(0, 100) + } + + // Copy `nestedAssetData[i]` from calldata to memory + calldatacopy( + 132, // memory slot after `amounts[i]` + nestedAssetDataElementLenStart, // location of `nestedAssetData[i]` in calldata + add(nestedAssetDataElementLen, 32) // `nestedAssetData[i].length` plus 32 byte length + ) + + // call `assetProxy.transferFrom` + let success := call( + gas, // forward all gas + assetProxy, // call address of asset proxy + 0, // don't send any ETH + 0, // pointer to start of input + add(164, nestedAssetDataElementLen), // length of input + 0, // write output over memory that won't be reused + 0 // don't copy output to memory + ) + + // Revert with reason given by AssetProxy if `transferFrom` call failed + if iszero(success) { + returndatacopy( + 0, // copy to memory at 0 + 0, // copy from return data at 0 + returndatasize() // copy all return data + ) + revert(0, returndatasize()) + } + } + + // Return if no `transferFrom` calls reverted + return(0, 0) + } + + // Revert if undefined function is called + revert(0, 0) + } + } + + /// @dev Gets the proxy id associated with the proxy address. + /// @return Proxy id. + function getProxyId() + external + pure + returns (bytes4) + { + return PROXY_ID; + } +} diff --git a/contracts/exchange/contracts/test/StaticCallProxy.sol b/contracts/exchange/contracts/test/StaticCallProxy.sol new file mode 100644 index 0000000000..c8b12faea6 --- /dev/null +++ b/contracts/exchange/contracts/test/StaticCallProxy.sol @@ -0,0 +1,83 @@ +/* + + Copyright 2018 ZeroEx Intl. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +pragma solidity ^0.5.9; + +import "@0x/contracts-utils/contracts/src/LibBytes.sol"; + + +// solhint-disable no-unused-vars +contract StaticCallProxy { + + using LibBytes for bytes; + + // Id of this proxy. + bytes4 constant internal PROXY_ID = bytes4(keccak256("StaticCall(address,bytes,bytes32)")); + + /// @dev Makes a staticcall to a target address and verifies that the data returned matches the expected return data. + /// @param assetData Byte array encoded with staticCallTarget, staticCallData, and expectedCallResultHash + /// @param from This value is ignored. + /// @param to This value is ignored. + /// @param amount This value is ignored. + function transferFrom( + bytes calldata assetData, + address from, + address to, + uint256 amount + ) + external + view + { + // Decode params from `assetData` + ( + address staticCallTarget, + bytes memory staticCallData, + bytes32 expectedReturnDataHash + ) = abi.decode( + assetData.sliceDestructive(4, assetData.length), + (address, bytes, bytes32) + ); + + // Execute staticcall + (bool success, bytes memory returnData) = staticCallTarget.staticcall(staticCallData); + + // Revert with returned data if staticcall is unsuccessful + if (!success) { + assembly { + revert(add(returnData, 32), mload(returnData)) + } + } + + // Revert if hash of return data is not as expected + bytes32 returnDataHash = keccak256(returnData); + require( + expectedReturnDataHash == returnDataHash, + "UNEXPECTED_STATIC_CALL_RESULT" + ); + } + + /// @dev Gets the proxy id associated with the proxy address. + /// @return Proxy id. + function getProxyId() + external + pure + returns (bytes4) + { + return PROXY_ID; + } +} diff --git a/contracts/exchange/contracts/test/TestStaticCallTarget.sol b/contracts/exchange/contracts/test/TestStaticCallTarget.sol new file mode 100644 index 0000000000..28da79c634 --- /dev/null +++ b/contracts/exchange/contracts/test/TestStaticCallTarget.sol @@ -0,0 +1,82 @@ +/* + + Copyright 2018 ZeroEx Intl. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +pragma solidity ^0.5.9; + +import "@0x/contracts-utils/contracts/src/LibBytes.sol"; + + +contract TestStaticCallTarget { + + using LibBytes for bytes; + + uint256 internal _state; + + function updateState() + external + { + _state++; + } + + function assertEvenNumber(uint256 target) + external + pure + { + require( + target % 2 == 0, + "TARGET_NOT_EVEN" + ); + } + + function isOddNumber(uint256 target) + external + pure + returns (bool isOdd) + { + isOdd = target % 2 == 1; + return isOdd; + } + + function noInputFunction() + external + pure + { + assert(msg.data.length == 4 && msg.data.readBytes4(0) == bytes4(keccak256("noInputFunction()"))); + } + + function dynamicInputFunction(bytes calldata a) + external + pure + { + bytes memory abiEncodedData = abi.encodeWithSignature("dynamicInputFunction(bytes)", a); + assert(msg.data.equals(abiEncodedData)); + } + + function returnComplexType(uint256 a, uint256 b) + external + view + returns (bytes memory result) + { + result = abi.encodePacked( + address(this), + a, + b + ); + return result; + } +} \ No newline at end of file diff --git a/contracts/exchange/package.json b/contracts/exchange/package.json index 83dc128500..61f190712e 100644 --- a/contracts/exchange/package.json +++ b/contracts/exchange/package.json @@ -15,10 +15,11 @@ "pre_build": "run-s compile generate_contract_wrappers", "test": "yarn run_mocha", "rebuild_and_test": "run-s build test", - "test:coverage": "SOLIDITY_COVERAGE=true run-s build run_mocha coverage:report:text coverage:report:lcov", + "test:coverage": "SOLIDITY_COVERAGE=true run-s build run_mocha:long coverage:report:text coverage:report:lcov", "test:profiler": "SOLIDITY_PROFILER=true run-s build run_mocha profiler:report:html", "test:trace": "SOLIDITY_REVERT_TRACE=true run-s build run_mocha", "run_mocha": "mocha --require source-map-support/register --require make-promises-safe 'lib/test/**/*.js' --timeout 100000 --bail --exit", + "run_mocha:long": "mocha --require source-map-support/register --require make-promises-safe 'lib/test/**/*.js' --timeout 300000 --bail --exit", "compile": "sol-compiler", "watch": "sol-compiler -w", "clean": "shx rm -rf lib generated-artifacts generated-wrappers", From 7a724c8a6d86c50bd9f8d43cfa0fb32ca05a4ea0 Mon Sep 17 00:00:00 2001 From: Alex Towle Date: Thu, 8 Aug 2019 16:57:20 -0700 Subject: [PATCH 3/3] Updated packages so that they can use @0x/subproviders directly to fix linting issues --- contracts/asset-proxy/package.json | 1 + contracts/coordinator/package.json | 1 + contracts/dev-utils/package.json | 1 + contracts/erc1155/package.json | 1 + contracts/erc20/package.json | 1 + contracts/erc721/package.json | 1 + contracts/exchange-forwarder/package.json | 1 + contracts/exchange-libs/package.json | 1 + contracts/exchange/package.json | 1 + contracts/exchange/test/core.ts | 2 +- contracts/extensions/package.json | 1 + contracts/multisig/package.json | 1 + contracts/staking/package.json | 2 + contracts/utils/package.json | 1 + packages/sol-coverage/package.json | 2 +- packages/sol-tracing-utils/package.json | 2 +- yarn.lock | 821 +++++++++++++++++++++- 17 files changed, 807 insertions(+), 34 deletions(-) diff --git a/contracts/asset-proxy/package.json b/contracts/asset-proxy/package.json index 1c4ed19af1..f248a70387 100644 --- a/contracts/asset-proxy/package.json +++ b/contracts/asset-proxy/package.json @@ -74,6 +74,7 @@ "@0x/contracts-erc721": "^2.1.9", "@0x/contracts-utils": "^3.1.9", "@0x/order-utils": "^8.2.2", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/coordinator/package.json b/contracts/coordinator/package.json index c64bd9c263..278e438189 100644 --- a/contracts/coordinator/package.json +++ b/contracts/coordinator/package.json @@ -75,6 +75,7 @@ "@0x/contracts-exchange-libs": "^3.0.2", "@0x/contracts-utils": "^3.1.9", "@0x/order-utils": "^8.2.2", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/dev-utils/package.json b/contracts/dev-utils/package.json index 5d6d68a906..e392019a12 100644 --- a/contracts/dev-utils/package.json +++ b/contracts/dev-utils/package.json @@ -77,6 +77,7 @@ "@0x/contracts-exchange-libs": "^3.0.2", "@0x/contracts-utils": "^3.1.9", "@0x/order-utils": "^8.2.2", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/erc1155/package.json b/contracts/erc1155/package.json index 5e9d1c9d9d..5abee96b13 100644 --- a/contracts/erc1155/package.json +++ b/contracts/erc1155/package.json @@ -70,6 +70,7 @@ "@0x/base-contract": "^5.1.1", "@0x/contracts-test-utils": "^3.1.10", "@0x/contracts-utils": "^3.1.9", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/erc20/package.json b/contracts/erc20/package.json index 7137b8f95b..f0135ba91a 100644 --- a/contracts/erc20/package.json +++ b/contracts/erc20/package.json @@ -70,6 +70,7 @@ "dependencies": { "@0x/base-contract": "^5.1.1", "@0x/contracts-utils": "^3.1.9", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/erc721/package.json b/contracts/erc721/package.json index 4444ebc1cc..d91aa10bde 100644 --- a/contracts/erc721/package.json +++ b/contracts/erc721/package.json @@ -70,6 +70,7 @@ "dependencies": { "@0x/base-contract": "^5.1.1", "@0x/contracts-utils": "^3.1.9", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/exchange-forwarder/package.json b/contracts/exchange-forwarder/package.json index 230b8b9ea4..ec0ab06e10 100644 --- a/contracts/exchange-forwarder/package.json +++ b/contracts/exchange-forwarder/package.json @@ -75,6 +75,7 @@ "@0x/contracts-exchange-libs": "^3.0.2", "@0x/contracts-utils": "^3.1.9", "@0x/order-utils": "^8.2.2", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/exchange-libs/package.json b/contracts/exchange-libs/package.json index 5e9b69a81f..f602578047 100644 --- a/contracts/exchange-libs/package.json +++ b/contracts/exchange-libs/package.json @@ -73,6 +73,7 @@ "@0x/base-contract": "^5.1.1", "@0x/contracts-utils": "^3.1.9", "@0x/order-utils": "^8.2.2", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/exchange/package.json b/contracts/exchange/package.json index 61f190712e..4fcbff96d9 100644 --- a/contracts/exchange/package.json +++ b/contracts/exchange/package.json @@ -77,6 +77,7 @@ "@0x/contracts-exchange-libs": "^3.0.2", "@0x/contracts-utils": "^3.1.9", "@0x/order-utils": "^8.2.2", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/exchange/test/core.ts b/contracts/exchange/test/core.ts index 2d5069592e..9d36970111 100644 --- a/contracts/exchange/test/core.ts +++ b/contracts/exchange/test/core.ts @@ -57,7 +57,7 @@ const expect = chai.expect; const blockchainLifecycle = new BlockchainLifecycle(web3Wrapper); // tslint:disable:no-unnecessary-type-assertion -describe('Exchange core', () => { +describe.only('Exchange core', () => { let chainId: number; let makerAddress: string; let owner: string; diff --git a/contracts/extensions/package.json b/contracts/extensions/package.json index 72293c9d02..432fcb2ca3 100644 --- a/contracts/extensions/package.json +++ b/contracts/extensions/package.json @@ -77,6 +77,7 @@ "@0x/contracts-exchange-libs": "^3.0.2", "@0x/contracts-utils": "^3.1.9", "@0x/order-utils": "^8.2.2", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/multisig/package.json b/contracts/multisig/package.json index 864618515c..821a2604f7 100644 --- a/contracts/multisig/package.json +++ b/contracts/multisig/package.json @@ -72,6 +72,7 @@ "@0x/contracts-asset-proxy": "^2.2.2", "@0x/contracts-erc20": "^2.2.8", "@0x/contracts-utils": "2.0.1", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/contracts/staking/package.json b/contracts/staking/package.json index 1273b0c1c9..81c130b132 100644 --- a/contracts/staking/package.json +++ b/contracts/staking/package.json @@ -69,7 +69,9 @@ }, "dependencies": { "@0x/base-contract": "^5.0.5", + "@0x/contracts-test-utils": "3.1.10", "@0x/contracts-utils": "^3.1.1", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.2.2", "@0x/typescript-typings": "^4.2.2", "@0x/utils": "^4.3.1", diff --git a/contracts/utils/package.json b/contracts/utils/package.json index 55aa8618ab..de5b086a4d 100644 --- a/contracts/utils/package.json +++ b/contracts/utils/package.json @@ -71,6 +71,7 @@ "dependencies": { "@0x/base-contract": "^5.1.1", "@0x/order-utils": "^8.2.2", + "@0x/subproviders": "^5.0.1", "@0x/types": "^2.4.0", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", diff --git a/packages/sol-coverage/package.json b/packages/sol-coverage/package.json index a664c03082..4411a25eb8 100644 --- a/packages/sol-coverage/package.json +++ b/packages/sol-coverage/package.json @@ -31,7 +31,7 @@ "homepage": "https://github.com/0xProject/0x-monorepo/packages/sol-coverage/README.md", "dependencies": { "@0x/sol-tracing-utils": "^6.0.13", - "@0x/subproviders": "^4.1.1", + "@0x/subproviders": "4.1.1", "@0x/typescript-typings": "^4.2.3", "@types/minimatch": "^3.0.3", "ethereum-types": "^2.1.3", diff --git a/packages/sol-tracing-utils/package.json b/packages/sol-tracing-utils/package.json index 54a500206b..23f64e6dee 100644 --- a/packages/sol-tracing-utils/package.json +++ b/packages/sol-tracing-utils/package.json @@ -46,7 +46,7 @@ "@0x/dev-utils": "^2.2.4", "@0x/sol-compiler": "^3.1.9", "@0x/sol-resolver": "^2.0.8", - "@0x/subproviders": "^4.1.1", + "@0x/subproviders": "4.1.1", "@0x/typescript-typings": "^4.2.3", "@0x/utils": "^4.4.0", "@0x/web3-wrapper": "^6.0.7", diff --git a/yarn.lock b/yarn.lock index bc11be3614..8e04b7447d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -715,6 +715,17 @@ dependencies: "@0x/base-contract" "^5.1.0" +"@0x/assert@^2.1.3": + version "2.1.3" + resolved "https://registry.yarnpkg.com/@0x/assert/-/assert-2.1.3.tgz#ff35336730246140ad9584b0521046bf2962b62a" + integrity sha512-uOA4tQ3LQTPnVUaQrFkbFtGKWhvW51CNwS8DO65xXPszSUmWOc9Pqtrk2Ee10TxfA90ImaXYgWGves9lDI+Nog== + dependencies: + "@0x/json-schemas" "^3.1.13" + "@0x/typescript-typings" "^4.2.4" + "@0x/utils" "^4.5.0" + lodash "^4.17.11" + valid-url "^1.0.9" + "@0x/asset-buyer@6.1.4": version "6.1.4" resolved "https://registry.yarnpkg.com/@0x/asset-buyer/-/asset-buyer-6.1.4.tgz#ea863b860fbae6f633846bdcf23cacbb345aefd1" @@ -820,6 +831,16 @@ typeorm "0.2.7" websocket "^1.0.25" +"@0x/json-schemas@^3.1.13": + version "3.1.13" + resolved "https://registry.yarnpkg.com/@0x/json-schemas/-/json-schemas-3.1.13.tgz#4b9010f1bdeaf2aef1daba1753aa2e5ecf57f654" + integrity sha512-V93sF6seHDHFCSLZOOEhgY5k+w+78tLmxJRhj8XvsW4+EnXcgpshxK38P6SQAmBoNLDutmM8Wk1inf6ghiW0qA== + dependencies: + "@0x/typescript-typings" "^4.2.4" + "@types/node" "*" + jsonschema "^1.2.0" + lodash.values "^4.3.0" + "@0x/order-utils@^5.0.0": version "5.0.0" resolved "https://registry.yarnpkg.com/@0x/order-utils/-/order-utils-5.0.0.tgz#7f43e0310ace31738895881501c8dda9c3a3aefa" @@ -864,6 +885,73 @@ ethers "~4.0.4" lodash "^4.17.11" +"@0x/subproviders@^5.0.1": + version "5.0.1" + resolved "https://registry.yarnpkg.com/@0x/subproviders/-/subproviders-5.0.1.tgz#167e0fddc8da6dc629c741d33dd68e0142f759d4" + integrity sha512-qt3pSbuOev9G0mOjf0DnpGRifFeVdntdFI+BMgO1YhXUdu4DM0t3WlJo6HXlnWmjx/2+Yr00N0lz2G3JACUDsQ== + dependencies: + "@0x/assert" "^2.1.3" + "@0x/types" "^2.4.1" + "@0x/typescript-typings" "^4.2.4" + "@0x/utils" "^4.5.0" + "@0x/web3-wrapper" "^6.0.10" + "@ledgerhq/hw-app-eth" "^4.3.0" + "@ledgerhq/hw-transport-u2f" "4.24.0" + "@types/hdkey" "^0.7.0" + "@types/web3-provider-engine" "^14.0.0" + bip39 "^2.5.0" + bn.js "^4.11.8" + ethereum-types "^2.1.4" + ethereumjs-tx "^1.3.5" + ethereumjs-util "^5.1.1" + ganache-core "^2.6.0" + hdkey "^0.7.1" + json-rpc-error "2.0.0" + lodash "^4.17.11" + semaphore-async-await "^1.5.1" + web3-provider-engine "14.0.6" + optionalDependencies: + "@ledgerhq/hw-transport-node-hid" "^4.3.0" + +"@0x/types@^2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@0x/types/-/types-2.4.1.tgz#41a42185dcd093b19ef0d4595a432b285aae4746" + integrity sha512-gJrpxwoV1c1rSWg94RH1fLdfMCwaSCene8p4ckCgwmOzoLaD9Oj1ImErgjzGhmbPugwn6n5HnjoU7cQzeek4nw== + dependencies: + "@types/node" "*" + bignumber.js "~8.0.2" + ethereum-types "^2.1.4" + +"@0x/typescript-typings@^4.2.4": + version "4.2.4" + resolved "https://registry.yarnpkg.com/@0x/typescript-typings/-/typescript-typings-4.2.4.tgz#0858639ddfdf7e9e1a3f9fd8f7d8f2e8ebfdce85" + integrity sha512-yIg8q/bj9+Y0OzNuq59D3JDe4OoQR3bU2QKy+7d8NV6CIfA0GqfWWS+JFdUB45S45qT5P0EmThh/szQ7zuW4oQ== + dependencies: + "@types/bn.js" "^4.11.0" + "@types/react" "*" + bignumber.js "~8.0.2" + ethereum-types "^2.1.4" + popper.js "1.14.3" + +"@0x/utils@^4.5.0": + version "4.5.0" + resolved "https://registry.yarnpkg.com/@0x/utils/-/utils-4.5.0.tgz#b5780ea76f4553ef458c4dddc970262c5d6cee75" + integrity sha512-tdMpfccExkuuVDznJBJ0m813GocNv0RdyHckmjPQVdpaAlcehY6u9WB2+b8O9Coop5l8p1Y71Z4DeNuFrEqHpQ== + dependencies: + "@0x/types" "^2.4.1" + "@0x/typescript-typings" "^4.2.4" + "@types/node" "*" + abortcontroller-polyfill "^1.1.9" + bignumber.js "~8.0.2" + chalk "^2.3.0" + detect-node "2.0.3" + ethereum-types "^2.1.4" + ethereumjs-util "^5.1.1" + ethers "~4.0.4" + isomorphic-fetch "2.2.1" + js-sha3 "^0.7.0" + lodash "^4.17.11" + "@0x/web3-wrapper@^4.0.1": version "4.0.2" resolved "https://registry.npmjs.org/@0x/web3-wrapper/-/web3-wrapper-4.0.2.tgz#d4e0a4fa1217155e1aed4cd91086654fd99f2959" @@ -890,6 +978,20 @@ ethers "~4.0.4" lodash "^4.17.11" +"@0x/web3-wrapper@^6.0.10": + version "6.0.10" + resolved "https://registry.yarnpkg.com/@0x/web3-wrapper/-/web3-wrapper-6.0.10.tgz#6be653dc2ed7e82e208c1131f4a8ee538991ce7d" + integrity sha512-jPsKVoBNb/IeJOgdhVwtkceYgayA1L/9RCqSzZ5uvqQtdpZho4Xa6SaJIeE+XnBnluicunvc9swILrknNLNKKA== + dependencies: + "@0x/assert" "^2.1.3" + "@0x/json-schemas" "^3.1.13" + "@0x/typescript-typings" "^4.2.4" + "@0x/utils" "^4.5.0" + ethereum-types "^2.1.4" + ethereumjs-util "^5.1.1" + ethers "~4.0.4" + lodash "^4.17.11" + "@0xproject/npm-cli-login@^0.0.11": version "0.0.11" resolved "https://registry.yarnpkg.com/@0xproject/npm-cli-login/-/npm-cli-login-0.0.11.tgz#3f1ec06112ce62aad300ff0575358f68aeecde2e" @@ -2627,6 +2729,13 @@ ansi-align@^2.0.0: dependencies: string-width "^2.0.0" +ansi-colors@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-1.1.0.tgz#6374b4dd5d4718ff3ce27a671a3b1cad077132a9" + integrity sha512-SFKX67auSNoVR38N3L+nvsPjOE0bybKTYbkf5tRvushrAPQ9V75huw0ZxBkKVeRU9kqH3d6HA4xTckbwZ4ixmA== + dependencies: + ansi-wrap "^0.1.0" + ansi-colors@^3.0.0: version "3.1.0" resolved "https://registry.npmjs.org/ansi-colors/-/ansi-colors-3.1.0.tgz#dcfaacc90ef9187de413ec3ef8d5eb981a98808f" @@ -2675,7 +2784,7 @@ ansi-styles@^3.2.0, ansi-styles@^3.2.1: dependencies: color-convert "^1.9.0" -ansi-wrap@0.1.0: +ansi-wrap@0.1.0, ansi-wrap@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" @@ -2760,10 +2869,24 @@ arr-diff@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" +arr-filter@^1.1.1: + version "1.1.2" + resolved "https://registry.yarnpkg.com/arr-filter/-/arr-filter-1.1.2.tgz#43fdddd091e8ef11aa4c45d9cdc18e2dff1711ee" + integrity sha1-Q/3d0JHo7xGqTEXZzcGOLf8XEe4= + dependencies: + make-iterator "^1.0.0" + arr-flatten@^1.0.1, arr-flatten@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/arr-flatten/-/arr-flatten-1.1.0.tgz#36048bbff4e7b47e136644316c99669ea5ae91f1" +arr-map@^2.0.0, arr-map@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/arr-map/-/arr-map-2.0.2.tgz#3a77345ffc1cf35e2a91825601f9e58f2e24cac4" + integrity sha1-Onc0X/wc814qkYJWAfnljy4kysQ= + dependencies: + make-iterator "^1.0.0" + arr-union@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" @@ -2777,7 +2900,7 @@ array-differ@^2.0.3: resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-2.1.0.tgz#4b9c1c3f14b906757082925769e8ab904f4801b1" integrity sha512-KbUpJgx909ZscOc/7CLATBFam7P1Z1QRQInvgT0UztM9Q72aGKCunKASAl7WNW0tnPmPyEMeMhdsfWhfmW037w== -array-each@^1.0.1: +array-each@^1.0.0, array-each@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/array-each/-/array-each-1.0.1.tgz#a794af0c05ab1752846ee753a1f211a05ba0c44f" @@ -2805,6 +2928,21 @@ array-ify@^1.0.0: version "1.0.0" resolved "http://registry.yarnpkg.com/array-ify/-/array-ify-1.0.0.tgz#9e528762b4a9066ad163a6962a364418e9626ece" +array-initial@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/array-initial/-/array-initial-1.1.0.tgz#2fa74b26739371c3947bd7a7adc73be334b3d795" + integrity sha1-L6dLJnOTccOUe9enrcc74zSz15U= + dependencies: + array-slice "^1.0.0" + is-number "^4.0.0" + +array-last@^1.1.1: + version "1.3.0" + resolved "https://registry.yarnpkg.com/array-last/-/array-last-1.3.0.tgz#7aa77073fec565ddab2493f5f88185f404a9d336" + integrity sha512-eOCut5rXlI6aCOS7Z7kCplKRKyiFQ6dHFBem4PwlwKeNFk2/XxTrhRh5T9PyaEWGy/NHTZWbY+nsZlNFJu9rYg== + dependencies: + is-number "^4.0.0" + array-map@~0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/array-map/-/array-map-0.0.0.tgz#88a2bab73d1cf7bcd5c1b118a003f66f665fa662" @@ -2817,6 +2955,15 @@ array-slice@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-1.1.0.tgz#e368ea15f89bc7069f7ffb89aec3a6c7d4ac22d4" +array-sort@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/array-sort/-/array-sort-1.0.0.tgz#e4c05356453f56f53512a7d1d6123f2c54c0a88a" + integrity sha512-ihLeJkonmdiAsD7vpgN3CRcx2J2S0TiYW+IS/5zHBI7mKUq3ySvBdzzBfD236ubDBQFiiyG3SWCPc+msQ9KoYg== + dependencies: + default-compare "^1.0.0" + get-value "^2.0.6" + kind-of "^5.0.2" + array-union@^1.0.1, array-union@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/array-union/-/array-union-1.0.2.tgz#9a34410e4f4e3da23dea375be5be70f24778ec39" @@ -2896,6 +3043,16 @@ async-child-process@^1.1.1: dependencies: babel-runtime "^6.11.6" +async-done@^1.2.0, async-done@^1.2.2: + version "1.3.2" + resolved "https://registry.yarnpkg.com/async-done/-/async-done-1.3.2.tgz#5e15aa729962a4b07414f528a88cdf18e0b290a2" + integrity sha512-uYkTP8dw2og1tu1nmza1n1CMW0qb8gWWlwqMmLb7MhBVs4BXrFziT6HXUd+/RlRA/i4H9AkofYloUbs1fwMqlw== + dependencies: + end-of-stream "^1.1.0" + once "^1.3.2" + process-nextick-args "^2.0.0" + stream-exhaust "^1.0.1" + async-each@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.1.tgz#19d386a1d9edc6e7c1c85d388aedbcc56d33602d" @@ -2916,6 +3073,13 @@ async-limiter@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/async-limiter/-/async-limiter-1.0.0.tgz#78faed8c3d074ab81f22b4e985d79e8738f720f8" +async-settle@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/async-settle/-/async-settle-1.0.0.tgz#1d0a914bb02575bec8a8f3a74e5080f72b2c0c6b" + integrity sha1-HQqRS7Aldb7IqPOnTlCA9yssDGs= + dependencies: + async-done "^1.2.2" + async@0.2.9: version "0.2.9" resolved "https://registry.yarnpkg.com/async/-/async-0.2.9.tgz#df63060fbf3d33286a76aaf6d55a2986d9ff8619" @@ -2934,6 +3098,13 @@ async@2.6.1, async@^2.1.4: dependencies: lodash "^4.17.10" +async@2.6.2: + version "2.6.2" + resolved "https://registry.yarnpkg.com/async/-/async-2.6.2.tgz#18330ea7e6e313887f5d2f2a904bac6fe4dd5381" + integrity sha512-H1qVYh1MYhEEFLsP97cVKqCGo7KfCyTt6uEWqsTBr9SO84oK9Uwbyd/yCW+6rKJLHksBNUVWZDAjfS+Ccx0Bbg== + dependencies: + lodash "^4.17.11" + async@^0.9.0, async@~0.9.0: version "0.9.2" resolved "https://registry.yarnpkg.com/async/-/async-0.9.2.tgz#aea74d5e61c1f899613bf64bda66d4c78f2fd17d" @@ -2944,6 +3115,13 @@ async@^2.0.1, async@^2.1.2, async@^2.4.0, async@^2.5.0, async@^2.6.0: dependencies: lodash "^4.14.0" +async@^2.6.1: + version "2.6.3" + resolved "https://registry.yarnpkg.com/async/-/async-2.6.3.tgz#d72625e2344a3656e3a3ad4fa749fa83299d82ff" + integrity sha512-zflvls11DCy+dQWzTW2dzuilv8Z5X/pjfmZOWba6TNIVDm+2UDaJmXSOXlasHKfNBs8oo3M0aT50fDEWfKZjXg== + dependencies: + lodash "^4.17.14" + async@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/async/-/async-1.0.0.tgz#f8fc04ca3a13784ade9e1641af98578cfbd647a9" @@ -3717,6 +3895,21 @@ babylon@^6.1.21, babylon@^6.18.0: version "6.18.0" resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.18.0.tgz#af2f3b88fa6f5c1e4c634d1a0f8eac4f55b395e3" +bach@^1.0.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/bach/-/bach-1.2.0.tgz#4b3ce96bf27134f79a1b414a51c14e34c3bd9880" + integrity sha1-Szzpa/JxNPeaG0FKUcFONMO9mIA= + dependencies: + arr-filter "^1.1.1" + arr-flatten "^1.0.1" + arr-map "^2.0.0" + array-each "^1.0.0" + array-initial "^1.0.0" + array-last "^1.1.1" + async-done "^1.2.2" + async-settle "^1.0.0" + now-and-later "^2.0.0" + backoff@^2.5.0: version "2.5.0" resolved "https://registry.yarnpkg.com/backoff/-/backoff-2.5.0.tgz#f616eda9d3e4b66b8ca7fca79f695722c5f8e26f" @@ -3967,7 +4160,7 @@ bn.js@4.11.7: version "4.11.7" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.7.tgz#ddb048e50d9482790094c13eb3fcfc833ce7ab46" -bn.js@4.11.8, bn.js@=4.11.8, bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.1.1, bn.js@^4.10.0, bn.js@^4.11.0, bn.js@^4.11.3, bn.js@^4.11.6, bn.js@^4.11.8, bn.js@^4.4.0, bn.js@^4.8.0: +bn.js@4.11.8, bn.js@=4.11.8, bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.1.1, bn.js@^4.10.0, bn.js@^4.11.0, bn.js@^4.11.1, bn.js@^4.11.3, bn.js@^4.11.6, bn.js@^4.11.8, bn.js@^4.4.0, bn.js@^4.8.0: version "4.11.8" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.8.tgz#2cde09eb5ee341f484746bb0309b3253b1b1442f" @@ -4289,7 +4482,7 @@ buffer@^5.0.3, buffer@^5.0.5: base64-js "^1.0.2" ieee754 "^1.1.4" -buffer@^5.1.0: +buffer@^5.1.0, buffer@^5.2.1: version "5.2.1" resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.2.1.tgz#dd57fa0f109ac59c602479044dca7b8b3d0b71d6" dependencies: @@ -4986,6 +5179,15 @@ collapse-white-space@^1.0.2: version "1.0.4" resolved "https://registry.yarnpkg.com/collapse-white-space/-/collapse-white-space-1.0.4.tgz#ce05cf49e54c3277ae573036a26851ba430a0091" +collection-map@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/collection-map/-/collection-map-1.0.0.tgz#aea0f06f8d26c780c2b75494385544b2255af18c" + integrity sha1-rqDwb40mx4DCt1SUOFVEsiVa8Yw= + dependencies: + arr-map "^2.0.2" + for-own "^1.0.0" + make-iterator "^1.0.0" + collection-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" @@ -5436,6 +5638,14 @@ copy-descriptor@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" +copy-props@^2.0.1: + version "2.0.4" + resolved "https://registry.yarnpkg.com/copy-props/-/copy-props-2.0.4.tgz#93bb1cadfafd31da5bb8a9d4b41f471ec3a72dfe" + integrity sha512-7cjuUME+p+S3HZlbllgsn2CDwS+5eCCX16qBgNC4jgSTf49qR1VKy/Zhl400m0IQXl/bPGEVqncgUUMjrr4s8A== + dependencies: + each-props "^1.3.0" + is-plain-object "^2.0.1" + copy-to-clipboard@^3, copy-to-clipboard@^3.0.8: version "3.0.8" resolved "https://registry.npmjs.org/copy-to-clipboard/-/copy-to-clipboard-3.0.8.tgz#f4e82f4a8830dce4666b7eb8ded0c9bcc313aba9" @@ -5880,6 +6090,13 @@ debug@3.1.0, debug@=3.1.0, debug@^3.1.0: dependencies: ms "2.0.0" +debug@3.2.6: + version "3.2.6" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.6.tgz#e83d17de16d8a7efb7717edbe5fb10135eee629b" + integrity sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ== + dependencies: + ms "^2.1.1" + debug@^4.0.1, debug@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" @@ -6018,6 +6235,13 @@ deepmerge@^2.0.1: version "2.1.1" resolved "https://registry.npmjs.org/deepmerge/-/deepmerge-2.1.1.tgz#e862b4e45ea0555072bf51e7fd0d9845170ae768" +default-compare@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/default-compare/-/default-compare-1.0.0.tgz#cb61131844ad84d84788fb68fd01681ca7781a2f" + integrity sha512-QWfXlM0EkAbqOCbD/6HjdwT19j7WCkMyiRhWilc4H9/5h/RzTF9gv5LYh1+CmDV5d1rki6KAWLtQale0xt20eQ== + dependencies: + kind-of "^5.0.2" + default-gateway@^2.6.0: version "2.7.2" resolved "https://registry.npmjs.org/default-gateway/-/default-gateway-2.7.2.tgz#b7ef339e5e024b045467af403d50348db4642d0f" @@ -6031,6 +6255,11 @@ default-require-extensions@^1.0.0: dependencies: strip-bom "^2.0.0" +default-resolution@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/default-resolution/-/default-resolution-2.0.0.tgz#bcb82baa72ad79b426a76732f1a81ad6df26d684" + integrity sha1-vLgrqnKtebQmp2cy8aga1t8m1oQ= + defaults@^1.0.0, defaults@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/defaults/-/defaults-1.0.3.tgz#c656051e9817d9ff08ed881477f3fe4019f3ef7d" @@ -6456,6 +6685,14 @@ duplexify@^3.6.0: readable-stream "^2.0.0" stream-shift "^1.0.0" +each-props@^1.3.0: + version "1.3.2" + resolved "https://registry.yarnpkg.com/each-props/-/each-props-1.3.2.tgz#ea45a414d16dd5cfa419b1a81720d5ca06892333" + integrity sha512-vV0Hem3zAGkJAyU7JSjixeU66rwdynTAa1vofCrSA5fEln+m67Az9CcnkVD776/fsN/UjIWmBDoNRS6t6G9RfA== + dependencies: + is-plain-object "^2.0.1" + object.defaults "^1.1.0" + ecc-jsbn@~0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.1.tgz#0fc73a9ed5f0d53c38193398523ef7e543777505" @@ -6528,7 +6765,7 @@ encodeurl@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59" -encoding-down@5.0.4: +encoding-down@5.0.4, encoding-down@~5.0.0: version "5.0.4" resolved "https://registry.yarnpkg.com/encoding-down/-/encoding-down-5.0.4.tgz#1e477da8e9e9d0f7c8293d320044f8b2cd8e9614" dependencies: @@ -6683,7 +6920,16 @@ es5-ext@^0.10.35, es5-ext@^0.10.9, es5-ext@~0.10.14: es6-symbol "~3.1.1" next-tick "1" -es6-iterator@~2.0.3: +es5-ext@^0.10.46: + version "0.10.50" + resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.50.tgz#6d0e23a0abdb27018e5ac4fd09b412bc5517a778" + integrity sha512-KMzZTPBkeQV/JcSQhI5/z6d9VWJ3EnQ194USTUwIYZ2ZbpN8+SGXQKt1h68EX44+qt+Fzr8DO17vnxrw7c3agw== + dependencies: + es6-iterator "~2.0.3" + es6-symbol "~3.1.1" + next-tick "^1.0.0" + +es6-iterator@^2.0.1, es6-iterator@^2.0.3, es6-iterator@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" dependencies: @@ -6712,6 +6958,16 @@ es6-symbol@^3.1.1, es6-symbol@~3.1.1: d "1" es5-ext "~0.10.14" +es6-weak-map@^2.0.1: + version "2.0.3" + resolved "https://registry.yarnpkg.com/es6-weak-map/-/es6-weak-map-2.0.3.tgz#b6da1f16cc2cc0d9be43e6bdbfc5e7dfcdf31d53" + integrity sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA== + dependencies: + d "1" + es5-ext "^0.10.46" + es6-iterator "^2.0.3" + es6-symbol "^3.1.1" + escape-html@~1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/escape-html/-/escape-html-1.0.3.tgz#0258eae4d3d0c0974de1c169188ef0051d1d1988" @@ -6960,6 +7216,18 @@ eth-sig-util@2.0.2: ethereumjs-abi "0.6.5" ethereumjs-util "^5.1.1" +eth-sig-util@2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/eth-sig-util/-/eth-sig-util-2.2.0.tgz#769fa3d296b450f6618dedeefe076642c923a16f" + integrity sha512-bAxW35bL4U2lrtjjV8rFGJ8B27z4Sn5v9eIaNdpPUnPfUAtrvx5j8atfyV+k+JOnbppcvKhWCO1rQSBk4kkAhw== + dependencies: + buffer "^5.2.1" + elliptic "^6.4.0" + ethereumjs-abi "0.6.5" + ethereumjs-util "^5.1.1" + tweetnacl "^1.0.0" + tweetnacl-util "^0.15.0" + eth-sig-util@^1.4.2: version "1.4.2" resolved "https://registry.yarnpkg.com/eth-sig-util/-/eth-sig-util-1.4.2.tgz#8d958202c7edbaae839707fba6f09ff327606210" @@ -6985,6 +7253,16 @@ eth-tx-summary@^3.1.2: treeify "^1.0.1" web3-provider-engine "^13.3.2" +ethashjs@~0.0.7: + version "0.0.7" + resolved "https://registry.yarnpkg.com/ethashjs/-/ethashjs-0.0.7.tgz#30bfe4196726690a0c59d3b8272e70d4d0c34bae" + integrity sha1-ML/kGWcmaQoMWdO4Jy5w1NDDS64= + dependencies: + async "^1.4.2" + buffer-xor "^1.0.3" + ethereumjs-util "^4.0.1" + miller-rabin "^4.0.0" + ethereum-common@0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/ethereum-common/-/ethereum-common-0.2.0.tgz#13bf966131cce1eeade62a1b434249bb4cb120ca" @@ -6993,6 +7271,14 @@ ethereum-common@^0.0.18: version "0.0.18" resolved "https://registry.yarnpkg.com/ethereum-common/-/ethereum-common-0.0.18.tgz#2fdc3576f232903358976eb39da783213ff9523f" +ethereum-types@^2.1.4: + version "2.1.4" + resolved "https://registry.yarnpkg.com/ethereum-types/-/ethereum-types-2.1.4.tgz#5e3f5fd562f354d6334500af7a10bea10da0c7c4" + integrity sha512-plsM51Nj4+yC0G5Z+cxWxQ7OTtwnjKDCT6GZyrpt6NVKTANc5woJTJsjvye2o0xwbbtu89/npFvXpH6D5ohwSA== + dependencies: + "@types/node" "*" + bignumber.js "~8.0.2" + ethereumjs-abi@0.6.5: version "0.6.5" resolved "https://registry.yarnpkg.com/ethereumjs-abi/-/ethereumjs-abi-0.6.5.tgz#5a637ef16ab43473fa72a29ad90871405b3f5241" @@ -7000,6 +7286,14 @@ ethereumjs-abi@0.6.5: bn.js "^4.10.0" ethereumjs-util "^4.3.0" +ethereumjs-abi@0.6.7: + version "0.6.7" + resolved "https://registry.yarnpkg.com/ethereumjs-abi/-/ethereumjs-abi-0.6.7.tgz#d1d1c5cdb8d910a7d97645ba9e93be5d153bba2e" + integrity sha512-EMLOA8ICO5yAaXDhjVEfYjsJIXYutY8ufTE93eEKwsVtp2usQreKwsDTJ9zvam3omYqNuffr8IONIqb2uUslGQ== + dependencies: + bn.js "^4.11.8" + ethereumjs-util "^6.0.0" + "ethereumjs-abi@git+https://github.com/ethereumjs/ethereumjs-abi.git": version "0.6.5" resolved "git+https://github.com/ethereumjs/ethereumjs-abi.git#00ba8463a7f7a67fcad737ff9c2ebd95643427f7" @@ -7015,6 +7309,15 @@ ethereumjs-account@2.0.5: rlp "^2.0.0" safe-buffer "^5.1.1" +ethereumjs-account@3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/ethereumjs-account/-/ethereumjs-account-3.0.0.tgz#728f060c8e0c6e87f1e987f751d3da25422570a9" + integrity sha512-WP6BdscjiiPkQfF9PVfMcwx/rDvfZTjFKY0Uwc09zSQr9JfIVH87dYIJu0gNhBhpmovV4yq295fdllS925fnBA== + dependencies: + ethereumjs-util "^6.0.0" + rlp "^2.2.1" + safe-buffer "^5.1.1" + ethereumjs-account@^2.0.3: version "2.0.4" resolved "https://registry.yarnpkg.com/ethereumjs-account/-/ethereumjs-account-2.0.4.tgz#f8c30231bcb707f4514d8a052c1f9da103624d47" @@ -7032,6 +7335,16 @@ ethereumjs-block@2.1.0: ethereumjs-util "^5.0.0" merkle-patricia-tree "^2.1.2" +ethereumjs-block@2.2.0, ethereumjs-block@~2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/ethereumjs-block/-/ethereumjs-block-2.2.0.tgz#8c6c3ab4a5eff0a16d9785fbeedbe643f4dbcbef" + dependencies: + async "^2.0.1" + ethereumjs-common "^1.1.0" + ethereumjs-tx "^1.2.2" + ethereumjs-util "^5.0.0" + merkle-patricia-tree "^2.1.2" + ethereumjs-block@^1.2.2, ethereumjs-block@^1.4.1, ethereumjs-block@^1.6.0, ethereumjs-block@~1.7.0: version "1.7.1" resolved "https://registry.yarnpkg.com/ethereumjs-block/-/ethereumjs-block-1.7.1.tgz#78b88e6cc56de29a6b4884ee75379b6860333c3f" @@ -7042,15 +7355,21 @@ ethereumjs-block@^1.2.2, ethereumjs-block@^1.4.1, ethereumjs-block@^1.6.0, ether ethereumjs-util "^5.0.0" merkle-patricia-tree "^2.1.2" -ethereumjs-block@~2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/ethereumjs-block/-/ethereumjs-block-2.2.0.tgz#8c6c3ab4a5eff0a16d9785fbeedbe643f4dbcbef" +ethereumjs-blockchain@^3.4.0: + version "3.4.0" + resolved "https://registry.yarnpkg.com/ethereumjs-blockchain/-/ethereumjs-blockchain-3.4.0.tgz#92240da6ecd86b3d8d324df69510b381f26c966b" + integrity sha512-wxPSmt6EQjhbywkFbftKcb0qRFIZWocHMuDa8/AB4eWL/UPYalNcDyLaxYbrDytmhHid3Uu8G/tA3C/TxZBuOQ== dependencies: - async "^2.0.1" + async "^2.6.1" + ethashjs "~0.0.7" + ethereumjs-block "~2.2.0" ethereumjs-common "^1.1.0" - ethereumjs-tx "^1.2.2" - ethereumjs-util "^5.0.0" - merkle-patricia-tree "^2.1.2" + ethereumjs-util "~6.0.0" + flow-stoplight "^1.0.0" + level-mem "^3.0.1" + lru-cache "^5.1.1" + safe-buffer "^5.1.2" + semaphore "^1.1.0" ethereumjs-blockstream@6.0.0: version "6.0.0" @@ -7094,6 +7413,18 @@ ethereumjs-util@5.2.0, ethereumjs-util@^5.2.0: safe-buffer "^5.1.1" secp256k1 "^3.0.1" +ethereumjs-util@6.1.0, ethereumjs-util@^6.0.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-6.1.0.tgz#e9c51e5549e8ebd757a339cc00f5380507e799c8" + dependencies: + bn.js "^4.11.0" + create-hash "^1.1.2" + ethjs-util "0.1.6" + keccak "^1.0.2" + rlp "^2.0.0" + safe-buffer "^5.1.1" + secp256k1 "^3.0.1" + ethereumjs-util@^4.0.1, ethereumjs-util@^4.3.0: version "4.5.0" resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-4.5.0.tgz#3e9428b317eebda3d7260d854fddda954b1f1bc6" @@ -7116,18 +7447,37 @@ ethereumjs-util@^5.0.0, ethereumjs-util@^5.0.1, ethereumjs-util@^5.1.1, ethereum safe-buffer "^5.1.1" secp256k1 "^3.0.1" -ethereumjs-util@^6.0.0: - version "6.1.0" - resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-6.1.0.tgz#e9c51e5549e8ebd757a339cc00f5380507e799c8" +ethereumjs-util@~6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-6.0.0.tgz#f14841c182b918615afefd744207c7932c8536c0" + integrity sha512-E3yKUyl0Fs95nvTFQZe/ZSNcofhDzUsDlA5y2uoRmf1+Ec7gpGhNCsgKkZBRh7Br5op8mJcYF/jFbmjj909+nQ== dependencies: bn.js "^4.11.0" create-hash "^1.1.2" - ethjs-util "0.1.6" + ethjs-util "^0.1.6" keccak "^1.0.2" rlp "^2.0.0" safe-buffer "^5.1.1" secp256k1 "^3.0.1" +ethereumjs-vm@3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/ethereumjs-vm/-/ethereumjs-vm-3.0.0.tgz#70fea2964a6797724b0d93fe080f9984ad18fcdd" + integrity sha512-lNu+G/RWPRCrQM5s24MqgU75PEGiAhL4Ombw0ew6m08d+amsxf/vGAb98yDNdQqqHKV6JbwO/tCGfdqXGI6Cug== + dependencies: + async "^2.1.2" + async-eventemitter "^0.2.2" + ethereumjs-account "^2.0.3" + ethereumjs-block "~2.2.0" + ethereumjs-blockchain "^3.4.0" + ethereumjs-common "^1.1.0" + ethereumjs-util "^6.0.0" + fake-merkle-patricia-tree "^1.0.1" + functional-red-black-tree "^1.0.1" + merkle-patricia-tree "^2.3.2" + rustbn.js "~0.2.0" + safe-buffer "^5.1.1" + ethereumjs-vm@^2.0.2, ethereumjs-vm@^2.1.0, ethereumjs-vm@^2.3.4: version "2.3.4" resolved "https://registry.yarnpkg.com/ethereumjs-vm/-/ethereumjs-vm-2.3.4.tgz#f635d7cb047571a1840a6e9a74d29de4488f8ad6" @@ -7173,6 +7523,21 @@ ethereumjs-wallet@0.6.2: utf8 "^3.0.0" uuid "^3.3.2" +ethereumjs-wallet@0.6.3: + version "0.6.3" + resolved "https://registry.yarnpkg.com/ethereumjs-wallet/-/ethereumjs-wallet-0.6.3.tgz#b0eae6f327637c2aeb9ccb9047b982ac542e6ab1" + integrity sha512-qiXPiZOsStem+Dj/CQHbn5qex+FVkuPmGH7SvSnA9F3tdRDt8dLMyvIj3+U05QzVZNPYh4HXEdnzoYI4dZkr9w== + dependencies: + aes-js "^3.1.1" + bs58check "^2.1.2" + ethereumjs-util "^6.0.0" + hdkey "^1.1.0" + randombytes "^2.0.6" + safe-buffer "^5.1.2" + scrypt.js "^0.3.0" + utf8 "^3.0.0" + uuid "^3.3.2" + ethers@~4.0.4: version "4.0.4" resolved "https://registry.yarnpkg.com/ethers/-/ethers-4.0.4.tgz#d3f85e8b27f4b59537e06526439b0fb15b44dc65" @@ -7211,7 +7576,7 @@ ethjs-unit@0.1.6: bn.js "4.11.6" number-to-bn "1.7.0" -ethjs-util@0.1.6: +ethjs-util@0.1.6, ethjs-util@^0.1.6: version "0.1.6" resolved "https://registry.yarnpkg.com/ethjs-util/-/ethjs-util-0.1.6.tgz#f308b62f185f9fe6237132fb2a9818866a5cd536" dependencies: @@ -7567,6 +7932,16 @@ fancy-log@^1.1.0: color-support "^1.1.3" time-stamp "^1.0.0" +fancy-log@^1.3.2: + version "1.3.3" + resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.3.tgz#dbc19154f558690150a23953a0adbd035be45fc7" + integrity sha512-k9oEhlyc0FrVh25qYuSELjr8oxsCoc4/LEZfg2iJJrfEk/tZL9bCoJE47gqAvI2m/AUjluCS4+3I0eTx8n3AEw== + dependencies: + ansi-gray "^0.1.1" + color-support "^1.1.3" + parse-node-version "^1.0.0" + time-stamp "^1.0.0" + 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" @@ -7836,6 +8211,16 @@ findup-sync@^2.0.0: micromatch "^3.0.4" resolve-dir "^1.0.1" +findup-sync@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-3.0.0.tgz#17b108f9ee512dfb7a5c7f3c8b27ea9e1a9c08d1" + integrity sha512-YbffarhcicEhOrm4CtrwdKBdCuz576RLdhJDsIfvNtxUuhdRet1qZcsMjqbePtAseKdAnDyM/IyXbu7PRPRLYg== + dependencies: + detect-file "^1.0.0" + is-glob "^4.0.0" + micromatch "^3.0.4" + resolve-dir "^1.0.1" + fined@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/fined/-/fined-1.1.0.tgz#b37dc844b76a2f5e7081e884f7c0ae344f153476" @@ -7893,6 +8278,11 @@ flickity@^2.1.1: tap-listener "^2.0.0" unidragger "^2.3.0" +flow-stoplight@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/flow-stoplight/-/flow-stoplight-1.0.0.tgz#4a292c5bcff8b39fa6cc0cb1a853d86f27eeff7b" + integrity sha1-SiksW8/4s5+mzAyxqFPYbyfu/3s= + flush-write-stream@^1.0.0, flush-write-stream@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/flush-write-stream/-/flush-write-stream-1.0.3.tgz#c5d586ef38af6097650b49bc41b55fabb19f35bd" @@ -8141,7 +8531,7 @@ function.prototype.name@^1.1.0: function-bind "^1.1.1" is-callable "^1.1.3" -functional-red-black-tree@^1.0.1: +functional-red-black-tree@^1.0.1, functional-red-black-tree@~1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" @@ -8187,6 +8577,39 @@ ganache-core@^2.5.3: ethereumjs-wallet "0.6.2" web3 "1.0.0-beta.35" +ganache-core@^2.6.0: + version "2.6.1" + resolved "https://registry.yarnpkg.com/ganache-core/-/ganache-core-2.6.1.tgz#b97156cd53d0492477c1229d57f8a97763d30d46" + integrity sha512-P3X8yo1GAabYuc8SOnWAFyHL8LhOlNOG6amtItgOEDBTUXMKlkGKP42OxjKovxCAlE7d9CXmYXo1Bu0rffBm9w== + dependencies: + abstract-leveldown "3.0.0" + async "2.6.2" + bip39 "2.5.0" + cachedown "1.0.0" + clone "2.1.2" + debug "3.2.6" + encoding-down "5.0.4" + eth-sig-util "2.2.0" + ethereumjs-abi "0.6.7" + ethereumjs-account "3.0.0" + ethereumjs-block "2.2.0" + ethereumjs-tx "1.3.7" + ethereumjs-util "6.1.0" + ethereumjs-vm "3.0.0" + heap "0.2.6" + level-sublevel "6.6.4" + levelup "3.1.1" + lodash "4.17.14" + merkle-patricia-tree "2.3.2" + seedrandom "3.0.1" + source-map-support "0.5.12" + tmp "0.1.0" + web3-provider-engine "14.2.0" + websocket "1.0.29" + optionalDependencies: + ethereumjs-wallet "0.6.3" + web3 "1.0.0-beta.35" + gauge@~1.2.5: version "1.2.7" resolved "https://registry.yarnpkg.com/gauge/-/gauge-1.2.7.tgz#e9cec5483d3d4ee0ef44b60a7d99e4935e136d93" @@ -8428,6 +8851,18 @@ glob-watcher@^0.0.6: dependencies: gaze "^0.5.1" +glob-watcher@^5.0.3: + version "5.0.3" + resolved "https://registry.yarnpkg.com/glob-watcher/-/glob-watcher-5.0.3.tgz#88a8abf1c4d131eb93928994bc4a593c2e5dd626" + integrity sha512-8tWsULNEPHKQ2MR4zXuzSmqbdyV5PtwwCaWSGQ1WwHsJ07ilNeN1JB8ntxhckbnpSHaf9dXFUHzIWvm1I13dsg== + dependencies: + anymatch "^2.0.0" + async-done "^1.2.0" + chokidar "^2.0.0" + is-negated-glob "^1.0.0" + just-debounce "^1.0.0" + object.defaults "^1.1.0" + glob2base@^0.0.12: version "0.0.12" resolved "https://registry.yarnpkg.com/glob2base/-/glob2base-0.0.12.tgz#9d419b3e28f12e83a362164a277055922c9c0d56" @@ -8651,11 +9086,28 @@ got@^6.7.1: unzip-response "^2.0.1" url-parse-lax "^1.0.0" -graceful-fs@4.1.15, graceful-fs@^3.0.0, graceful-fs@^4.0.0, graceful-fs@^4.1.10, graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9, graceful-fs@^4.2.0, graceful-fs@~1.2.0: +graceful-fs@^3.0.0: + version "3.0.11" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-3.0.11.tgz#7613c778a1afea62f25c630a086d7f3acbbdd818" + integrity sha1-dhPHeKGv6mLyXGMKCG1/Osu92Bg= + dependencies: + natives "^1.1.0" + +graceful-fs@^4.0.0, graceful-fs@^4.1.10, graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9: version "4.1.15" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00" integrity sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA== +graceful-fs@^4.2.0: + version "4.2.1" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.1.tgz#1c1f0c364882c868f5bff6512146328336a11b1d" + integrity sha512-b9usnbDGnD928gJB3LrCmxoibr3VE4U2SMo5PBuBnokWyDADTqDPXg4YpwKF1trpH+UbGp7QLicO3+aWEy0+mw== + +graceful-fs@~1.2.0: + version "1.2.3" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-1.2.3.tgz#15a4806a57547cb2d2dbf27f42e89a8c3451b364" + integrity sha1-FaSAaldUfLLS2/J/QuiajDRRs2Q= + "graceful-readlink@>= 1.0.0": version "1.0.1" resolved "https://registry.yarnpkg.com/graceful-readlink/-/graceful-readlink-1.0.1.tgz#4cafad76bc62f02fa039b2f94e9a3dd3a391a725" @@ -8672,6 +9124,30 @@ gud@^1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/gud/-/gud-1.0.0.tgz#a489581b17e6a70beca9abe3ae57de7a499852c0" +gulp-cli@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/gulp-cli/-/gulp-cli-2.2.0.tgz#5533126eeb7fe415a7e3e84a297d334d5cf70ebc" + integrity sha512-rGs3bVYHdyJpLqR0TUBnlcZ1O5O++Zs4bA0ajm+zr3WFCfiSLjGwoCBqFs18wzN+ZxahT9DkOK5nDf26iDsWjA== + dependencies: + ansi-colors "^1.0.1" + archy "^1.0.0" + array-sort "^1.0.0" + color-support "^1.1.3" + concat-stream "^1.6.0" + copy-props "^2.0.1" + fancy-log "^1.3.2" + gulplog "^1.0.0" + interpret "^1.1.0" + isobject "^3.0.1" + liftoff "^3.1.0" + matchdep "^2.0.0" + mute-stdout "^1.0.0" + pretty-hrtime "^1.0.0" + replace-homedir "^1.0.0" + semver-greatest-satisfied-range "^1.1.0" + v8flags "^3.0.1" + yargs "^7.1.0" + gulp-util@^3.0.0: version "3.0.8" resolved "https://registry.yarnpkg.com/gulp-util/-/gulp-util-3.0.8.tgz#0054e1e744502e27c04c187c3ecc505dd54bbb4f" @@ -8713,6 +9189,16 @@ gulp@^3.9.1: v8flags "^2.0.2" vinyl-fs "^0.3.0" +gulp@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/gulp/-/gulp-4.0.2.tgz#543651070fd0f6ab0a0650c6a3e6ff5a7cb09caa" + integrity sha512-dvEs27SCZt2ibF29xYgmnwwCYZxdxhQ/+LFWlbAW8y7jt68L/65402Lz3+CKy0Ov4rOs+NERmDq7YlZaDqUIfA== + dependencies: + glob-watcher "^5.0.3" + gulp-cli "^2.2.0" + undertaker "^1.2.1" + vinyl-fs "^3.0.0" + gulplog@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/gulplog/-/gulplog-1.0.0.tgz#e28c4d45d05ecbbed818363ce8f9c5926229ffe5" @@ -8926,7 +9412,7 @@ hdkey@^0.7.1: coinstring "^2.0.0" secp256k1 "^3.0.1" -hdkey@^1.0.0: +hdkey@^1.0.0, hdkey@^1.1.0: version "1.1.1" resolved "https://registry.npmjs.org/hdkey/-/hdkey-1.1.1.tgz#c2b3bfd5883ff9529b72f2f08b28be0972a9f64a" dependencies: @@ -9284,7 +9770,7 @@ imagesloaded@^4.1.3: dependencies: ev-emitter "^1.0.0" -immediate@^3.2.3: +immediate@^3.2.3, immediate@~3.2.3: version "3.2.3" resolved "https://registry.yarnpkg.com/immediate/-/immediate-3.2.3.tgz#d140fa8f614659bd6541233097ddaac25cdd991c" @@ -10738,6 +11224,11 @@ jump.js@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/jump.js/-/jump.js-1.0.1.tgz#0de2b1631ba9a1c2c6b8572ad277d877e8503600" +just-debounce@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/just-debounce/-/just-debounce-1.0.0.tgz#87fccfaeffc0b68cd19d55f6722943f929ea35ea" + integrity sha1-h/zPrv/AtozRnVX2cilD+SnqNeo= + just-extend@^1.1.27: version "1.1.27" resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-1.1.27.tgz#ec6e79410ff914e472652abfa0e603c03d60e905" @@ -10778,7 +11269,7 @@ kind-of@^4.0.0: dependencies: is-buffer "^1.1.5" -kind-of@^5.0.0: +kind-of@^5.0.0, kind-of@^5.0.2: version "5.1.0" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" @@ -10796,6 +11287,14 @@ kleur@^2.0.1: version "2.0.2" resolved "https://registry.npmjs.org/kleur/-/kleur-2.0.2.tgz#b704f4944d95e255d038f0cb05fb8a602c55a300" +last-run@^1.1.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/last-run/-/last-run-1.1.1.tgz#45b96942c17b1c79c772198259ba943bebf8ca5b" + integrity sha1-RblpQsF7HHnHchmCWbqUO+v4yls= + dependencies: + default-resolution "^2.0.0" + es6-weak-map "^2.0.1" + latest-version@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/latest-version/-/latest-version-3.1.0.tgz#a205383fea322b33b5ae3b18abee0dc2f356ee15" @@ -10944,6 +11443,22 @@ level-iterator-stream@~3.0.0: readable-stream "^2.3.6" xtend "^4.0.0" +level-mem@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/level-mem/-/level-mem-3.0.1.tgz#7ce8cf256eac40f716eb6489654726247f5a89e5" + integrity sha512-LbtfK9+3Ug1UmvvhR2DqLqXiPW1OJ5jEh0a3m9ZgAipiwpSxGj/qaVVy54RG5vAQN1nCuXqjvprCuKSCxcJHBg== + dependencies: + level-packager "~4.0.0" + memdown "~3.0.0" + +level-packager@~4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/level-packager/-/level-packager-4.0.1.tgz#7e7d3016af005be0869bc5fa8de93d2a7f56ffe6" + integrity sha512-svCRKfYLn9/4CoFfi+d8krOtrp6RoX8+xm0Na5cgXMqSyRru0AnDYdLl+YI8u1FyS6gGZ94ILLZDE5dh2but3Q== + dependencies: + encoding-down "~5.0.0" + levelup "^3.0.0" + level-post@^1.0.7: version "1.0.7" resolved "https://registry.yarnpkg.com/level-post/-/level-post-1.0.7.tgz#19ccca9441a7cc527879a0635000f06d5e8f27d0" @@ -10972,7 +11487,7 @@ level-ws@0.0.0: readable-stream "~1.0.15" xtend "~2.1.1" -levelup@3.1.1: +levelup@3.1.1, levelup@^3.0.0: version "3.1.1" resolved "https://registry.yarnpkg.com/levelup/-/levelup-3.1.1.tgz#c2c0b3be2b4dc316647c53b42e2f559e232d2189" dependencies: @@ -11026,6 +11541,20 @@ liftoff@^2.1.0: rechoir "^0.6.2" resolve "^1.1.7" +liftoff@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/liftoff/-/liftoff-3.1.0.tgz#c9ba6081f908670607ee79062d700df062c52ed3" + integrity sha512-DlIPlJUkCV0Ips2zf2pJP0unEoT1kwYhiiPUGF3s/jtxTCjziNLoiVVh+jqWOWeFi6mmwQ5fNxvAUyPad4Dfog== + dependencies: + extend "^3.0.0" + findup-sync "^3.0.0" + fined "^1.0.1" + flagged-respawn "^1.0.0" + is-plain-object "^2.0.4" + object.map "^1.0.0" + rechoir "^0.6.2" + resolve "^1.1.7" + 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" @@ -11426,6 +11955,11 @@ lodash@4.17.11, lodash@^4.0.0, lodash@^4.13.1, lodash@^4.15.0, lodash@^4.17.11, version "4.17.11" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" +lodash@4.17.14: + version "4.17.14" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.14.tgz#9ce487ae66c96254fe20b599f21b6816028078ba" + integrity sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw== + lodash@=4.17.4: version "4.17.4" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae" @@ -11710,6 +12244,16 @@ marked@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/marked/-/marked-0.4.0.tgz#9ad2c2a7a1791f10a852e0112f77b571dce10c66" +matchdep@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/matchdep/-/matchdep-2.0.0.tgz#c6f34834a0d8dbc3b37c27ee8bbcb27c7775582e" + integrity sha1-xvNINKDY28OzfCfui7yyfHd1WC4= + dependencies: + findup-sync "^2.0.0" + micromatch "^3.0.4" + resolve "^1.4.0" + stack-trace "0.0.10" + matchmediaquery@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/matchmediaquery/-/matchmediaquery-0.3.0.tgz#6f672bcdbc44de16825c6917fbcdcfb9b82607b1" @@ -11788,6 +12332,18 @@ memdown@^1.0.0: ltgt "~2.2.0" safe-buffer "~5.1.1" +memdown@~3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/memdown/-/memdown-3.0.0.tgz#93aca055d743b20efc37492e9e399784f2958309" + integrity sha512-tbV02LfZMWLcHcq4tw++NuqMO+FZX8tNJEiD2aNRm48ZZusVg5N8NART+dmBkepJVye986oixErf7jfXboMGMA== + dependencies: + abstract-leveldown "~5.0.0" + functional-red-black-tree "~1.0.1" + immediate "~3.2.3" + inherits "~2.0.1" + ltgt "~2.2.0" + safe-buffer "~5.1.1" + memoize-one@^4.0.0: version "4.0.0" resolved "https://registry.npmjs.org/memoize-one/-/memoize-one-4.0.0.tgz#fc5e2f1427a216676a62ec652cf7398cfad123db" @@ -11888,7 +12444,7 @@ merkle-patricia-tree@2.3.1, merkle-patricia-tree@^2.1.2: rlp "^2.0.0" semaphore ">=1.0.1" -merkle-patricia-tree@^2.3.2: +merkle-patricia-tree@2.3.2, merkle-patricia-tree@^2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/merkle-patricia-tree/-/merkle-patricia-tree-2.3.2.tgz#982ca1b5a0fde00eed2f6aeed1f9152860b8208a" dependencies: @@ -12222,6 +12778,11 @@ multipipe@^0.1.2: dependencies: duplexer2 "0.0.2" +mute-stdout@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/mute-stdout/-/mute-stdout-1.0.1.tgz#acb0300eb4de23a7ddeec014e3e96044b3472331" + integrity sha512-kDcwXR4PS7caBpuRYYBUz9iVixUk3anO3f5OYFiIPwK/20vCzKCHyKoulbiDY1S53zD2bxUpxN/IJ+TnXjfvxg== + mute-stream@0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.4.tgz#a9219960a6d5d5d046597aee51252c6655f7177e" @@ -12267,6 +12828,11 @@ nanomatch@^1.2.9: snapdragon "^0.8.1" to-regex "^3.0.1" +natives@^1.1.0: + version "1.1.6" + resolved "https://registry.yarnpkg.com/natives/-/natives-1.1.6.tgz#a603b4a498ab77173612b9ea1acdec4d980f00bb" + integrity sha512-6+TDFewD4yxY14ptjKaS63GVdtKiES1pTPyxn9Jb0rBqPMZ7VcCiooEhPNsr+mqHtMGxa/5c/HhcC4uPEUw/nA== + natural-compare@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" @@ -12318,7 +12884,7 @@ neo-async@^2.6.0: resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.1.tgz#ac27ada66167fa8849a6addd837f6b189ad2081c" integrity sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw== -next-tick@1: +next-tick@1, next-tick@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" @@ -12888,7 +13454,7 @@ object.assign@^4.0.4, object.assign@^4.1.0: has-symbols "^1.0.0" object-keys "^1.0.11" -object.defaults@^1.1.0: +object.defaults@^1.0.0, object.defaults@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/object.defaults/-/object.defaults-1.1.0.tgz#3a7f868334b407dea06da16d88d5cd29e435fecf" dependencies: @@ -12933,6 +13499,14 @@ object.pick@^1.2.0, object.pick@^1.3.0: dependencies: isobject "^3.0.1" +object.reduce@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/object.reduce/-/object.reduce-1.0.1.tgz#6fe348f2ac7fa0f95ca621226599096825bb03ad" + integrity sha1-b+NI8qx/oPlcpiEiZZkJaCW7A60= + dependencies: + for-own "^1.0.0" + make-iterator "^1.0.0" + object.values@^1.0.4: version "1.0.4" resolved "https://registry.npmjs.org/object.values/-/object.values-1.0.4.tgz#e524da09b4f66ff05df457546ec72ac99f13069a" @@ -13395,6 +13969,11 @@ parse-json@^4.0.0: error-ex "^1.3.1" json-parse-better-errors "^1.0.1" +parse-node-version@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/parse-node-version/-/parse-node-version-1.0.1.tgz#e2b5dbede00e7fa9bc363607f53327e8b073189b" + integrity sha512-3YHlOa/JgH6Mnpr05jP9eDG254US9ek25LyIxZlDItp2iJtwyaXQb57lBYLdT3MowkUFYEV2XXNAYIPlESvJlA== + parse-passwd@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6" @@ -14401,6 +14980,13 @@ randombytes@^2.0.0, randombytes@^2.0.1, randombytes@^2.0.5: dependencies: safe-buffer "^5.1.0" +randombytes@^2.0.6: + version "2.1.0" + resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" + integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== + dependencies: + safe-buffer "^5.1.0" + randomfill@^1.0.3: version "1.0.4" resolved "https://registry.yarnpkg.com/randomfill/-/randomfill-1.0.4.tgz#c92196fc86ab42be983f1bf31778224931d61458" @@ -15253,7 +15839,7 @@ remove-bom-stream@^1.2.0: safe-buffer "^5.1.0" through2 "^2.0.3" -remove-trailing-separator@^1.0.1: +remove-trailing-separator@^1.0.1, remove-trailing-separator@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" @@ -15289,6 +15875,15 @@ replace-ext@1.0.0, replace-ext@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-1.0.0.tgz#de63128373fcbf7c3ccfa4de5a480c45a67958eb" +replace-homedir@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/replace-homedir/-/replace-homedir-1.0.0.tgz#e87f6d513b928dde808260c12be7fec6ff6e798c" + integrity sha1-6H9tUTuSjd6AgmDBK+f+xv9ueYw= + dependencies: + homedir-polyfill "^1.0.1" + is-absolute "^1.0.0" + remove-trailing-separator "^1.1.0" + request-ip@~2.0.1: version "2.0.2" resolved "https://registry.yarnpkg.com/request-ip/-/request-ip-2.0.2.tgz#deeae6d4af21768497db8cd05fa37143f8f1257e" @@ -15493,6 +16088,13 @@ resolve@^1.10.0: dependencies: path-parse "^1.0.6" +resolve@^1.4.0: + version "1.12.0" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.12.0.tgz#3fc644a35c84a48554609ff26ec52b66fa577df6" + integrity sha512-B/dOmuoAik5bKcD6s6nXDCjzUKnaDvdkRyAk6rsmsKLipWj4797iothd7jmmUhWTfinVMU+wc56rYKsit2Qy4w== + dependencies: + path-parse "^1.0.6" + resolve@~1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.5.0.tgz#1f09acce796c9a762579f31b2c1cc4c3cddf9f36" @@ -15571,6 +16173,14 @@ rlp@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/rlp/-/rlp-2.0.0.tgz#9db384ff4b89a8f61563d92395d8625b18f3afb0" +rlp@^2.2.1: + version "2.2.3" + resolved "https://registry.yarnpkg.com/rlp/-/rlp-2.2.3.tgz#7f94aef86cec412df87d5ea1d8cb116a47d45f0e" + integrity sha512-l6YVrI7+d2vpW6D6rS05x2Xrmq8oW7v3pieZOJKBEdjuTF4Kz/iwk55Zyh1Zaz+KOB2kC8+2jZlp2u9L4tTzCQ== + dependencies: + bn.js "^4.11.1" + safe-buffer "^5.1.1" + rollbar-sourcemap-webpack-plugin@^2.4.0: version "2.4.0" resolved "https://registry.yarnpkg.com/rollbar-sourcemap-webpack-plugin/-/rollbar-sourcemap-webpack-plugin-2.4.0.tgz#0d864fe4d7a141a09fafd417415b704f95faddad" @@ -15767,6 +16377,15 @@ scrypt.js@0.2.0, scrypt.js@^0.2.0: scrypt "^6.0.2" scryptsy "^1.2.1" +scrypt.js@^0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/scrypt.js/-/scrypt.js-0.3.0.tgz#6c62d61728ad533c8c376a2e5e3e86d41a95c4c0" + integrity sha512-42LTc1nyFsyv/o0gcHtDztrn+aqpkaCNt5Qh7ATBZfhEZU7IC/0oT/qbBH+uRNoAPvs2fwiOId68FDEoSRA8/A== + dependencies: + scryptsy "^1.2.1" + optionalDependencies: + scrypt "^6.0.2" + scrypt@^6.0.2: version "6.0.3" resolved "https://registry.yarnpkg.com/scrypt/-/scrypt-6.0.3.tgz#04e014a5682b53fa50c2d5cce167d719c06d870d" @@ -15796,6 +16415,11 @@ seedrandom@2.4.4: version "2.4.4" resolved "https://registry.yarnpkg.com/seedrandom/-/seedrandom-2.4.4.tgz#b25ea98632c73e45f58b77cfaa931678df01f9ba" +seedrandom@3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/seedrandom/-/seedrandom-3.0.1.tgz#eb3dde015bcf55df05a233514e5df44ef9dce083" + integrity sha512-1/02Y/rUeU1CJBAGLebiC5Lbo5FnB22gQbIFFYTLkwvp1xdABZJH1sn4ZT1MzXmPpzv+Rf/Lu2NcsLJiK4rcDg== + seek-bzip@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/seek-bzip/-/seek-bzip-1.0.5.tgz#cfe917cb3d274bcffac792758af53173eb1fabdc" @@ -15820,7 +16444,7 @@ semaphore-async-await@^1.5.1: version "1.5.1" resolved "https://registry.yarnpkg.com/semaphore-async-await/-/semaphore-async-await-1.5.1.tgz#857bef5e3644601ca4b9570b87e9df5ca12974fa" -semaphore@>=1.0.1, semaphore@^1.0.3: +semaphore@>=1.0.1, semaphore@^1.0.3, semaphore@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/semaphore/-/semaphore-1.1.0.tgz#aaad8b86b20fe8e9b32b16dc2ee682a8cd26a8aa" @@ -15830,6 +16454,13 @@ semver-diff@^2.0.0, semver-diff@^2.1.0: dependencies: semver "^5.0.3" +semver-greatest-satisfied-range@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/semver-greatest-satisfied-range/-/semver-greatest-satisfied-range-1.1.0.tgz#13e8c2658ab9691cb0cd71093240280d36f77a5b" + integrity sha1-E+jCZYq5aRywzXEJMkAoDTb3els= + dependencies: + sver-compat "^1.5.0" + semver-regex@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/semver-regex/-/semver-regex-1.0.0.tgz#92a4969065f9c70c694753d55248fc68f8f652c9" @@ -16310,6 +16941,14 @@ source-map-resolve@^0.5.2: source-map-url "^0.4.0" urix "^0.1.0" +source-map-support@0.5.12: + version "0.5.12" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.12.tgz#b4f3b10d51857a5af0138d3ce8003b201613d599" + integrity sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + source-map-support@0.5.6, 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" @@ -16492,7 +17131,7 @@ ssri@^6.0.0, ssri@^6.0.1: dependencies: figgy-pudding "^3.5.1" -stack-trace@0.0.x: +stack-trace@0.0.10, stack-trace@0.0.x: version "0.0.10" resolved "https://registry.yarnpkg.com/stack-trace/-/stack-trace-0.0.10.tgz#547c70b347e8d32b4e108ea1a2a159e5fdde19c0" @@ -16555,6 +17194,11 @@ stream-each@^1.1.0: end-of-stream "^1.1.0" stream-shift "^1.0.0" +stream-exhaust@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/stream-exhaust/-/stream-exhaust-1.0.2.tgz#acdac8da59ef2bc1e17a2c0ccf6c320d120e555d" + integrity sha512-b/qaq/GlBK5xaq1yrK9/zFcyRSTNxmcZwFLGSTG0mXgZl/4Z6GgiyYOXOvY7N3eEvFRAG1bkDRz5EPGSvPYQlw== + stream-http@^2.7.2: version "2.8.1" resolved "https://registry.yarnpkg.com/stream-http/-/stream-http-2.8.1.tgz#d0441be1a457a73a733a8a7b53570bebd9ef66a4" @@ -16820,6 +17464,14 @@ supports-color@^5.5.0: dependencies: has-flag "^3.0.0" +sver-compat@^1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/sver-compat/-/sver-compat-1.5.0.tgz#3cf87dfeb4d07b4a3f14827bc186b3fd0c645cd8" + integrity sha1-PPh9/rTQe0o/FIJ7wYaz/QxkXNg= + dependencies: + es6-iterator "^2.0.1" + es6-symbol "^3.1.1" + svg-react-loader@^0.4.6: version "0.4.6" resolved "https://registry.yarnpkg.com/svg-react-loader/-/svg-react-loader-0.4.6.tgz#b263efb3e3d2fff4c682a729351aba5f185051a1" @@ -17248,6 +17900,13 @@ tmp@0.0.33, tmp@^0.0.33: dependencies: os-tmpdir "~1.0.2" +tmp@0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.1.0.tgz#ee434a4e22543082e294ba6201dcc6eafefa2877" + integrity sha512-J7Z2K08jbGcdA1kkQpJSqLF6T0tdQqpR2pnSUXsIchbPdTI9v3e85cLW0d6WDhwuAleOV71j2xWs8qMPfK7nKw== + dependencies: + rimraf "^2.6.3" + tmpl@1.0.x: version "1.0.4" resolved "https://registry.npmjs.org/tmpl/-/tmpl-1.0.4.tgz#23640dd7b42d00433911140820e5cf440e521dd1" @@ -17510,6 +18169,11 @@ tunnel-agent@^0.6.0: dependencies: safe-buffer "^5.0.1" +tweetnacl-util@^0.15.0: + version "0.15.0" + resolved "https://registry.yarnpkg.com/tweetnacl-util/-/tweetnacl-util-0.15.0.tgz#4576c1cee5e2d63d207fee52f1ba02819480bc75" + integrity sha1-RXbBzuXi1j0gf+5S8boCgZSAvHU= + tweetnacl@0.13.2: version "0.13.2" resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.13.2.tgz#453161770469d45cd266c36404e2bc99a8fa9944" @@ -17518,6 +18182,11 @@ 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.1" + resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-1.0.1.tgz#2594d42da73cd036bd0d2a54683dd35a6b55ca17" + integrity sha512-kcoMoKTPYnoeS50tzoqjPY3Uv9axeuuFAZY9M/9zFnhoVvRfxz9K29IMPD7jGmt2c8SW7i3gT9WqDl2+nV7p4A== + type-check@~0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" @@ -17744,6 +18413,26 @@ underscore@~1.4.4: version "1.4.4" resolved "https://registry.npmjs.org/underscore/-/underscore-1.4.4.tgz#61a6a32010622afa07963bf325203cf12239d604" +undertaker-registry@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/undertaker-registry/-/undertaker-registry-1.0.1.tgz#5e4bda308e4a8a2ae584f9b9a4359a499825cc50" + integrity sha1-XkvaMI5KiirlhPm5pDWaSZglzFA= + +undertaker@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/undertaker/-/undertaker-1.2.1.tgz#701662ff8ce358715324dfd492a4f036055dfe4b" + integrity sha512-71WxIzDkgYk9ZS+spIB8iZXchFhAdEo2YU8xYqBYJ39DIUIqziK78ftm26eecoIY49X0J2MLhG4hr18Yp6/CMA== + dependencies: + arr-flatten "^1.0.1" + arr-map "^2.0.0" + bach "^1.0.0" + collection-map "^1.0.0" + es6-weak-map "^2.0.1" + last-run "^1.1.0" + object.defaults "^1.0.0" + object.reduce "^1.0.0" + undertaker-registry "^1.0.0" + unherit@^1.0.4: version "1.1.0" resolved "https://registry.yarnpkg.com/unherit/-/unherit-1.1.0.tgz#6b9aaedfbf73df1756ad9e316dd981885840cd7d" @@ -18087,6 +18776,13 @@ v8flags@^2.0.2: dependencies: user-home "^1.1.1" +v8flags@^3.0.1: + version "3.1.3" + resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-3.1.3.tgz#fc9dc23521ca20c5433f81cc4eb9b3033bb105d8" + integrity sha512-amh9CCg3ZxkzQ48Mhcb8iX7xpAfYJgePHxWMQCBWECpOSqJUXgY26ncA61UTV0BkPqfhcy6mzwCIoP4ygxpW8w== + dependencies: + homedir-polyfill "^1.0.1" + valid-url@^1.0.9: version "1.0.9" resolved "https://registry.yarnpkg.com/valid-url/-/valid-url-1.0.9.tgz#1c14479b40f1397a75782f115e4086447433a200" @@ -18164,7 +18860,7 @@ vinyl-fs@^0.3.0: through2 "^0.6.1" vinyl "^0.4.0" -vinyl-fs@^3.0.2: +vinyl-fs@^3.0.0, vinyl-fs@^3.0.2: version "3.0.3" resolved "https://registry.yarnpkg.com/vinyl-fs/-/vinyl-fs-3.0.3.tgz#c85849405f67428feabbbd5c5dbdd64f47d31bc7" dependencies: @@ -18499,6 +19195,32 @@ web3-provider-engine@14.1.0: xhr "^2.2.0" xtend "^4.0.1" +web3-provider-engine@14.2.0: + version "14.2.0" + resolved "https://registry.yarnpkg.com/web3-provider-engine/-/web3-provider-engine-14.2.0.tgz#2efec157b2c429c5c674c079aea96b0a06de8b3d" + integrity sha512-sfLH5VhGjJrJJT5WcF8aGehcIKRUQ553q9tjQkkLaKU2AaLsRcwffnnWvrgeTkmKSf0y9dwkDTa48RVp+GUCSg== + dependencies: + async "^2.5.0" + backoff "^2.5.0" + clone "^2.0.0" + cross-fetch "^2.1.0" + eth-block-tracker "^3.0.0" + eth-json-rpc-infura "^3.1.0" + eth-sig-util "^1.4.2" + ethereumjs-block "^1.2.2" + ethereumjs-tx "^1.2.0" + ethereumjs-util "^5.1.5" + ethereumjs-vm "^2.3.4" + json-rpc-error "^2.0.0" + json-stable-stringify "^1.0.1" + promise-to-callback "^1.0.0" + readable-stream "^2.2.9" + request "^2.85.0" + semaphore "^1.0.3" + ws "^5.1.1" + xhr "^2.2.0" + xtend "^4.0.1" + web3-provider-engine@^13.3.2: version "13.8.0" resolved "https://registry.yarnpkg.com/web3-provider-engine/-/web3-provider-engine-13.8.0.tgz#4c7c1ad2af5f1fe10343b8a65495879a2f9c00df" @@ -18778,6 +19500,17 @@ websocket@1.0.26: typedarray-to-buffer "^3.1.2" yaeti "^0.0.6" +websocket@1.0.29: + version "1.0.29" + resolved "https://registry.yarnpkg.com/websocket/-/websocket-1.0.29.tgz#3f83e49d3279657c58b02a22d90749c806101b98" + integrity sha512-WhU8jKXC8sTh6ocLSqpZRlOKMNYGwUvjA5+XcIgIk/G3JCaDfkZUr0zA19sVSxJ0TEvm0i5IBzr54RZC4vzW7g== + dependencies: + debug "^2.2.0" + gulp "^4.0.2" + nan "^2.11.0" + typedarray-to-buffer "^3.1.5" + yaeti "^0.0.6" + websocket@^1.0.25, websocket@^1.0.26: version "1.0.28" resolved "https://registry.yarnpkg.com/websocket/-/websocket-1.0.28.tgz#9e5f6fdc8a3fe01d4422647ef93abdd8d45a78d3" @@ -19196,6 +19929,13 @@ yargs-parser@^2.4.1: camelcase "^3.0.0" lodash.assign "^4.0.6" +yargs-parser@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-5.0.0.tgz#275ecf0d7ffe05c77e64e7c86e4cd94bf0e1228a" + integrity sha1-J17PDX/+Bcd+ZOfIbkzZS/DhIoo= + dependencies: + camelcase "^3.0.0" + yargs-parser@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-7.0.0.tgz#8d0ac42f16ea55debd332caf4c4038b3e3f5dfd9" @@ -19330,6 +20070,25 @@ yargs@^4.7.1: y18n "^3.2.1" yargs-parser "^2.4.1" +yargs@^7.1.0: + version "7.1.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-7.1.0.tgz#6ba318eb16961727f5d284f8ea003e8d6154d0c8" + integrity sha1-a6MY6xaWFyf10oT46gA+jWFU0Mg= + dependencies: + camelcase "^3.0.0" + cliui "^3.2.0" + decamelize "^1.1.1" + get-caller-file "^1.0.1" + os-locale "^1.4.0" + read-pkg-up "^1.0.1" + require-directory "^2.1.1" + require-main-filename "^1.0.1" + set-blocking "^2.0.0" + string-width "^1.0.2" + which-module "^1.0.0" + y18n "^3.2.1" + yargs-parser "^5.0.0" + yargs@^8.0.2: version "8.0.2" resolved "https://registry.yarnpkg.com/yargs/-/yargs-8.0.2.tgz#6299a9055b1cefc969ff7e79c1d918dceb22c360"