Compare commits
5 Commits
@0x/contra
...
@0x/contra
Author | SHA1 | Date | |
---|---|---|---|
|
c03a014740 | ||
|
84e6d788aa | ||
|
cd296b8767 | ||
|
5946d32a7d | ||
|
842dd8572b |
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "3.7.10",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "3.7.9",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v3.7.10 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v3.7.9 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-asset-proxy",
|
||||
"version": "3.7.9",
|
||||
"version": "3.7.10",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -51,15 +51,15 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/protocol",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contract-wrappers": "^13.15.0",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contract-wrappers": "^13.16.0",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -67,7 +67,7 @@
|
||||
"chai-as-promised": "^7.1.0",
|
||||
"chai-bignumber": "^3.0.0",
|
||||
"dirty-chai": "^2.0.1",
|
||||
"ethereumjs-util": "^5.1.1",
|
||||
"ethereumjs-util": "^7.0.10",
|
||||
"make-promises-safe": "^1.1.0",
|
||||
"mocha": "^6.2.0",
|
||||
"npm-run-all": "^4.1.2",
|
||||
@@ -79,17 +79,17 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/contracts-erc1155": "^2.1.27",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-erc721": "^3.1.27",
|
||||
"@0x/contracts-exchange-libs": "^4.3.27",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contracts-erc1155": "^2.1.28",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-erc721": "^3.1.28",
|
||||
"@0x/contracts-exchange-libs": "^4.3.28",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"lodash": "^4.17.11"
|
||||
},
|
||||
"publishConfig": {
|
||||
|
@@ -168,7 +168,7 @@ describe('StaticCallProxy', () => {
|
||||
it('should revert if the hash of the output is different than expected expected', async () => {
|
||||
const staticCallData = staticCallTarget.isOddNumber(new BigNumber(0)).getABIEncodedTransactionData();
|
||||
const trueAsBuffer = ethUtil.toBuffer('0x0000000000000000000000000000000000000000000000000000000000000001');
|
||||
const expectedResultHash = ethUtil.bufferToHex(ethUtil.sha3(trueAsBuffer));
|
||||
const expectedResultHash = ethUtil.bufferToHex(ethUtil.keccak256(trueAsBuffer));
|
||||
const assetData = assetDataInterface
|
||||
.StaticCall(staticCallTarget.address, staticCallData, expectedResultHash)
|
||||
.getABIEncodedTransactionData();
|
||||
@@ -199,7 +199,7 @@ describe('StaticCallProxy', () => {
|
||||
it('should be successful if a function call with one static input returns the correct value', async () => {
|
||||
const staticCallData = staticCallTarget.isOddNumber(new BigNumber(1)).getABIEncodedTransactionData();
|
||||
const trueAsBuffer = ethUtil.toBuffer('0x0000000000000000000000000000000000000000000000000000000000000001');
|
||||
const expectedResultHash = ethUtil.bufferToHex(ethUtil.sha3(trueAsBuffer));
|
||||
const expectedResultHash = ethUtil.bufferToHex(ethUtil.keccak256(trueAsBuffer));
|
||||
const assetData = assetDataInterface
|
||||
.StaticCall(staticCallTarget.address, staticCallData, expectedResultHash)
|
||||
.getABIEncodedTransactionData();
|
||||
@@ -232,7 +232,7 @@ describe('StaticCallProxy', () => {
|
||||
const offset = '0000000000000000000000000000000000000000000000000000000000000020';
|
||||
const encodedExpectedResultWithOffset = `0x${offset}${abiEncoder.encode(expectedResults).slice(2)}`;
|
||||
const expectedResultHash = ethUtil.bufferToHex(
|
||||
ethUtil.sha3(ethUtil.toBuffer(encodedExpectedResultWithOffset)),
|
||||
ethUtil.keccak256(ethUtil.toBuffer(encodedExpectedResultWithOffset)),
|
||||
);
|
||||
const assetData = assetDataInterface
|
||||
.StaticCall(staticCallTarget.address, staticCallData, expectedResultHash)
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "1.1.28",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "1.1.27",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v1.1.28 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v1.1.27 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-broker",
|
||||
"version": "1.1.27",
|
||||
"version": "1.1.28",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -51,20 +51,20 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/extensions",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-erc721": "^3.1.27",
|
||||
"@0x/contracts-exchange": "^3.2.28",
|
||||
"@0x/contracts-exchange-libs": "^4.3.27",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-erc721": "^3.1.28",
|
||||
"@0x/contracts-exchange": "^3.2.29",
|
||||
"@0x/contracts-exchange-libs": "^4.3.28",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -84,11 +84,11 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"ethereum-types": "^3.4.0"
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"ethereum-types": "^3.5.0"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "3.1.29",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "3.1.28",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v3.1.29 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v3.1.28 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-coordinator",
|
||||
"version": "3.1.28",
|
||||
"version": "3.1.29",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -52,17 +52,17 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/extensions",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-dev-utils": "^1.3.26",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-dev-utils": "^1.3.27",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -82,17 +82,17 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/assert": "^3.0.21",
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/assert": "^3.0.26",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contract-addresses": "^6.0.0",
|
||||
"@0x/contracts-exchange": "^3.2.28",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/json-schemas": "^5.4.1",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"@0x/contracts-exchange": "^3.2.29",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/json-schemas": "^6.1.2",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"http-status-codes": "^1.3.2"
|
||||
},
|
||||
"publishConfig": {
|
||||
|
@@ -1,8 +1,4 @@
|
||||
import { assert as sharedAssert } from '@0x/assert';
|
||||
// HACK: We need those two unused imports because they're actually used by sharedAssert which gets injected here
|
||||
import { Schema } from '@0x/json-schemas'; // tslint:disable-line:no-unused-variable
|
||||
import { Order } from '@0x/types'; // tslint:disable-line:no-unused-variable
|
||||
import { BigNumber } from '@0x/utils'; // tslint:disable-line:no-unused-variable
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
|
||||
export const assert = {
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "1.3.27",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "1.3.26",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v1.3.27 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v1.3.26 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-dev-utils",
|
||||
"version": "1.3.26",
|
||||
"version": "1.3.27",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -41,18 +41,18 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/dev-utils",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/assert": "^3.0.21",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/assert": "^3.0.26",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethers": "~4.0.4",
|
||||
"npm-run-all": "^4.1.2",
|
||||
"shx": "^0.2.2",
|
||||
@@ -63,7 +63,7 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@types/node": "12.12.54"
|
||||
},
|
||||
"publishConfig": {
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "2.1.28",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "2.1.27",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v2.1.28 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v2.1.27 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-erc1155",
|
||||
"version": "2.1.27",
|
||||
"version": "2.1.28",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -52,15 +52,15 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/tokens",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -68,7 +68,7 @@
|
||||
"chai-as-promised": "^7.1.0",
|
||||
"chai-bignumber": "^3.0.0",
|
||||
"dirty-chai": "^2.0.1",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"make-promises-safe": "^1.1.0",
|
||||
"mocha": "^6.2.0",
|
||||
"npm-run-all": "^4.1.2",
|
||||
@@ -80,10 +80,10 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"lodash": "^4.17.11"
|
||||
},
|
||||
"publishConfig": {
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "3.3.7",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "3.3.6",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v3.3.7 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v3.3.6 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-erc20",
|
||||
"version": "3.3.6",
|
||||
"version": "3.3.7",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -51,18 +51,18 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/tokens",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -70,7 +70,7 @@
|
||||
"chai-as-promised": "^7.1.0",
|
||||
"chai-bignumber": "^3.0.0",
|
||||
"dirty-chai": "^2.0.1",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"lodash": "^4.17.11",
|
||||
"make-promises-safe": "^1.1.0",
|
||||
"mocha": "^6.2.0",
|
||||
@@ -82,7 +82,7 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18"
|
||||
"@0x/base-contract": "^6.3.2"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "3.1.28",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "3.1.27",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v3.1.28 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v3.1.27 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-erc721",
|
||||
"version": "3.1.27",
|
||||
"version": "3.1.28",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -52,18 +52,18 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/tokens",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -71,7 +71,7 @@
|
||||
"chai-as-promised": "^7.1.0",
|
||||
"chai-bignumber": "^3.0.0",
|
||||
"dirty-chai": "^2.0.1",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"lodash": "^4.17.11",
|
||||
"make-promises-safe": "^1.1.0",
|
||||
"mocha": "^6.2.0",
|
||||
@@ -84,7 +84,7 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18"
|
||||
"@0x/base-contract": "^6.3.2"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "4.2.29",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "4.2.28",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v4.2.29 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v4.2.28 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-exchange-forwarder",
|
||||
"version": "4.2.28",
|
||||
"version": "4.2.29",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -52,25 +52,25 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/extensions",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-dev-utils": "^1.3.26",
|
||||
"@0x/contracts-erc1155": "^2.1.27",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-erc721": "^3.1.27",
|
||||
"@0x/contracts-exchange": "^3.2.28",
|
||||
"@0x/contracts-exchange-libs": "^4.3.27",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-dev-utils": "^1.3.27",
|
||||
"@0x/contracts-erc1155": "^2.1.28",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-erc721": "^3.1.28",
|
||||
"@0x/contracts-exchange": "^3.2.29",
|
||||
"@0x/contracts-exchange-libs": "^4.3.28",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -90,9 +90,9 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"ethereum-types": "^3.4.0"
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"ethereum-types": "^3.5.0"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "4.3.28",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "4.3.27",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v4.3.28 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v4.3.27 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-exchange-libs",
|
||||
"version": "4.3.27",
|
||||
"version": "4.3.28",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -52,14 +52,14 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/libs",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/subproviders": "^6.4.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/subproviders": "^6.5.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -67,7 +67,7 @@
|
||||
"chai-as-promised": "^7.1.0",
|
||||
"chai-bignumber": "^3.0.0",
|
||||
"dirty-chai": "^2.0.1",
|
||||
"ethereumjs-util": "^5.1.1",
|
||||
"ethereumjs-util": "^7.0.10",
|
||||
"lodash": "^4.17.11",
|
||||
"make-promises-safe": "^1.1.0",
|
||||
"mocha": "^6.2.0",
|
||||
@@ -80,14 +80,14 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"ethereum-types": "^3.4.0"
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"ethereum-types": "^3.5.0"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "3.2.29",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "3.2.28",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v3.2.29 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v3.2.28 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-exchange",
|
||||
"version": "3.2.28",
|
||||
"version": "3.2.29",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -52,21 +52,21 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/protocol",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-exchange-libs": "^4.3.27",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-multisig": "^4.1.28",
|
||||
"@0x/contracts-staking": "^2.0.35",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-exchange-libs": "^4.3.28",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-multisig": "^4.1.29",
|
||||
"@0x/contracts-staking": "^2.0.36",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -74,8 +74,8 @@
|
||||
"chai-as-promised": "^7.1.0",
|
||||
"chai-bignumber": "^3.0.0",
|
||||
"dirty-chai": "^2.0.1",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereumjs-util": "^5.1.1",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethereumjs-util": "^7.0.10",
|
||||
"js-combinatorics": "^0.5.3",
|
||||
"make-promises-safe": "^1.1.0",
|
||||
"mocha": "^6.2.0",
|
||||
@@ -88,13 +88,13 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/contracts-dev-utils": "^1.3.26",
|
||||
"@0x/contracts-erc1155": "^2.1.27",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-erc721": "^3.1.27",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contracts-dev-utils": "^1.3.27",
|
||||
"@0x/contracts-erc1155": "^2.1.28",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-erc721": "^3.1.28",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"lodash": "^4.17.11"
|
||||
},
|
||||
"publishConfig": {
|
||||
|
@@ -86,7 +86,7 @@ blockchainTests.resets('MixinSignatureValidator', env => {
|
||||
|
||||
const SIGNATURE_LENGTH = 65;
|
||||
const generateRandomSignature = (): string => hexUtils.random(SIGNATURE_LENGTH);
|
||||
const hashBytes = (bytesHex: string): string => ethUtil.bufferToHex(ethUtil.sha3(ethUtil.toBuffer(bytesHex)));
|
||||
const hashBytes = (bytesHex: string): string => hexUtils.hash(bytesHex);
|
||||
const signDataHex = (dataHex: string, privateKey: Buffer): string => {
|
||||
const ecSignature = ethUtil.ecsign(ethUtil.toBuffer(dataHex), privateKey);
|
||||
return hexUtils.concat(ecSignature.v, ecSignature.r, ecSignature.s);
|
||||
|
@@ -12,7 +12,6 @@ import { ReferenceFunctions as UtilReferenceFunctions, SafeMathRevertErrors } fr
|
||||
import { FillResults, Order } from '@0x/types';
|
||||
import { AnyRevertError, BigNumber, ExchangeRevertErrors, hexUtils, StringRevertError } from '@0x/utils';
|
||||
import { LogEntry, LogWithDecodedArgs } from 'ethereum-types';
|
||||
import * as ethjs from 'ethereumjs-util';
|
||||
import * as _ from 'lodash';
|
||||
|
||||
import { artifacts } from './artifacts';
|
||||
@@ -104,7 +103,7 @@ blockchainTests('Exchange wrapper functions unit tests.', env => {
|
||||
// Creates a deterministic order signature, even though no signature validation
|
||||
// actually occurs in the test contract.
|
||||
function createOrderSignature(order: Order): string {
|
||||
return ethjs.bufferToHex(ethjs.sha3(ethjs.toBuffer(orderHashUtils.getOrderHashHex(order))));
|
||||
return hexUtils.hash(orderHashUtils.getOrderHashHex(order));
|
||||
}
|
||||
|
||||
// Asserts that `_fillOrder()` was called in the same order and with the same
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "6.2.23",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "6.2.22",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v6.2.23 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v6.2.22 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-extensions",
|
||||
"version": "6.2.22",
|
||||
"version": "6.2.23",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -52,23 +52,23 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/extensions",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-dev-utils": "^1.3.26",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-erc721": "^3.1.27",
|
||||
"@0x/contracts-exchange": "^3.2.28",
|
||||
"@0x/contracts-exchange-libs": "^4.3.27",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-dev-utils": "^1.3.27",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-erc721": "^3.1.28",
|
||||
"@0x/contracts-exchange": "^3.2.29",
|
||||
"@0x/contracts-exchange-libs": "^4.3.28",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -77,7 +77,7 @@
|
||||
"chai-bignumber": "^3.0.0",
|
||||
"dirty-chai": "^2.0.1",
|
||||
"ethereumjs-abi": "0.6.5",
|
||||
"ethereumjs-util": "^5.1.1",
|
||||
"ethereumjs-util": "^7.0.10",
|
||||
"lodash": "^4.17.11",
|
||||
"make-promises-safe": "^1.1.0",
|
||||
"mocha": "^6.2.0",
|
||||
@@ -90,10 +90,10 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"ethereum-types": "^3.4.0"
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"ethereum-types": "^3.5.0"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-integrations",
|
||||
"version": "2.7.36",
|
||||
"version": "2.7.37",
|
||||
"private": true,
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
@@ -52,25 +52,25 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/extensions",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contract-addresses": "^6.0.0",
|
||||
"@0x/contract-wrappers": "^13.15.0",
|
||||
"@0x/contracts-broker": "^1.1.27",
|
||||
"@0x/contracts-coordinator": "^3.1.28",
|
||||
"@0x/contracts-dev-utils": "^1.3.26",
|
||||
"@0x/contracts-exchange-forwarder": "^4.2.28",
|
||||
"@0x/contracts-exchange-libs": "^4.3.27",
|
||||
"@0x/contracts-extensions": "^6.2.22",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/contract-wrappers": "^13.16.0",
|
||||
"@0x/contracts-broker": "^1.1.28",
|
||||
"@0x/contracts-coordinator": "^3.1.29",
|
||||
"@0x/contracts-dev-utils": "^1.3.27",
|
||||
"@0x/contracts-exchange-forwarder": "^4.2.29",
|
||||
"@0x/contracts-exchange-libs": "^4.3.28",
|
||||
"@0x/contracts-extensions": "^6.2.23",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/coordinator-server": "^1.0.5",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/migrations": "^8.0.2",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/protocol-utils": "^1.5.0",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/migrations": "^8.0.3",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/protocol-utils": "^1.5.1",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@azure/core-asynciterator-polyfill": "^1.0.0",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
@@ -93,23 +93,23 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/asset-swapper": "^6.7.0",
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-erc1155": "^2.1.27",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-erc721": "^3.1.27",
|
||||
"@0x/contracts-exchange": "^3.2.28",
|
||||
"@0x/contracts-multisig": "^4.1.28",
|
||||
"@0x/contracts-staking": "^2.0.35",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-zero-ex": "^0.22.0",
|
||||
"@0x/subproviders": "^6.4.1",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereumjs-util": "^6.2.0",
|
||||
"@0x/asset-swapper": "^6.8.0",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-erc1155": "^2.1.28",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-erc721": "^3.1.28",
|
||||
"@0x/contracts-exchange": "^3.2.29",
|
||||
"@0x/contracts-multisig": "^4.1.29",
|
||||
"@0x/contracts-staking": "^2.0.36",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-zero-ex": "^0.22.1",
|
||||
"@0x/subproviders": "^6.5.2",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethereumjs-util": "^7.0.10",
|
||||
"lodash": "^4.17.11"
|
||||
},
|
||||
"publishConfig": {
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "4.1.29",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "4.1.28",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v4.1.29 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v4.1.28 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-multisig",
|
||||
"version": "4.1.28",
|
||||
"version": "4.1.29",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -49,18 +49,18 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/multisig",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
@@ -78,9 +78,9 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"ethereum-types": "^3.4.0"
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"ethereum-types": "^3.5.0"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "2.0.36",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "2.0.35",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v2.0.36 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v2.0.35 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-staking",
|
||||
"version": "2.0.35",
|
||||
"version": "2.0.36",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -53,20 +53,20 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/tokens",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-dev-utils": "^1.3.26",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-exchange-libs": "^4.3.27",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-dev-utils": "^1.3.27",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-exchange-libs": "^4.3.28",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/node": "12.12.54",
|
||||
"chai": "^4.0.1",
|
||||
@@ -87,12 +87,12 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereumjs-util": "^5.1.1"
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethereumjs-util": "^7.0.10"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "5.3.25",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "5.3.24",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v5.3.25 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v5.3.24 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-test-utils",
|
||||
"version": "5.3.24",
|
||||
"version": "5.3.25",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -34,28 +34,28 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/test-utils",
|
||||
"devDependencies": {
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"npm-run-all": "^4.1.2",
|
||||
"shx": "^0.2.2",
|
||||
"tslint": "5.11.0",
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/assert": "^3.0.21",
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/assert": "^3.0.26",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contract-addresses": "^6.0.0",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/json-schemas": "^5.4.1",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/sol-coverage": "^4.0.31",
|
||||
"@0x/sol-profiler": "^4.1.21",
|
||||
"@0x/sol-trace": "^3.0.31",
|
||||
"@0x/subproviders": "^6.4.1",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/json-schemas": "^6.1.2",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/sol-coverage": "^4.0.36",
|
||||
"@0x/sol-profiler": "^4.1.26",
|
||||
"@0x/sol-trace": "^3.0.36",
|
||||
"@0x/subproviders": "^6.5.2",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/bn.js": "^4.11.0",
|
||||
"@types/js-combinatorics": "^0.5.29",
|
||||
"@types/lodash": "4.14.104",
|
||||
@@ -67,8 +67,8 @@
|
||||
"chai-bignumber": "^3.0.0",
|
||||
"decimal.js": "^10.2.0",
|
||||
"dirty-chai": "^2.0.1",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereumjs-util": "^5.1.1",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethereumjs-util": "^7.0.10",
|
||||
"ethers": "~4.0.4",
|
||||
"js-combinatorics": "^0.5.3",
|
||||
"lodash": "^4.17.11",
|
||||
|
@@ -77,7 +77,7 @@ export const constants = {
|
||||
ZERO_AMOUNT: new BigNumber(0),
|
||||
PERCENTAGE_DENOMINATOR: new BigNumber(10).pow(18),
|
||||
TIME_BUFFER: new BigNumber(1000),
|
||||
KECCAK256_NULL: ethUtil.addHexPrefix(ethUtil.bufferToHex(ethUtil.SHA3_NULL)),
|
||||
KECCAK256_NULL: ethUtil.bufferToHex(ethUtil.keccak256(Buffer.alloc(0))),
|
||||
MAX_UINT256_ROOT: new BigNumber('340282366920938463463374607431768211456'),
|
||||
ONE_ETHER: new BigNumber(1e18),
|
||||
EIP712_DOMAIN_NAME: '0x Protocol',
|
||||
|
@@ -57,9 +57,7 @@ describe('Order hashing', () => {
|
||||
...order,
|
||||
takerAddress: (null as any) as string,
|
||||
};
|
||||
const expectedErrorMessage = `Order taker must be of type string. If you want anyone to be able to fill an order - pass ${
|
||||
constants.NULL_ADDRESS
|
||||
}`;
|
||||
const expectedErrorMessage = `Expected order to conform to schema`;
|
||||
expect(() => orderHashUtils.getOrderHashHex(orderWithInvalidtakerFormat)).to.throw(expectedErrorMessage);
|
||||
});
|
||||
});
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "1.1.4",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1619481586,
|
||||
"version": "1.1.3",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v1.1.4 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v1.1.3 - _April 26, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-treasury",
|
||||
"version": "1.1.3",
|
||||
"version": "1.1.4",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -46,16 +46,16 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/treasury",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contract-addresses": "^6.0.0",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-staking": "^2.0.35",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-staking": "^2.0.36",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@types/isomorphic-fetch": "^0.0.35",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
@@ -72,15 +72,15 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/protocol-utils": "^1.5.0",
|
||||
"@0x/subproviders": "^6.4.1",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereumjs-util": "^5.1.1"
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/protocol-utils": "^1.5.1",
|
||||
"@0x/subproviders": "^6.5.2",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethereumjs-util": "^7.0.10"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "4.7.7",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1617311315,
|
||||
"version": "4.7.6",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v4.7.7 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v4.7.6 - _April 1, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-utils",
|
||||
"version": "4.7.6",
|
||||
"version": "4.7.7",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -50,15 +50,15 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/utils",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/bn.js": "^4.11.0",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
@@ -67,7 +67,7 @@
|
||||
"chai-as-promised": "^7.1.0",
|
||||
"chai-bignumber": "^3.0.0",
|
||||
"dirty-chai": "^2.0.1",
|
||||
"ethereumjs-util": "^5.1.1",
|
||||
"ethereumjs-util": "^7.0.10",
|
||||
"lodash": "^4.17.11",
|
||||
"make-promises-safe": "^1.1.0",
|
||||
"mocha": "^6.2.0",
|
||||
@@ -79,11 +79,11 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"bn.js": "^4.11.8",
|
||||
"ethereum-types": "^3.4.0"
|
||||
"ethereum-types": "^3.5.0"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -2,7 +2,6 @@ import { chaiSetup, constants, provider, txDefaults, web3Wrapper } from '@0x/con
|
||||
import { BlockchainLifecycle } from '@0x/dev-utils';
|
||||
import { BigNumber, hexUtils, signTypedDataUtils } from '@0x/utils';
|
||||
import * as chai from 'chai';
|
||||
import * as ethUtil from 'ethereumjs-util';
|
||||
import * as _ from 'lodash';
|
||||
|
||||
import { artifacts } from './artifacts';
|
||||
@@ -78,7 +77,7 @@ describe('LibEIP712', () => {
|
||||
|
||||
// Hash the provided input to get the expected hash
|
||||
const input = '0x1901'.concat(unprefixedDomainHash.concat(unprefixedHashStruct));
|
||||
const expectedHash = '0x'.concat(ethUtil.sha3(input).toString('hex'));
|
||||
const expectedHash = hexUtils.hash(input);
|
||||
|
||||
// Get the actual hash by calling the smart contract
|
||||
const actualHash = await lib.externalHashEIP712Message(domainHash, hashStruct).callAsync();
|
||||
|
@@ -1,4 +1,14 @@
|
||||
[
|
||||
{
|
||||
"version": "0.22.1",
|
||||
"changes": [
|
||||
{
|
||||
"note": "bump feature version to 1.2",
|
||||
"pr": 213
|
||||
}
|
||||
],
|
||||
"timestamp": 1619596077
|
||||
},
|
||||
{
|
||||
"version": "0.22.0",
|
||||
"changes": [
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v0.22.1 - _April 28, 2021_
|
||||
|
||||
* bump feature version to 1.2 (#213)
|
||||
|
||||
## v0.22.0 - _April 26, 2021_
|
||||
|
||||
* Add order signer registry to NativeOrdersFeature (#195)
|
||||
|
@@ -34,7 +34,7 @@ contract NativeOrdersFeature is
|
||||
/// @dev Name of this feature.
|
||||
string public constant override FEATURE_NAME = "LimitOrders";
|
||||
/// @dev Version of this feature.
|
||||
uint256 public immutable override FEATURE_VERSION = _encodeVersion(1, 1, 0);
|
||||
uint256 public immutable override FEATURE_VERSION = _encodeVersion(1, 2, 0);
|
||||
|
||||
constructor(
|
||||
address zeroExAddress,
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contracts-zero-ex",
|
||||
"version": "0.22.0",
|
||||
"version": "0.22.1",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -55,16 +55,16 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/zero-ex",
|
||||
"devDependencies": {
|
||||
"@0x/abi-gen": "^5.4.21",
|
||||
"@0x/abi-gen": "^5.5.2",
|
||||
"@0x/contract-addresses": "^6.0.0",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@types/isomorphic-fetch": "^0.0.35",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
@@ -82,15 +82,15 @@
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/protocol-utils": "^1.5.0",
|
||||
"@0x/subproviders": "^6.4.1",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereumjs-util": "^5.1.1"
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/protocol-utils": "^1.5.1",
|
||||
"@0x/subproviders": "^6.5.2",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethereumjs-util": "^7.0.10"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
@@ -20,6 +20,7 @@ export function rlpEncodeNonce(nonce: number): string {
|
||||
return ethjs.bufferToHex(ethjs.toBuffer(nonce));
|
||||
} else {
|
||||
const rlpNonce = ethjs.toBuffer(nonce);
|
||||
// tslint:disable-next-line: restrict-plus-operands
|
||||
return hexUtils.concat(rlpNonce.length + 0x80, ethjs.bufferToHex(rlpNonce));
|
||||
}
|
||||
}
|
||||
|
@@ -1,6 +1,5 @@
|
||||
import { blockchainTests, expect, verifyEventsFromLogs } from '@0x/contracts-test-utils';
|
||||
import { BigNumber, hexUtils } from '@0x/utils';
|
||||
import * as ethjs from 'ethereumjs-util';
|
||||
|
||||
import { artifacts } from './artifacts';
|
||||
import {
|
||||
@@ -41,9 +40,9 @@ blockchainTests.resets('PermissionlessTransformerDeployer', env => {
|
||||
it('deploys at predictable address', async () => {
|
||||
const salt = hexUtils.random();
|
||||
const targetAddress = await deployer.deploy(deployBytes, salt).callAsync();
|
||||
const initCodeHash = hexUtils.toHex(ethjs.sha3(deployBytes));
|
||||
const initCodeHash = hexUtils.hash(deployBytes);
|
||||
const expectedAddress = hexUtils.slice(
|
||||
hexUtils.toHex(ethjs.sha3(hexUtils.concat('0xFF', deployer.address, salt, initCodeHash))),
|
||||
hexUtils.hash(hexUtils.concat('0xFF', deployer.address, salt, initCodeHash)),
|
||||
12,
|
||||
);
|
||||
|
||||
@@ -94,7 +93,7 @@ blockchainTests.resets('PermissionlessTransformerDeployer', env => {
|
||||
const targetAddress = await deployer.deploy(deployBytes, salt).callAsync({ from: sender });
|
||||
await deployer.deploy(deployBytes, salt).awaitTransactionSuccessAsync({ from: sender });
|
||||
expect(hexUtils.toHex(await deployer.toInitCodeHash(targetAddress).callAsync())).to.eq(
|
||||
hexUtils.toHex(ethjs.sha3(deployBytes)),
|
||||
hexUtils.hash(deployBytes),
|
||||
);
|
||||
});
|
||||
});
|
||||
|
@@ -66,7 +66,7 @@
|
||||
"ignoreDependencyVersionsForPackage": "contract-wrappers"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@0x/monorepo-scripts": "^3.1.1",
|
||||
"@0x/monorepo-scripts": "^3.1.6",
|
||||
"@0x-lerna-fork/lerna": "3.16.10",
|
||||
"@0xproject/npm-cli-login": "^0.0.11",
|
||||
"async-child-process": "^1.1.1",
|
||||
|
@@ -1,4 +1,18 @@
|
||||
[
|
||||
{
|
||||
"version": "6.8.0",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Prune paths which cannot improve the best path",
|
||||
"pr": 183
|
||||
},
|
||||
{
|
||||
"note": "Use FastABI for Sampler ABI encoding and decoding",
|
||||
"pr": 183
|
||||
}
|
||||
],
|
||||
"timestamp": 1619596077
|
||||
},
|
||||
{
|
||||
"version": "6.7.0",
|
||||
"changes": [
|
||||
|
@@ -5,6 +5,11 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v6.8.0 - _April 28, 2021_
|
||||
|
||||
* Prune paths which cannot improve the best path (#183)
|
||||
* Use FastABI for Sampler ABI encoding and decoding (#183)
|
||||
|
||||
## v6.7.0 - _April 26, 2021_
|
||||
|
||||
* Support PancakeSwap V2 (#211)
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/asset-swapper",
|
||||
"version": "6.7.0",
|
||||
"version": "6.8.0",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -57,20 +57,20 @@
|
||||
"registry": "git@github.com:0xProject/gitpkg-registry.git"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/assert": "^3.0.21",
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/assert": "^3.0.26",
|
||||
"@0x/base-contract": "^6.4.0",
|
||||
"@0x/contract-addresses": "^6.0.0",
|
||||
"@0x/contract-wrappers": "^13.15.0",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-zero-ex": "^0.22.0",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/json-schemas": "^5.4.1",
|
||||
"@0x/protocol-utils": "^1.5.0",
|
||||
"@0x/contract-wrappers": "^13.16.0",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-zero-ex": "^0.22.1",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/json-schemas": "^6.1.2",
|
||||
"@0x/protocol-utils": "^1.5.1",
|
||||
"@0x/quote-server": "^5.0.0",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@balancer-labs/sor": "0.3.2",
|
||||
"@bancor/sdk": "0.2.9",
|
||||
"@ethersproject/abi": "^5.0.1",
|
||||
@@ -82,26 +82,27 @@
|
||||
"axios-mock-adapter": "^1.19.0",
|
||||
"cream-sor": "^0.3.3",
|
||||
"decimal.js": "^10.2.0",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereumjs-util": "^5.1.1",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethereumjs-util": "^7.0.10",
|
||||
"fast-abi": "^0.0.2",
|
||||
"heartbeats": "^5.0.1",
|
||||
"lodash": "^4.17.11"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-exchange": "^3.2.28",
|
||||
"@0x/contracts-exchange-libs": "^4.3.27",
|
||||
"@0x/contracts-gen": "^2.0.32",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/abi-gen": "^5.6.0",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-exchange": "^3.2.29",
|
||||
"@0x/contracts-exchange-libs": "^4.3.28",
|
||||
"@0x/contracts-gen": "^2.0.37",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/mesh-rpc-client": "^9.4.2",
|
||||
"@0x/migrations": "^8.0.2",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/subproviders": "^6.4.1",
|
||||
"@0x/migrations": "^8.0.3",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/subproviders": "^6.5.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@types/lodash": "4.14.104",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"@types/node": "12.12.54",
|
||||
|
@@ -2,7 +2,8 @@ import { ChainId, getContractAddressesForChainOrThrow } from '@0x/contract-addre
|
||||
import { FillQuoteTransformerOrderType, LimitOrder } from '@0x/protocol-utils';
|
||||
import { BigNumber, providerUtils } from '@0x/utils';
|
||||
import Axios, { AxiosInstance } from 'axios';
|
||||
import { BlockParamLiteral, SupportedProvider, ZeroExProvider } from 'ethereum-types';
|
||||
import { BlockParamLiteral, MethodAbi, SupportedProvider, ZeroExProvider } from 'ethereum-types';
|
||||
import { FastABI } from 'fast-abi';
|
||||
import { Agent as HttpAgent } from 'http';
|
||||
import { Agent as HttpsAgent } from 'https';
|
||||
import * as _ from 'lodash';
|
||||
@@ -122,12 +123,19 @@ export class SwapQuoter {
|
||||
{ block: BlockParamLiteral.Latest, overrides: defaultCodeOverrides },
|
||||
options.samplerOverrides,
|
||||
);
|
||||
const fastAbi = new FastABI(ERC20BridgeSamplerContract.ABI() as MethodAbi[]);
|
||||
const samplerContract = new ERC20BridgeSamplerContract(
|
||||
this._contractAddresses.erc20BridgeSampler,
|
||||
this.provider,
|
||||
{
|
||||
gas: samplerGasLimit,
|
||||
},
|
||||
{},
|
||||
undefined,
|
||||
{
|
||||
encodeInput: (fnName: string, values: any) => fastAbi.encodeInput(fnName, values),
|
||||
decodeOutput: (fnName: string, data: string) => fastAbi.decodeOutput(fnName, data),
|
||||
},
|
||||
);
|
||||
|
||||
this._marketOperationUtils = new MarketOperationUtils(
|
||||
|
@@ -1025,7 +1025,7 @@ export const DEFAULT_GAS_SCHEDULE: Required<FeeSchedule> = {
|
||||
},
|
||||
[ERC20BridgeSource.Uniswap]: () => 90e3,
|
||||
[ERC20BridgeSource.LiquidityProvider]: fillData => {
|
||||
return (fillData as LiquidityProviderFillData).gasCost;
|
||||
return (fillData as LiquidityProviderFillData).gasCost || 100e3;
|
||||
},
|
||||
[ERC20BridgeSource.Eth2Dai]: () => 400e3,
|
||||
[ERC20BridgeSource.Kyber]: () => 450e3,
|
||||
|
@@ -152,7 +152,7 @@ function dexSamplesToFills(
|
||||
const { source, fillData } = sample;
|
||||
const input = sample.input.minus(prevSample ? prevSample.input : 0);
|
||||
const output = sample.output.minus(prevSample ? prevSample.output : 0);
|
||||
const fee = fees[source] === undefined ? 0 : fees[source]!(sample.fillData);
|
||||
const fee = fees[source] === undefined ? 0 : fees[source]!(sample.fillData) || 0;
|
||||
let penalty = ZERO_AMOUNT;
|
||||
if (i === 0) {
|
||||
// Only the first fill in a DEX path incurs a penalty.
|
||||
|
@@ -152,6 +152,17 @@ export class Path {
|
||||
return getRate(this.side, input, output);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the best possible rate this path can offer, given the fills.
|
||||
*/
|
||||
public bestRate(): BigNumber {
|
||||
const best = this.fills.reduce((prevRate, curr) => {
|
||||
const currRate = getRate(this.side, curr.input, curr.output);
|
||||
return prevRate.isLessThan(currRate) ? currRate : prevRate;
|
||||
}, new BigNumber(0));
|
||||
return best;
|
||||
}
|
||||
|
||||
public adjustedSlippage(maxRate: BigNumber): number {
|
||||
if (maxRate.eq(0)) {
|
||||
return 0;
|
||||
|
@@ -4,7 +4,7 @@ import * as _ from 'lodash';
|
||||
import { MarketOperation } from '../../types';
|
||||
|
||||
import { DEFAULT_PATH_PENALTY_OPTS, Path, PathPenaltyOpts } from './path';
|
||||
import { Fill } from './types';
|
||||
import { ERC20BridgeSource, Fill } from './types';
|
||||
|
||||
// tslint:disable: prefer-for-of custom-no-magic-numbers completed-docs no-bitwise
|
||||
|
||||
@@ -22,12 +22,13 @@ export async function findOptimalPathAsync(
|
||||
opts: PathPenaltyOpts = DEFAULT_PATH_PENALTY_OPTS,
|
||||
): Promise<Path | undefined> {
|
||||
// Sort fill arrays by descending adjusted completed rate.
|
||||
const sortedPaths = fillsToSortedPaths(fills, side, targetInput, opts);
|
||||
// Remove any paths which cannot impact the optimal path
|
||||
const sortedPaths = reducePaths(fillsToSortedPaths(fills, side, targetInput, opts), side);
|
||||
if (sortedPaths.length === 0) {
|
||||
return undefined;
|
||||
}
|
||||
const rates = rateBySourcePathId(sortedPaths);
|
||||
let optimalPath = sortedPaths[0];
|
||||
const rates = rateBySourcePathId(side, fills, targetInput);
|
||||
for (const [i, path] of sortedPaths.slice(1).entries()) {
|
||||
optimalPath = mixPaths(side, optimalPath, path, targetInput, runLimit * RUN_LIMIT_DECAY_FACTOR ** i, rates);
|
||||
// Yield to event loop.
|
||||
@@ -44,10 +45,47 @@ export function fillsToSortedPaths(
|
||||
opts: PathPenaltyOpts,
|
||||
): Path[] {
|
||||
const paths = fills.map(singleSourceFills => Path.create(side, singleSourceFills, targetInput, opts));
|
||||
const sortedPaths = paths.sort((a, b) => b.adjustedCompleteRate().comparedTo(a.adjustedCompleteRate()));
|
||||
const sortedPaths = paths.sort((a, b) => {
|
||||
const aRate = a.adjustedCompleteRate();
|
||||
const bRate = b.adjustedCompleteRate();
|
||||
// There is a case where the adjusted completed rate isn't sufficient for the desired amount
|
||||
// resulting in a NaN div by 0 (output)
|
||||
if (bRate.isNaN()) {
|
||||
return -1;
|
||||
}
|
||||
if (aRate.isNaN()) {
|
||||
return 1;
|
||||
}
|
||||
return bRate.comparedTo(aRate);
|
||||
});
|
||||
return sortedPaths;
|
||||
}
|
||||
|
||||
// Remove paths which have no impact on the optimal path
|
||||
export function reducePaths(sortedPaths: Path[], side: MarketOperation): Path[] {
|
||||
// Any path which has a min rate that is less than the best adjusted completed rate has no chance of improving
|
||||
// the overall route.
|
||||
const bestNonNativeCompletePath = sortedPaths.filter(
|
||||
p => p.isComplete() && p.fills[0].source !== ERC20BridgeSource.Native,
|
||||
)[0];
|
||||
|
||||
// If there is no complete path then just go ahead with the sorted paths
|
||||
// I.e if the token only exists on sources which cannot sell to infinity
|
||||
// or buys where X is greater than all the tokens available in the pools
|
||||
if (!bestNonNativeCompletePath) {
|
||||
return sortedPaths;
|
||||
}
|
||||
const bestNonNativeCompletePathAdjustedRate = bestNonNativeCompletePath.adjustedCompleteRate();
|
||||
if (!bestNonNativeCompletePathAdjustedRate.isGreaterThan(0)) {
|
||||
return sortedPaths;
|
||||
}
|
||||
|
||||
const filteredPaths = sortedPaths.filter(p =>
|
||||
p.bestRate().isGreaterThanOrEqualTo(bestNonNativeCompletePathAdjustedRate),
|
||||
);
|
||||
return filteredPaths;
|
||||
}
|
||||
|
||||
function mixPaths(
|
||||
side: MarketOperation,
|
||||
pathA: Path,
|
||||
@@ -98,17 +136,6 @@ function mixPaths(
|
||||
return bestPath;
|
||||
}
|
||||
|
||||
function rateBySourcePathId(
|
||||
side: MarketOperation,
|
||||
fills: Fill[][],
|
||||
targetInput: BigNumber,
|
||||
): { [id: string]: BigNumber } {
|
||||
const flattenedFills = _.flatten(fills);
|
||||
const sourcePathIds = flattenedFills.filter(f => f.index === 0).map(f => f.sourcePathId);
|
||||
return Object.assign(
|
||||
{},
|
||||
...sourcePathIds.map(s => ({
|
||||
[s]: Path.create(side, flattenedFills.filter(f => f.sourcePathId === s), targetInput).adjustedRate(),
|
||||
})),
|
||||
);
|
||||
function rateBySourcePathId(paths: Path[]): { [id: string]: BigNumber } {
|
||||
return _.fromPairs(paths.map(p => [p.fills[0].sourcePathId, p.adjustedRate()]));
|
||||
}
|
||||
|
@@ -141,6 +141,13 @@ export class SamplerOperations {
|
||||
orders: SignedNativeOrder[],
|
||||
exchangeAddress: string,
|
||||
): BatchedOperation<BigNumber[]> {
|
||||
// Skip checking empty or invalid orders on-chain, returning a constant
|
||||
if (orders.length === 0) {
|
||||
return SamplerOperations.constant<BigNumber[]>([]);
|
||||
}
|
||||
if (orders.length === 1 && orders[0].order.maker === NULL_ADDRESS) {
|
||||
return SamplerOperations.constant<BigNumber[]>([ZERO_AMOUNT]);
|
||||
}
|
||||
return new SamplerContractOperation({
|
||||
source: ERC20BridgeSource.Native,
|
||||
contract: this._samplerContract,
|
||||
@@ -154,6 +161,13 @@ export class SamplerOperations {
|
||||
orders: SignedNativeOrder[],
|
||||
exchangeAddress: string,
|
||||
): BatchedOperation<BigNumber[]> {
|
||||
// Skip checking empty or invalid orders on-chain, returning a constant
|
||||
if (orders.length === 0) {
|
||||
return SamplerOperations.constant<BigNumber[]>([]);
|
||||
}
|
||||
if (orders.length === 1 && orders[0].order.maker === NULL_ADDRESS) {
|
||||
return SamplerOperations.constant<BigNumber[]>([ZERO_AMOUNT]);
|
||||
}
|
||||
return new SamplerContractOperation({
|
||||
source: ERC20BridgeSource.Native,
|
||||
contract: this._samplerContract,
|
||||
|
@@ -299,6 +299,7 @@ describe('MarketOperationUtils tests', () => {
|
||||
[ERC20BridgeSource.Native]: createDecreasingRates(NUM_SAMPLES),
|
||||
[ERC20BridgeSource.Eth2Dai]: createDecreasingRates(NUM_SAMPLES),
|
||||
[ERC20BridgeSource.Uniswap]: createDecreasingRates(NUM_SAMPLES),
|
||||
[ERC20BridgeSource.Kyber]: createDecreasingRates(NUM_SAMPLES),
|
||||
};
|
||||
|
||||
interface FillDataBySource {
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "3.14.1",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"version": "3.14.0",
|
||||
"changes": [
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v3.14.1 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v3.14.0 - _April 1, 2021_
|
||||
|
||||
* Update artifacts (#164)
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contract-artifacts",
|
||||
"version": "3.14.0",
|
||||
"version": "3.14.1",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -30,7 +30,7 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/packages/contract-artifacts",
|
||||
"devDependencies": {
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@types/mocha": "^5.2.7",
|
||||
"chai": "^4.0.1",
|
||||
"lodash": "^4.17.11",
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contract-wrappers-test",
|
||||
"version": "12.2.41",
|
||||
"version": "12.2.42",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -31,17 +31,17 @@
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/packages/contract-wrappers-test",
|
||||
"devDependencies": {
|
||||
"@0x/contract-wrappers": "^13.15.0",
|
||||
"@0x/contracts-test-utils": "^5.3.24",
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/migrations": "^8.0.2",
|
||||
"@0x/order-utils": "^10.4.19",
|
||||
"@0x/subproviders": "^6.4.1",
|
||||
"@0x/contract-wrappers": "^13.16.0",
|
||||
"@0x/contracts-test-utils": "^5.3.25",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/migrations": "^8.0.3",
|
||||
"@0x/order-utils": "^10.4.20",
|
||||
"@0x/subproviders": "^6.5.2",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@types/nock": "^10.0.3",
|
||||
"chai": "^4.0.1",
|
||||
"dirty-chai": "^2.0.1",
|
||||
|
@@ -1,4 +1,14 @@
|
||||
[
|
||||
{
|
||||
"version": "13.16.0",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Regenerate wrappers with new abi-gen",
|
||||
"pr": 212
|
||||
}
|
||||
],
|
||||
"timestamp": 1619596077
|
||||
},
|
||||
{
|
||||
"version": "13.15.0",
|
||||
"changes": [
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v13.16.0 - _April 28, 2021_
|
||||
|
||||
* Regenerate wrappers with new abi-gen (#212)
|
||||
|
||||
## v13.15.0 - _April 1, 2021_
|
||||
|
||||
* Regenerate wrappers (#164)
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/contract-wrappers",
|
||||
"version": "13.15.0",
|
||||
"version": "13.16.0",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -48,21 +48,21 @@
|
||||
"homepage": "https://github.com/0xProject/protocol/tree/main/packages/contract-wrappers",
|
||||
"devDependencies": {
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"gitpkg": "https://github.com/0xProject/gitpkg.git",
|
||||
"tslint": "5.11.0",
|
||||
"typedoc": "~0.16.11",
|
||||
"typescript": "4.2.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/assert": "^3.0.21",
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/assert": "^3.0.26",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contract-addresses": "^6.0.0",
|
||||
"@0x/json-schemas": "^5.4.1",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"@0x/json-schemas": "^6.1.2",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethers": "~4.0.4"
|
||||
},
|
||||
"publishConfig": {
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -24,9 +25,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -52,11 +54,7 @@ export class BrokerContract extends BaseContract {
|
||||
exchange: string,
|
||||
weth: string,
|
||||
): Promise<BrokerContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -89,11 +87,7 @@ export class BrokerContract extends BaseContract {
|
||||
exchange: string,
|
||||
weth: string,
|
||||
): Promise<BrokerContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -133,11 +127,7 @@ export class BrokerContract extends BaseContract {
|
||||
weth: string,
|
||||
): Promise<BrokerContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[exchange, weth] = BaseContract._formatABIDataItemList(
|
||||
@@ -539,6 +529,9 @@ export class BrokerContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as BrokerContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -645,6 +638,16 @@ export class BrokerContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -777,6 +780,16 @@ export class BrokerContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -867,6 +880,16 @@ export class BrokerContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -895,6 +918,7 @@ export class BrokerContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = BrokerContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'Broker',
|
||||
@@ -904,6 +928,7 @@ export class BrokerContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
BrokerContract.ABI().forEach((item, index) => {
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -24,9 +25,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -53,11 +55,7 @@ export class CoordinatorContract extends BaseContract {
|
||||
exchange: string,
|
||||
chainId: BigNumber,
|
||||
): Promise<CoordinatorContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -90,11 +88,7 @@ export class CoordinatorContract extends BaseContract {
|
||||
exchange: string,
|
||||
chainId: BigNumber,
|
||||
): Promise<CoordinatorContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -134,11 +128,7 @@ export class CoordinatorContract extends BaseContract {
|
||||
chainId: BigNumber,
|
||||
): Promise<CoordinatorContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[exchange, chainId] = BaseContract._formatABIDataItemList(
|
||||
@@ -563,6 +553,9 @@ export class CoordinatorContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as CoordinatorContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -875,6 +868,16 @@ export class CoordinatorContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -967,6 +970,7 @@ export class CoordinatorContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = CoordinatorContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'Coordinator',
|
||||
@@ -976,6 +980,7 @@ export class CoordinatorContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
CoordinatorContract.ABI().forEach((item, index) => {
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -24,9 +25,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -54,11 +56,7 @@ export class DevUtilsContract extends BaseContract {
|
||||
chaiBridge_: string,
|
||||
dydxBridge_: string,
|
||||
): Promise<DevUtilsContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -93,11 +91,7 @@ export class DevUtilsContract extends BaseContract {
|
||||
chaiBridge_: string,
|
||||
dydxBridge_: string,
|
||||
): Promise<DevUtilsContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -139,11 +133,7 @@ export class DevUtilsContract extends BaseContract {
|
||||
dydxBridge_: string,
|
||||
): Promise<DevUtilsContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[exchange_, chaiBridge_, dydxBridge_] = BaseContract._formatABIDataItemList(
|
||||
@@ -1580,6 +1570,9 @@ export class DevUtilsContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as DevUtilsContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -2312,6 +2305,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2367,6 +2370,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2425,6 +2438,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -2483,6 +2506,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber[]> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2538,6 +2571,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber[]> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2596,6 +2639,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -2750,6 +2803,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -2842,6 +2905,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -2934,6 +3007,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<number> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3015,6 +3098,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<number> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3097,6 +3190,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<number[]> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3190,6 +3293,16 @@ export class DevUtilsContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3262,6 +3375,7 @@ export class DevUtilsContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = DevUtilsContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'DevUtils',
|
||||
@@ -3271,6 +3385,7 @@ export class DevUtilsContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
DevUtilsContract.ABI().forEach((item, index) => {
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -26,9 +27,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -72,11 +74,7 @@ export class ERC20TokenContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<ERC20TokenContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -99,11 +97,7 @@ export class ERC20TokenContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<ERC20TokenContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -133,11 +127,7 @@ export class ERC20TokenContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractAbi },
|
||||
): Promise<ERC20TokenContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[] = BaseContract._formatABIDataItemList(constructorAbi.inputs, [], BaseContract._bigNumberToString);
|
||||
@@ -411,6 +401,9 @@ export class ERC20TokenContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as ERC20TokenContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -486,6 +479,16 @@ export class ERC20TokenContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<boolean> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -590,6 +593,16 @@ export class ERC20TokenContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<boolean> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -646,6 +659,16 @@ export class ERC20TokenContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<boolean> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -740,6 +763,7 @@ export class ERC20TokenContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = ERC20TokenContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'ERC20Token',
|
||||
@@ -749,6 +773,7 @@ export class ERC20TokenContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
this._subscriptionManager = new SubscriptionManager<ERC20TokenEventArgs, ERC20TokenEvents>(
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -26,9 +27,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -82,11 +84,7 @@ export class ERC721TokenContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<ERC721TokenContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -109,11 +107,7 @@ export class ERC721TokenContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<ERC721TokenContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -143,11 +137,7 @@ export class ERC721TokenContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractAbi },
|
||||
): Promise<ERC721TokenContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[] = BaseContract._formatABIDataItemList(constructorAbi.inputs, [], BaseContract._bigNumberToString);
|
||||
@@ -501,6 +491,9 @@ export class ERC721TokenContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as ERC721TokenContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -555,6 +548,16 @@ export class ERC721TokenContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -713,6 +716,16 @@ export class ERC721TokenContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -785,6 +798,16 @@ export class ERC721TokenContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -844,6 +867,16 @@ export class ERC721TokenContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -902,6 +935,16 @@ export class ERC721TokenContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1000,6 +1043,7 @@ export class ERC721TokenContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = ERC721TokenContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'ERC721Token',
|
||||
@@ -1009,6 +1053,7 @@ export class ERC721TokenContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
this._subscriptionManager = new SubscriptionManager<ERC721TokenEventArgs, ERC721TokenEvents>(
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -26,9 +27,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -139,11 +141,7 @@ export class ExchangeContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
chainId: BigNumber,
|
||||
): Promise<ExchangeContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -167,11 +165,7 @@ export class ExchangeContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
chainId: BigNumber,
|
||||
): Promise<ExchangeContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -202,11 +196,7 @@ export class ExchangeContract extends BaseContract {
|
||||
chainId: BigNumber,
|
||||
): Promise<ExchangeContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[chainId] = BaseContract._formatABIDataItemList(
|
||||
@@ -3211,6 +3201,9 @@ export class ExchangeContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as ExchangeContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -3341,6 +3334,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3405,6 +3408,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string[]> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3490,6 +3503,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -3594,6 +3617,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -3698,6 +3731,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -3832,6 +3875,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -3990,6 +4043,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4099,6 +4162,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4152,6 +4225,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4243,6 +4326,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4306,6 +4399,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4388,6 +4491,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4485,6 +4598,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4793,6 +4916,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4892,6 +5025,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4990,6 +5133,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -5089,6 +5242,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -5217,6 +5380,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -5372,6 +5545,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -5508,6 +5691,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5622,6 +5815,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5674,6 +5877,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5725,6 +5938,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5779,6 +6002,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5846,6 +6079,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5918,6 +6161,16 @@ export class ExchangeContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6012,6 +6265,7 @@ export class ExchangeContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = ExchangeContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'Exchange',
|
||||
@@ -6021,6 +6275,7 @@ export class ExchangeContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
this._subscriptionManager = new SubscriptionManager<ExchangeEventArgs, ExchangeEvents>(
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -26,9 +27,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -67,11 +69,7 @@ export class ForwarderContract extends BaseContract {
|
||||
_exchangeV2: string,
|
||||
_weth: string,
|
||||
): Promise<ForwarderContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -106,11 +104,7 @@ export class ForwarderContract extends BaseContract {
|
||||
_exchangeV2: string,
|
||||
_weth: string,
|
||||
): Promise<ForwarderContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -152,11 +146,7 @@ export class ForwarderContract extends BaseContract {
|
||||
_weth: string,
|
||||
): Promise<ForwarderContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[_exchange, _exchangeV2, _weth] = BaseContract._formatABIDataItemList(
|
||||
@@ -763,6 +753,9 @@ export class ForwarderContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as ForwarderContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -877,6 +870,16 @@ export class ForwarderContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -964,6 +967,16 @@ export class ForwarderContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -1058,6 +1071,16 @@ export class ForwarderContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -1149,6 +1172,16 @@ export class ForwarderContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -1223,6 +1256,16 @@ export class ForwarderContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1295,6 +1338,16 @@ export class ForwarderContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1372,6 +1425,16 @@ export class ForwarderContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1426,6 +1489,16 @@ export class ForwarderContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1520,6 +1593,7 @@ export class ForwarderContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = ForwarderContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'Forwarder',
|
||||
@@ -1529,6 +1603,7 @@ export class ForwarderContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
this._subscriptionManager = new SubscriptionManager<ForwarderEventArgs, ForwarderEvents>(
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -24,9 +25,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -51,11 +53,7 @@ export class GodsUnchainedValidatorContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
_godsUnchained: string,
|
||||
): Promise<GodsUnchainedValidatorContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -86,11 +84,7 @@ export class GodsUnchainedValidatorContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
_godsUnchained: string,
|
||||
): Promise<GodsUnchainedValidatorContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -128,11 +122,7 @@ export class GodsUnchainedValidatorContract extends BaseContract {
|
||||
_godsUnchained: string,
|
||||
): Promise<GodsUnchainedValidatorContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[_godsUnchained] = BaseContract._formatABIDataItemList(
|
||||
@@ -265,6 +255,9 @@ export class GodsUnchainedValidatorContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as GodsUnchainedValidatorContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -315,6 +308,7 @@ export class GodsUnchainedValidatorContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = GodsUnchainedValidatorContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'GodsUnchainedValidator',
|
||||
@@ -324,6 +318,7 @@ export class GodsUnchainedValidatorContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
GodsUnchainedValidatorContract.ABI().forEach((item, index) => {
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -24,9 +25,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -50,11 +52,7 @@ export class IAssetDataContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<IAssetDataContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -77,11 +75,7 @@ export class IAssetDataContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<IAssetDataContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -111,11 +105,7 @@ export class IAssetDataContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractAbi },
|
||||
): Promise<IAssetDataContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[] = BaseContract._formatABIDataItemList(constructorAbi.inputs, [], BaseContract._bigNumberToString);
|
||||
@@ -334,6 +324,9 @@ export class IAssetDataContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as IAssetDataContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -398,6 +391,16 @@ export class IAssetDataContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -458,6 +461,16 @@ export class IAssetDataContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -513,6 +526,16 @@ export class IAssetDataContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -566,6 +589,16 @@ export class IAssetDataContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -622,6 +655,16 @@ export class IAssetDataContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -683,6 +726,16 @@ export class IAssetDataContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -709,6 +762,7 @@ export class IAssetDataContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = IAssetDataContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'IAssetData',
|
||||
@@ -718,6 +772,7 @@ export class IAssetDataContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
IAssetDataContract.ABI().forEach((item, index) => {
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -24,9 +25,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -50,11 +52,7 @@ export class ILiquidityProviderContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<ILiquidityProviderContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -83,11 +81,7 @@ export class ILiquidityProviderContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<ILiquidityProviderContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -123,11 +117,7 @@ export class ILiquidityProviderContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractAbi },
|
||||
): Promise<ILiquidityProviderContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[] = BaseContract._formatABIDataItemList(constructorAbi.inputs, [], BaseContract._bigNumberToString);
|
||||
@@ -315,6 +305,9 @@ export class ILiquidityProviderContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as ILiquidityProviderContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -380,6 +373,16 @@ export class ILiquidityProviderContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -478,6 +481,7 @@ export class ILiquidityProviderContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = ILiquidityProviderContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'ILiquidityProvider',
|
||||
@@ -487,6 +491,7 @@ export class ILiquidityProviderContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
ILiquidityProviderContract.ABI().forEach((item, index) => {
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -26,9 +27,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -80,11 +82,7 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<ITransformERC20Contract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -107,11 +105,7 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<ITransformERC20Contract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -141,11 +135,7 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractAbi },
|
||||
): Promise<ITransformERC20Contract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[] = BaseContract._formatABIDataItemList(constructorAbi.inputs, [], BaseContract._bigNumberToString);
|
||||
@@ -479,6 +469,9 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as ITransformERC20Contract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -539,6 +532,16 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -590,6 +593,16 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -639,6 +652,16 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -689,6 +712,16 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -738,6 +771,16 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -790,6 +833,16 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -843,6 +896,16 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -913,6 +976,16 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1013,6 +1086,7 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = ITransformERC20Contract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'ITransformERC20',
|
||||
@@ -1022,6 +1096,7 @@ export class ITransformERC20Contract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
this._subscriptionManager = new SubscriptionManager<ITransformERC20EventArgs, ITransformERC20Events>(
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -26,9 +27,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -193,11 +195,7 @@ export class IZeroExContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<IZeroExContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -220,11 +218,7 @@ export class IZeroExContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<IZeroExContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -254,11 +248,7 @@ export class IZeroExContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractAbi },
|
||||
): Promise<IZeroExContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[] = BaseContract._formatABIDataItemList(constructorAbi.inputs, [], BaseContract._bigNumberToString);
|
||||
@@ -3369,6 +3359,9 @@ export class IZeroExContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as IZeroExContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -3448,6 +3441,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -3530,6 +3533,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -3596,6 +3609,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3664,6 +3687,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3726,6 +3759,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3788,6 +3831,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3854,6 +3907,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3922,6 +3985,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string[]> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3988,6 +4061,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4065,6 +4148,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4148,6 +4241,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4230,6 +4333,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4317,6 +4430,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4398,6 +4521,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4460,6 +4593,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4526,6 +4669,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4594,6 +4747,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4645,6 +4808,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4712,6 +4885,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4765,6 +4948,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4839,6 +5032,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -4917,6 +5120,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -4988,6 +5201,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5060,6 +5283,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -5128,6 +5361,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5193,6 +5436,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -5272,6 +5525,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -5340,6 +5603,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5403,6 +5676,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5454,6 +5737,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5504,6 +5797,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<number> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5553,6 +5856,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5616,6 +5929,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5679,6 +6002,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -5756,6 +6089,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(
|
||||
callData: Partial<CallData> = {},
|
||||
defaultBlock?: BlockParam,
|
||||
@@ -5814,6 +6157,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5865,6 +6218,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5915,6 +6278,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -5964,6 +6337,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6023,6 +6406,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6088,6 +6481,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6137,6 +6540,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6191,6 +6604,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6244,6 +6667,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6319,6 +6752,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6389,6 +6832,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6451,6 +6904,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6503,6 +6966,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6556,6 +7029,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6607,6 +7090,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6659,6 +7152,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6729,6 +7232,16 @@ export class IZeroExContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -6829,6 +7342,7 @@ export class IZeroExContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = IZeroExContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'IZeroEx',
|
||||
@@ -6838,6 +7352,7 @@ export class IZeroExContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
this._subscriptionManager = new SubscriptionManager<IZeroExEventArgs, IZeroExEvents>(
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -24,9 +25,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -50,11 +52,7 @@ export class MaximumGasPriceContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<MaximumGasPriceContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -77,11 +75,7 @@ export class MaximumGasPriceContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<MaximumGasPriceContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -111,11 +105,7 @@ export class MaximumGasPriceContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractAbi },
|
||||
): Promise<MaximumGasPriceContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[] = BaseContract._formatABIDataItemList(constructorAbi.inputs, [], BaseContract._bigNumberToString);
|
||||
@@ -237,6 +227,9 @@ export class MaximumGasPriceContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as MaximumGasPriceContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -309,6 +302,7 @@ export class MaximumGasPriceContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = MaximumGasPriceContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'MaximumGasPrice',
|
||||
@@ -318,6 +312,7 @@ export class MaximumGasPriceContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
MaximumGasPriceContract.ABI().forEach((item, index) => {
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -26,9 +27,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -183,11 +185,7 @@ export class StakingContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<StakingContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -210,11 +208,7 @@ export class StakingContract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<StakingContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -244,11 +238,7 @@ export class StakingContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractAbi },
|
||||
): Promise<StakingContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[] = BaseContract._formatABIDataItemList(constructorAbi.inputs, [], BaseContract._bigNumberToString);
|
||||
@@ -1680,6 +1670,9 @@ export class StakingContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as StakingContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -1730,6 +1723,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1781,6 +1784,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2003,6 +2016,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2100,6 +2123,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2152,6 +2185,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<BigNumber> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2227,6 +2270,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2643,6 +2696,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2694,6 +2757,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2794,6 +2867,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2876,6 +2959,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -2980,6 +3073,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3033,6 +3136,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3084,6 +3197,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3193,6 +3316,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3251,6 +3384,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3322,6 +3465,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3375,6 +3528,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3468,6 +3631,16 @@ export class StakingContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -3562,6 +3735,7 @@ export class StakingContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = StakingContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'Staking',
|
||||
@@ -3571,6 +3745,7 @@ export class StakingContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
this._subscriptionManager = new SubscriptionManager<StakingEventArgs, StakingEvents>(
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -26,9 +27,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -90,11 +92,7 @@ export class StakingProxyContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
_stakingContract: string,
|
||||
): Promise<StakingProxyContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -125,11 +123,7 @@ export class StakingProxyContract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
_stakingContract: string,
|
||||
): Promise<StakingProxyContract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -167,11 +161,7 @@ export class StakingProxyContract extends BaseContract {
|
||||
_stakingContract: string,
|
||||
): Promise<StakingProxyContract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[_stakingContract] = BaseContract._formatABIDataItemList(
|
||||
@@ -807,6 +797,9 @@ export class StakingProxyContract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as StakingProxyContract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -857,6 +850,16 @@ export class StakingProxyContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -959,6 +962,16 @@ export class StakingProxyContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1053,6 +1066,16 @@ export class StakingProxyContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<string[]> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1182,6 +1205,16 @@ export class StakingProxyContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1386,6 +1419,16 @@ export class StakingProxyContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1439,6 +1482,16 @@ export class StakingProxyContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1551,6 +1604,16 @@ export class StakingProxyContract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -1686,6 +1749,7 @@ export class StakingProxyContract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = StakingProxyContract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'StakingProxy',
|
||||
@@ -1695,6 +1759,7 @@ export class StakingProxyContract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
this._subscriptionManager = new SubscriptionManager<StakingProxyEventArgs, StakingProxyEvents>(
|
||||
|
@@ -3,6 +3,7 @@
|
||||
// tslint:disable:no-unused-variable
|
||||
import {
|
||||
AwaitTransactionSuccessOpts,
|
||||
EncoderOverrides,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
SendTransactionOpts,
|
||||
@@ -26,9 +27,10 @@ import {
|
||||
TransactionReceiptWithDecodedLogs,
|
||||
TxData,
|
||||
TxDataPayable,
|
||||
TxAccessListWithGas,
|
||||
SupportedProvider,
|
||||
} from 'ethereum-types';
|
||||
import { BigNumber, classUtils, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { AbiEncoder, BigNumber, classUtils, EncodingRules, hexUtils, logUtils, providerUtils } from '@0x/utils';
|
||||
import { EventCallback, IndexedFilterValues, SimpleContractArtifact } from '@0x/types';
|
||||
import { Web3Wrapper } from '@0x/web3-wrapper';
|
||||
import { assert } from '@0x/assert';
|
||||
@@ -88,11 +90,7 @@ export class WETH9Contract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<WETH9Contract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -115,11 +113,7 @@ export class WETH9Contract extends BaseContract {
|
||||
txDefaults: Partial<TxData>,
|
||||
logDecodeDependencies: { [contractName: string]: ContractArtifact | SimpleContractArtifact },
|
||||
): Promise<WETH9Contract> {
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
if (artifact.compilerOutput === undefined) {
|
||||
throw new Error('Compiler output not found in the artifact file');
|
||||
}
|
||||
@@ -149,11 +143,7 @@ export class WETH9Contract extends BaseContract {
|
||||
logDecodeDependencies: { [contractName: string]: ContractAbi },
|
||||
): Promise<WETH9Contract> {
|
||||
assert.isHexString('bytecode', bytecode);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema, [
|
||||
schemas.addressSchema,
|
||||
schemas.numberSchema,
|
||||
schemas.jsNumber,
|
||||
]);
|
||||
assert.doesConformToSchema('txDefaults', txDefaults, schemas.txDataSchema);
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
const constructorAbi = BaseContract._lookupConstructorAbi(abi);
|
||||
[] = BaseContract._formatABIDataItemList(constructorAbi.inputs, [], BaseContract._bigNumberToString);
|
||||
@@ -535,6 +525,9 @@ export class WETH9Contract extends BaseContract {
|
||||
}
|
||||
|
||||
public getABIDecodedReturnData<T>(methodName: string, callData: string): T {
|
||||
if (this._encoderOverrides.decodeOutput) {
|
||||
return this._encoderOverrides.decodeOutput(methodName, callData);
|
||||
}
|
||||
const functionSignature = this.getFunctionSignature(methodName);
|
||||
const self = (this as any) as WETH9Contract;
|
||||
const abiEncoder = self._lookupAbiEncoder(functionSignature);
|
||||
@@ -604,6 +597,16 @@ export class WETH9Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<boolean> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -691,6 +694,16 @@ export class WETH9Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -799,6 +812,16 @@ export class WETH9Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<boolean> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -848,6 +871,16 @@ export class WETH9Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<boolean> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -895,6 +928,16 @@ export class WETH9Contract extends BaseContract {
|
||||
});
|
||||
return self._web3Wrapper.estimateGasAsync(txDataWithDefaults);
|
||||
},
|
||||
async createAccessListAsync(
|
||||
txData?: Partial<TxData> | undefined,
|
||||
defaultBlock?: BlockParam,
|
||||
): Promise<TxAccessListWithGas> {
|
||||
const txDataWithDefaults = await self._applyDefaultsToTxDataAsync({
|
||||
data: this.getABIEncodedTransactionData(),
|
||||
...txData,
|
||||
});
|
||||
return self._web3Wrapper.createAccessListAsync(txDataWithDefaults, defaultBlock);
|
||||
},
|
||||
async callAsync(callData: Partial<CallData> = {}, defaultBlock?: BlockParam): Promise<void> {
|
||||
BaseContract._assertCallParams(callData, defaultBlock);
|
||||
const rawCallResult = await self._performCallAsync(
|
||||
@@ -989,6 +1032,7 @@ export class WETH9Contract extends BaseContract {
|
||||
txDefaults?: Partial<TxData>,
|
||||
logDecodeDependencies?: { [contractName: string]: ContractAbi },
|
||||
deployedBytecode: string | undefined = WETH9Contract.deployedBytecode,
|
||||
encoderOverrides?: Partial<EncoderOverrides>,
|
||||
) {
|
||||
super(
|
||||
'WETH9',
|
||||
@@ -998,6 +1042,7 @@ export class WETH9Contract extends BaseContract {
|
||||
txDefaults,
|
||||
logDecodeDependencies,
|
||||
deployedBytecode,
|
||||
encoderOverrides,
|
||||
);
|
||||
classUtils.bindAll(this, ['_abiEncoderByFunctionSignature', 'address', '_web3Wrapper']);
|
||||
this._subscriptionManager = new SubscriptionManager<WETH9EventArgs, WETH9Events>(
|
||||
|
@@ -3,6 +3,7 @@ export {
|
||||
ContractEvent,
|
||||
ContractFunctionObj,
|
||||
ContractTxFunctionObj,
|
||||
EncoderOverrides,
|
||||
SendTransactionOpts,
|
||||
SubscriptionErrors,
|
||||
} from '@0x/base-contract';
|
||||
@@ -16,7 +17,7 @@ export {
|
||||
SimpleEvmOutput,
|
||||
SimpleStandardContractOutput,
|
||||
} from '@0x/types';
|
||||
export { AbiDecoder, DecodedCalldata } from '@0x/utils';
|
||||
export { AbiDecoder, AbiEncoder, DecodedCalldata, EncodingRules } from '@0x/utils';
|
||||
export {
|
||||
AbiDefinition,
|
||||
BlockParam,
|
||||
|
@@ -1,4 +1,13 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1619596077,
|
||||
"version": "8.0.3",
|
||||
"changes": [
|
||||
{
|
||||
"note": "Dependencies updated"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"timestamp": 1619481586,
|
||||
"version": "8.0.2",
|
||||
|
@@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only.
|
||||
|
||||
CHANGELOG
|
||||
|
||||
## v8.0.3 - _April 28, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
||||
## v8.0.2 - _April 26, 2021_
|
||||
|
||||
* Dependencies updated
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@0x/migrations",
|
||||
"version": "8.0.2",
|
||||
"version": "8.0.3",
|
||||
"engines": {
|
||||
"node": ">=6.12"
|
||||
},
|
||||
@@ -48,10 +48,10 @@
|
||||
"registry": "git@github.com:0xProject/gitpkg-registry.git"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@0x/dev-utils": "^4.2.1",
|
||||
"@0x/dev-utils": "^4.2.6",
|
||||
"@0x/ts-doc-gen": "^0.0.28",
|
||||
"@0x/tslint-config": "^4.1.3",
|
||||
"@0x/types": "^3.3.1",
|
||||
"@0x/tslint-config": "^4.1.4",
|
||||
"@0x/types": "^3.3.3",
|
||||
"@types/yargs": "^11.0.0",
|
||||
"chai": "^4.0.1",
|
||||
"dirty-chai": "^2.0.1",
|
||||
@@ -67,29 +67,29 @@
|
||||
"yargs": "^10.0.3"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/base-contract": "^6.2.18",
|
||||
"@0x/base-contract": "^6.3.2",
|
||||
"@0x/contract-addresses": "^6.0.0",
|
||||
"@0x/contracts-asset-proxy": "^3.7.9",
|
||||
"@0x/contracts-coordinator": "^3.1.28",
|
||||
"@0x/contracts-dev-utils": "^1.3.26",
|
||||
"@0x/contracts-erc1155": "^2.1.27",
|
||||
"@0x/contracts-erc20": "^3.3.6",
|
||||
"@0x/contracts-erc721": "^3.1.27",
|
||||
"@0x/contracts-exchange": "^3.2.28",
|
||||
"@0x/contracts-exchange-forwarder": "^4.2.28",
|
||||
"@0x/contracts-extensions": "^6.2.22",
|
||||
"@0x/contracts-multisig": "^4.1.28",
|
||||
"@0x/contracts-staking": "^2.0.35",
|
||||
"@0x/contracts-utils": "^4.7.6",
|
||||
"@0x/contracts-zero-ex": "^0.22.0",
|
||||
"@0x/sol-compiler": "^4.6.1",
|
||||
"@0x/subproviders": "^6.4.1",
|
||||
"@0x/typescript-typings": "^5.1.6",
|
||||
"@0x/utils": "^6.2.0",
|
||||
"@0x/web3-wrapper": "^7.4.1",
|
||||
"@0x/contracts-asset-proxy": "^3.7.10",
|
||||
"@0x/contracts-coordinator": "^3.1.29",
|
||||
"@0x/contracts-dev-utils": "^1.3.27",
|
||||
"@0x/contracts-erc1155": "^2.1.28",
|
||||
"@0x/contracts-erc20": "^3.3.7",
|
||||
"@0x/contracts-erc721": "^3.1.28",
|
||||
"@0x/contracts-exchange": "^3.2.29",
|
||||
"@0x/contracts-exchange-forwarder": "^4.2.29",
|
||||
"@0x/contracts-extensions": "^6.2.23",
|
||||
"@0x/contracts-multisig": "^4.1.29",
|
||||
"@0x/contracts-staking": "^2.0.36",
|
||||
"@0x/contracts-utils": "^4.7.7",
|
||||
"@0x/contracts-zero-ex": "^0.22.1",
|
||||
"@0x/sol-compiler": "^4.7.2",
|
||||
"@0x/subproviders": "^6.5.2",
|
||||
"@0x/typescript-typings": "^5.2.0",
|
||||
"@0x/utils": "^6.4.2",
|
||||
"@0x/web3-wrapper": "^7.5.2",
|
||||
"@ledgerhq/hw-app-eth": "^4.3.0",
|
||||
"@types/web3-provider-engine": "^14.0.0",
|
||||
"ethereum-types": "^3.4.0",
|
||||
"ethereum-types": "^3.5.0",
|
||||
"ethers": "~4.0.4",
|
||||
"lodash": "^4.17.11"
|
||||
},
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user