diff options
Diffstat (limited to 'packages/dev-utils')
-rw-r--r-- | packages/dev-utils/CHANGELOG.json | 82 | ||||
-rw-r--r-- | packages/dev-utils/CHANGELOG.md | 38 | ||||
-rw-r--r-- | packages/dev-utils/README.md | 8 | ||||
-rw-r--r-- | packages/dev-utils/package.json | 32 | ||||
-rw-r--r-- | packages/dev-utils/src/blockchain_lifecycle.ts | 4 | ||||
-rw-r--r-- | packages/dev-utils/src/callback_error_reporter.ts | 2 | ||||
-rw-r--r-- | packages/dev-utils/src/monorepo_scripts/postpublish.ts | 8 | ||||
-rw-r--r-- | packages/dev-utils/src/web3_factory.ts | 9 | ||||
-rw-r--r-- | packages/dev-utils/test/blockchain_lifecycle_test.ts | 2 | ||||
-rw-r--r-- | packages/dev-utils/test/rpc_test.ts | 2 | ||||
-rw-r--r-- | packages/dev-utils/tsconfig.json | 3 | ||||
-rw-r--r-- | packages/dev-utils/tslint.json | 2 |
12 files changed, 153 insertions, 39 deletions
diff --git a/packages/dev-utils/CHANGELOG.json b/packages/dev-utils/CHANGELOG.json index 51ae117cf..fd5a8d446 100644 --- a/packages/dev-utils/CHANGELOG.json +++ b/packages/dev-utils/CHANGELOG.json @@ -1,5 +1,87 @@ [ { + "version": "1.0.13", + "changes": [ + { + "note": "Make web3-provider-engine types a 'dependency' so it's available to users of the library", + "pr": 1105 + } + ], + "timestamp": 1539871071 + }, + { + "version": "1.0.12", + "changes": [ + { + "note": "Dependencies updated" + } + ], + "timestamp": 1538693146 + }, + { + "timestamp": 1538157789, + "version": "1.0.11", + "changes": [ + { + "note": "Dependencies updated" + } + ] + }, + { + "timestamp": 1537907159, + "version": "1.0.10", + "changes": [ + { + "note": "Dependencies updated" + } + ] + }, + { + "timestamp": 1537875740, + "version": "1.0.9", + "changes": [ + { + "note": "Dependencies updated" + } + ] + }, + { + "timestamp": 1537541580, + "version": "1.0.8", + "changes": [ + { + "note": "Dependencies updated" + } + ] + }, + { + "timestamp": 1536142250, + "version": "1.0.7", + "changes": [ + { + "note": "Dependencies updated" + } + ] + }, + { + "timestamp": 1535377027, + "version": "1.0.6", + "changes": [ + { + "note": "Dependencies updated" + } + ] + }, + { + "timestamp": 1535133899, + "version": "1.0.5", + "changes": [ + { + "note": "Dependencies updated" + } + ] + }, + { "timestamp": 1534210131, "version": "1.0.4", "changes": [ diff --git a/packages/dev-utils/CHANGELOG.md b/packages/dev-utils/CHANGELOG.md index 1e244ee7d..a6b60884e 100644 --- a/packages/dev-utils/CHANGELOG.md +++ b/packages/dev-utils/CHANGELOG.md @@ -5,7 +5,43 @@ Edit the package's CHANGELOG.json file only. CHANGELOG -## v1.0.4 - _August 13, 2018_ +## v1.0.13 - _October 18, 2018_ + + * Make web3-provider-engine types a 'dependency' so it's available to users of the library (#1105) + +## v1.0.12 - _October 4, 2018_ + + * Dependencies updated + +## v1.0.11 - _September 28, 2018_ + + * Dependencies updated + +## v1.0.10 - _September 25, 2018_ + + * Dependencies updated + +## v1.0.9 - _September 25, 2018_ + + * Dependencies updated + +## v1.0.8 - _September 21, 2018_ + + * Dependencies updated + +## v1.0.7 - _September 5, 2018_ + + * Dependencies updated + +## v1.0.6 - _August 27, 2018_ + + * Dependencies updated + +## v1.0.5 - _August 24, 2018_ + + * Dependencies updated + +## v1.0.4 - _August 14, 2018_ * Dependencies updated diff --git a/packages/dev-utils/README.md b/packages/dev-utils/README.md index 1c3bd3a3f..73b0b8816 100644 --- a/packages/dev-utils/README.md +++ b/packages/dev-utils/README.md @@ -16,14 +16,14 @@ Boolean env variables should be either `true` or `false`. Defaults to `false` if ## Install ```bash -yarn add @0xproject/dev-utils +yarn add @0x/dev-utils ``` If your project is in [TypeScript](https://www.typescriptlang.org/), add the following to your `tsconfig.json`: ```json "compilerOptions": { - "typeRoots": ["node_modules/@0xproject/typescript-typings/types", "node_modules/@types"], + "typeRoots": ["node_modules/@0x/typescript-typings/types", "node_modules/@types"], } ``` @@ -52,13 +52,13 @@ yarn install To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory: ```bash -PKG=@0xproject/dev-utils yarn build +PKG=@0x/dev-utils yarn build ``` Or continuously rebuild on change: ```bash -PKG=@0xproject/dev-utils yarn watch +PKG=@0x/dev-utils yarn watch ``` ### Clean diff --git a/packages/dev-utils/package.json b/packages/dev-utils/package.json index 79e75a06e..7c6bfde90 100644 --- a/packages/dev-utils/package.json +++ b/packages/dev-utils/package.json @@ -1,6 +1,6 @@ { - "name": "@0xproject/dev-utils", - "version": "1.0.4", + "name": "@0x/dev-utils", + "version": "1.0.13", "engines": { "node": ">=6.12" }, @@ -8,17 +8,16 @@ "main": "lib/src/index.js", "types": "lib/src/index.d.ts", "scripts": { - "watch_without_deps": "tsc -w", - "build": "tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts", + "build": "tsc -b", + "build:ci": "yarn build", "test": "yarn run_mocha", "rebuild_and_test": "run-s clean build test", "test:circleci": "yarn test:coverage", "run_mocha": "mocha --require source-map-support/register --require make-promises-safe lib/test/**/*_test.js --bail --exit", "test:coverage": "nyc npm run test --all && yarn coverage:report:lcov", "coverage:report:lcov": "nyc report --reporter=text-lcov > coverage/lcov.info", - "clean": "shx rm -rf lib scripts", - "lint": "tslint --project .", - "manual:postpublish": "yarn build; node ./scripts/postpublish.js" + "clean": "shx rm -rf lib", + "lint": "tslint --format stylish --project ." }, "license": "Apache-2.0", "repository": { @@ -30,12 +29,9 @@ }, "homepage": "https://github.com/0xProject/0x-monorepo/packages/dev-utils/README.md", "devDependencies": { - "@0xproject/monorepo-scripts": "^1.0.5", - "@0xproject/tslint-config": "^1.0.5", + "@0x/tslint-config": "^1.0.9", "@types/lodash": "4.14.104", "@types/mocha": "^2.2.42", - "chai": "^4.0.1", - "copyfiles": "^2.0.0", "make-promises-safe": "^1.1.0", "mocha": "^4.1.0", "npm-run-all": "^4.1.2", @@ -45,12 +41,14 @@ "typescript": "3.0.1" }, "dependencies": { - "@0xproject/subproviders": "^1.0.5", - "@0xproject/types": "^1.0.1-rc.4", - "@0xproject/typescript-typings": "^1.0.4", - "@0xproject/utils": "^1.0.5", - "@0xproject/web3-wrapper": "^1.2.0", - "ethereum-types": "^1.0.4", + "@0x/subproviders": "^2.1.0", + "@0x/types": "^1.2.0", + "@0x/typescript-typings": "^3.0.3", + "@0x/utils": "^2.0.3", + "@0x/web3-wrapper": "^3.1.0", + "@types/web3-provider-engine": "^14.0.0", + "chai": "^4.0.1", + "ethereum-types": "^1.1.1", "lodash": "^4.17.5" }, "publishConfig": { diff --git a/packages/dev-utils/src/blockchain_lifecycle.ts b/packages/dev-utils/src/blockchain_lifecycle.ts index a48cb0856..e9687787f 100644 --- a/packages/dev-utils/src/blockchain_lifecycle.ts +++ b/packages/dev-utils/src/blockchain_lifecycle.ts @@ -1,5 +1,5 @@ -import { logUtils } from '@0xproject/utils'; -import { NodeType, Web3Wrapper } from '@0xproject/web3-wrapper'; +import { logUtils } from '@0x/utils'; +import { NodeType, Web3Wrapper } from '@0x/web3-wrapper'; import * as _ from 'lodash'; // HACK(albrow): 🐉 We have to do this so that debug.setHead works correctly. diff --git a/packages/dev-utils/src/callback_error_reporter.ts b/packages/dev-utils/src/callback_error_reporter.ts index e69ce1c05..b993bf22a 100644 --- a/packages/dev-utils/src/callback_error_reporter.ts +++ b/packages/dev-utils/src/callback_error_reporter.ts @@ -1,7 +1,7 @@ import * as chai from 'chai'; import * as _ from 'lodash'; -import { DoneCallback } from '@0xproject/types'; +import { DoneCallback } from '@0x/types'; const expect = chai.expect; diff --git a/packages/dev-utils/src/monorepo_scripts/postpublish.ts b/packages/dev-utils/src/monorepo_scripts/postpublish.ts deleted file mode 100644 index dcb99d0f7..000000000 --- a/packages/dev-utils/src/monorepo_scripts/postpublish.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { postpublishUtils } from '@0xproject/monorepo-scripts'; - -import * as packageJSON from '../package.json'; -import * as tsConfigJSON from '../tsconfig.json'; - -const cwd = `${__dirname}/..`; -// tslint:disable-next-line:no-floating-promises -postpublishUtils.runAsync(packageJSON, tsConfigJSON, cwd); diff --git a/packages/dev-utils/src/web3_factory.ts b/packages/dev-utils/src/web3_factory.ts index 8e713fa68..b22bcc88b 100644 --- a/packages/dev-utils/src/web3_factory.ts +++ b/packages/dev-utils/src/web3_factory.ts @@ -4,7 +4,7 @@ import { GanacheSubprovider, RPCSubprovider, Web3ProviderEngine, -} from '@0xproject/subproviders'; +} from '@0x/subproviders'; import * as fs from 'fs'; import * as _ from 'lodash'; @@ -14,6 +14,7 @@ import { env, EnvVars } from './env'; export interface Web3Config { hasAddresses?: boolean; // default: true shouldUseInProcessGanache?: boolean; // default: false + shouldThrowErrorsOnGanacheRPCResponse?: boolean; // default: true rpcUrl?: string; // default: localhost:8545 shouldUseFakeGasEstimate?: boolean; // default: true } @@ -41,15 +42,19 @@ export const web3Factory = { if (!_.isUndefined(config.rpcUrl)) { throw new Error('Cannot use both GanacheSubrovider and RPCSubprovider'); } + const shouldThrowErrorsOnGanacheRPCResponse = + _.isUndefined(config.shouldThrowErrorsOnGanacheRPCResponse) || + config.shouldThrowErrorsOnGanacheRPCResponse; provider.addProvider( new GanacheSubprovider({ + vmErrorsOnRPCResponse: shouldThrowErrorsOnGanacheRPCResponse, gasLimit: constants.GAS_LIMIT, logger, verbose: env.parseBoolean(EnvVars.VerboseGanache), port: 8545, network_id: 50, mnemonic: 'concert load couple harbor equip island argue ramp clarify fence smart topic', - }), + } as any), // TODO remove any once types are merged in DefinitelyTyped ); } else { provider.addProvider(new RPCSubprovider(config.rpcUrl || constants.RPC_URL)); diff --git a/packages/dev-utils/test/blockchain_lifecycle_test.ts b/packages/dev-utils/test/blockchain_lifecycle_test.ts index 7d5e15fbe..d7e54f0e8 100644 --- a/packages/dev-utils/test/blockchain_lifecycle_test.ts +++ b/packages/dev-utils/test/blockchain_lifecycle_test.ts @@ -1,4 +1,4 @@ -import { Web3Wrapper } from '@0xproject/web3-wrapper'; +import { Web3Wrapper } from '@0x/web3-wrapper'; import * as chai from 'chai'; import 'mocha'; diff --git a/packages/dev-utils/test/rpc_test.ts b/packages/dev-utils/test/rpc_test.ts index dfbc0f7b2..f8cea4580 100644 --- a/packages/dev-utils/test/rpc_test.ts +++ b/packages/dev-utils/test/rpc_test.ts @@ -1,4 +1,4 @@ -import { Web3Wrapper } from '@0xproject/web3-wrapper'; +import { Web3Wrapper } from '@0x/web3-wrapper'; import * as chai from 'chai'; import { BlockParamLiteral } from 'ethereum-types'; import 'mocha'; diff --git a/packages/dev-utils/tsconfig.json b/packages/dev-utils/tsconfig.json index e35816553..2ee711adc 100644 --- a/packages/dev-utils/tsconfig.json +++ b/packages/dev-utils/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig", "compilerOptions": { - "outDir": "lib" + "outDir": "lib", + "rootDir": "." }, "include": ["./src/**/*", "./test/**/*"] } diff --git a/packages/dev-utils/tslint.json b/packages/dev-utils/tslint.json index 015dce851..631f46bca 100644 --- a/packages/dev-utils/tslint.json +++ b/packages/dev-utils/tslint.json @@ -1,5 +1,5 @@ { - "extends": ["@0xproject/tslint-config"], + "extends": ["@0x/tslint-config"], "rules": { "completed-docs": false } |