Skip to content

Commit

Permalink
Update SmartTransactionsController to v3 (#16511)
Browse files Browse the repository at this point in the history
This update drops support for Node.js v12, and it includes a bug fix
for a deadlock encountered when using swaps on unsupported testnets.

Fixes #16479
  • Loading branch information
Gudahtt authored and seaona committed Nov 16, 2022
1 parent f754d81 commit 2bc4408
Show file tree
Hide file tree
Showing 5 changed files with 68 additions and 551 deletions.
168 changes: 17 additions & 151 deletions lavamoat/browserify/beta/policy.json
Original file line number Diff line number Diff line change
Expand Up @@ -250,13 +250,27 @@
"packages": {
"@ethereumjs/tx": true,
"@keystonehq/bc-ur-registry-eth": true,
"@keystonehq/bc-ur-registry-eth>hdkey": true,
"@keystonehq/metamask-airgapped-keyring>@keystonehq/base-eth-keyring>hdkey": true,
"@keystonehq/metamask-airgapped-keyring>@keystonehq/base-eth-keyring>rlp": true,
"browserify>buffer": true,
"eth-lattice-keyring>@ethereumjs/util": true,
"uuid": true
}
},
"@keystonehq/metamask-airgapped-keyring>@keystonehq/base-eth-keyring>hdkey": {
"packages": {
"@keystonehq/metamask-airgapped-keyring>@keystonehq/base-eth-keyring>hdkey>secp256k1": true,
"browserify>assert": true,
"browserify>crypto-browserify": true,
"ethereumjs-wallet>bs58check": true,
"ethereumjs-wallet>safe-buffer": true
}
},
"@keystonehq/metamask-airgapped-keyring>@keystonehq/base-eth-keyring>hdkey>secp256k1": {
"packages": {
"ethers>@ethersproject/signing-key>elliptic": true
}
},
"@keystonehq/metamask-airgapped-keyring>@keystonehq/base-eth-keyring>rlp": {
"globals": {
"TextEncoder": true
Expand Down Expand Up @@ -999,9 +1013,9 @@
"packages": {
"@ethereumjs/tx": true,
"@metamask/eth-ledger-bridge-keyring>eth-sig-util": true,
"@metamask/eth-ledger-bridge-keyring>hdkey": true,
"browserify>buffer": true,
"browserify>events": true,
"eth-trezor-keyring>hdkey": true,
"ethereumjs-util": true
}
},
Expand Down Expand Up @@ -1034,25 +1048,6 @@
"ethjs>ethjs-util>strip-hex-prefix": true
}
},
"@metamask/eth-ledger-bridge-keyring>hdkey": {
"packages": {
"@metamask/eth-ledger-bridge-keyring>hdkey>secp256k1": true,
"browserify>assert": true,
"browserify>crypto-browserify": true,
"eth-trezor-keyring>hdkey>coinstring": true,
"ethereumjs-wallet>safe-buffer": true
}
},
"@metamask/eth-ledger-bridge-keyring>hdkey>secp256k1": {
"packages": {
"bn.js": true,
"browserify>insert-module-globals>is-buffer": true,
"eth-trezor-keyring>hdkey>secp256k1>bip66": true,
"ethereumjs-util>create-hash": true,
"ethereumjs-wallet>safe-buffer": true,
"ethers>@ethersproject/signing-key>elliptic": true
}
},
"@metamask/eth-token-tracker": {
"globals": {
"console.warn": true
Expand Down Expand Up @@ -1243,143 +1238,14 @@
"packages": {
"@ethersproject/bignumber": true,
"@ethersproject/bignumber>@ethersproject/bytes": true,
"@metamask/controllers": true,
"@metamask/controllers>@ethersproject/providers": true,
"@metamask/controllers>isomorphic-fetch": true,
"@metamask/smart-transactions-controller>@metamask/controllers": true,
"@metamask/smart-transactions-controller>bignumber.js": true,
"@metamask/smart-transactions-controller>fast-json-patch": true,
"lodash": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers": {
"globals": {
"Headers": true,
"URL": true,
"clearInterval": true,
"clearTimeout": true,
"console.error": true,
"console.log": true,
"fetch": true,
"setInterval": true,
"setTimeout": true
},
"packages": {
"@ethereumjs/common": true,
"@ethereumjs/tx": true,
"@metamask/contract-metadata": true,
"@metamask/controllers>abort-controller": true,
"@metamask/controllers>async-mutex": true,
"@metamask/controllers>eth-json-rpc-infura": true,
"@metamask/controllers>eth-phishing-detect": true,
"@metamask/controllers>isomorphic-fetch": true,
"@metamask/controllers>multiformats": true,
"@metamask/controllers>web3": true,
"@metamask/controllers>web3-provider-engine": true,
"@metamask/metamask-eth-abis": true,
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry": true,
"@metamask/smart-transactions-controller>@metamask/controllers>ethereumjs-wallet": true,
"@metamask/smart-transactions-controller>@metamask/controllers>nanoid": true,
"browserify>buffer": true,
"browserify>events": true,
"deep-freeze-strict": true,
"eslint>fast-deep-equal": true,
"eth-ens-namehash": true,
"eth-keyring-controller": true,
"eth-query": true,
"eth-rpc-errors": true,
"eth-sig-util": true,
"ethereumjs-util": true,
"ethers": true,
"ethjs>ethjs-unit": true,
"immer": true,
"json-rpc-engine": true,
"jsonschema": true,
"punycode": true,
"single-call-balance-checker-abi": true,
"uuid": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry": {
"packages": {
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs": {
"globals": {
"clearInterval": true,
"setInterval": true
},
"packages": {
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>bn.js": true,
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>ethjs-abi": true,
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>ethjs-contract": true,
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>ethjs-query": true,
"browserify>buffer": true,
"ethjs>ethjs-filter": true,
"ethjs>ethjs-provider-http": true,
"ethjs>ethjs-unit": true,
"ethjs>ethjs-util": true,
"ethjs>js-sha3": true,
"ethjs>number-to-bn": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>ethjs-abi": {
"packages": {
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>bn.js": true,
"browserify>buffer": true,
"ethjs>js-sha3": true,
"ethjs>number-to-bn": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>ethjs-contract": {
"packages": {
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>ethjs-contract>ethjs-abi": true,
"ethjs-query>babel-runtime": true,
"ethjs>ethjs-filter": true,
"ethjs>ethjs-util": true,
"ethjs>js-sha3": true,
"promise-to-callback": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>ethjs-contract>ethjs-abi": {
"packages": {
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>bn.js": true,
"browserify>buffer": true,
"ethjs>js-sha3": true,
"ethjs>number-to-bn": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers>eth-method-registry>ethjs>ethjs-query": {
"globals": {
"console": true
},
"packages": {
"ethjs-query>babel-runtime": true,
"ethjs-query>ethjs-format": true,
"ethjs-query>ethjs-rpc": true,
"promise-to-callback": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers>ethereumjs-wallet": {
"packages": {
"@metamask/smart-transactions-controller>@metamask/controllers>ethereumjs-wallet>uuid": true,
"@truffle/codec>utf8": true,
"browserify>buffer": true,
"browserify>crypto-browserify": true,
"ethereumjs-util": true,
"ethereumjs-util>ethereum-cryptography": true,
"ethereumjs-wallet>aes-js": true,
"ethereumjs-wallet>bs58check": true,
"ethereumjs-wallet>randombytes": true,
"ethers>@ethersproject/json-wallets>scrypt-js": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers>ethereumjs-wallet>uuid": {
"globals": {
"crypto": true,
"msCrypto": true
}
},
"@metamask/smart-transactions-controller>@metamask/controllers>nanoid": {
"globals": {
"crypto.getRandomValues": true
Expand Down
Loading

0 comments on commit 2bc4408

Please sign in to comment.