This repository was archived by the owner on Mar 13, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Is there a companion PR from upstream? |
Not exactly. There is a merged pr in upstream polkadot-evm/frontier#380. Since there are some subtle differences between darwinia-evm and upstream evm pallet, so I upgraded this pallet by myself following guidelines. |
hackfisher
approved these changes
Jun 1, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Runtimes are using the same pallet prefix "EVM".
LGTM
@AurevoirXavier Please help review this pull request |
aurexav
approved these changes
Jun 7, 2021
44aeb7f
to
2ae8375
Compare
Merged
14 tasks
11 tasks
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The old version metadata:
$ subsee -p EVM > evm_old.json {"name":"EVM","storage":{"prefix":"EVM","entries":[{"name":"AccountCodes","modifier":"Default","ty":{"Map":{"hasher":"Blake2_128Concat","key":"H160","value":"Vec<u8>","unused":false}},"default":[0],"documentation":[]},{"name":"AccountStorages","modifier":"Default","ty":{"DoubleMap":{"hasher":"Blake2_128Concat","key1":"H160","key2":"H256","value":"H256","key2_hasher":"Blake2_128Concat"}},"default":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"documentation":[]}]},"calls":[{"name":"call","arguments":[{"name":"source","ty":"H160"},{"name":"target","ty":"H160"},{"name":"input","ty":"Vec<u8>"},{"name":"value","ty":"U256"},{"name":"gas_limit","ty":"u64"},{"name":"gas_price","ty":"U256"},{"name":"nonce","ty":"Option<U256>"}],"documentation":[" Issue an EVM call operation. This is similar to a message call transaction in Ethereum."]},{"name":"create","arguments":[{"name":"source","ty":"H160"},{"name":"init","ty":"Vec<u8>"},{"name":"value","ty":"U256"},{"name":"gas_limit","ty":"u64"},{"name":"gas_price","ty":"U256"},{"name":"nonce","ty":"Option<U256>"}],"documentation":[" Issue an EVM create operation. This is similar to a contract creation transaction in"," Ethereum."]},{"name":"create2","arguments":[{"name":"source","ty":"H160"},{"name":"init","ty":"Vec<u8>"},{"name":"salt","ty":"H256"},{"name":"value","ty":"U256"},{"name":"gas_limit","ty":"u64"},{"name":"gas_price","ty":"U256"},{"name":"nonce","ty":"Option<U256>"}],"documentation":[" Issue an EVM create2 operation."]}],"event":[{"name":"Log","arguments":["Log"],"documentation":[" Ethereum events from contracts."]},{"name":"Created","arguments":["H160"],"documentation":[" A contract has been created at given \\[address\\]."]},{"name":"CreatedFailed","arguments":["H160"],"documentation":[" A \\[contract\\] was attempted to be created, but the execution failed."]},{"name":"Executed","arguments":["H160"],"documentation":[" A \\[contract\\] has been executed successfully with states applied."]},{"name":"ExecutedFailed","arguments":["H160"],"documentation":[" A \\[contract\\] has been executed with errors. States are reverted with only gas fees applied."]},{"name":"BalanceDeposit","arguments":["AccountId","H160","U256"],"documentation":[" A deposit has been made at a given address. \\[sender, address, value\\]"]},{"name":"BalanceWithdraw","arguments":["AccountId","H160","U256"],"documentation":[" A withdrawal has been made from a given address. \\[sender, address, value\\]"]}],"constants":[],"errors":[{"name":"BalanceLow","documentation":[" Not enough balance to perform action"]},{"name":"FeeOverflow","documentation":[" Calculating total fee overflowed"]},{"name":"PaymentOverflow","documentation":[" Calculating total payment overflowed"]},{"name":"WithdrawFailed","documentation":[" Withdraw fee failed"]},{"name":"GasPriceTooLow","documentation":[" Gas price is too low."]},{"name":"InvalidNonce","documentation":[" Nonce is invalid"]}],"index":40}
the new version metadata after upgrade:
$ subsee -p EVM > evm_new.json {"name":"EVM","storage":{"prefix":"EVM","entries":[{"name":"AccountCodes","modifier":"Default","ty":{"Map":{"hasher":"Blake2_128Concat","key":"H160","value":"Vec<u8>","unused":false}},"default":[0],"documentation":[]},{"name":"AccountStorages","modifier":"Default","ty":{"DoubleMap":{"hasher":"Blake2_128Concat","key1":"H160","key2":"H256","value":"H256","key2_hasher":"Blake2_128Concat"}},"default":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"documentation":[]}]},"calls":[{"name":"call","arguments":[{"name":"source","ty":"H160"},{"name":"target","ty":"H160"},{"name":"input","ty":"Vec<u8>"},{"name":"value","ty":"U256"},{"name":"gas_limit","ty":"u64"},{"name":"gas_price","ty":"U256"},{"name":"nonce","ty":"Option<U256>"}],"documentation":[" Issue an EVM call operation. This is similar to a message call transaction in Ethereum."]},{"name":"create","arguments":[{"name":"source","ty":"H160"},{"name":"init","ty":"Vec<u8>"},{"name":"value","ty":"U256"},{"name":"gas_limit","ty":"u64"},{"name":"gas_price","ty":"U256"},{"name":"nonce","ty":"Option<U256>"}],"documentation":[" Issue an EVM create operation. This is similar to a contract creation transaction in"," Ethereum."]},{"name":"create2","arguments":[{"name":"source","ty":"H160"},{"name":"init","ty":"Vec<u8>"},{"name":"salt","ty":"H256"},{"name":"value","ty":"U256"},{"name":"gas_limit","ty":"u64"},{"name":"gas_price","ty":"U256"},{"name":"nonce","ty":"Option<U256>"}],"documentation":[" Issue an EVM create2 operation."]}],"event":[{"name":"Log","arguments":["Log"],"documentation":[" Ethereum events from contracts."]},{"name":"Created","arguments":["H160"],"documentation":[" A contract has been created at given \\[address\\]."]},{"name":"CreatedFailed","arguments":["H160"],"documentation":[" A \\[contract\\] was attempted to be created, but the execution failed."]},{"name":"Executed","arguments":["H160"],"documentation":[" A \\[contract\\] has been executed successfully with states applied."]},{"name":"ExecutedFailed","arguments":["H160"],"documentation":[" A \\[contract\\] has been executed with errors. States are reverted with only gas fees applied."]},{"name":"BalanceDeposit","arguments":["AccountId","H160","U256"],"documentation":[" A deposit has been made at a given address. \\[sender, address, value\\]"]},{"name":"BalanceWithdraw","arguments":["AccountId","H160","U256"],"documentation":[" A withdrawal has been made from a given address. \\[sender, address, value\\]"]}],"constants":[],"errors":[{"name":"BalanceLow","documentation":[" Not enough balance to perform action"]},{"name":"FeeOverflow","documentation":[" Calculating total fee overflowed"]},{"name":"PaymentOverflow","documentation":[" Calculating total payment overflowed"]},{"name":"WithdrawFailed","documentation":[" Withdraw fee failed"]},{"name":"GasPriceTooLow","documentation":[" Gas price is too low."]},{"name":"InvalidNonce","documentation":[" Nonce is invalid"]}],"index":40}