yihuang
3b0fa63832
evm: clear access list for each transaction ( #802 )
...
* Clear access list for each transaction
Closes : #801
* changelog
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-30 12:36:10 +01:00
yihuang
e6d0eff957
evm: ForEachStorage
semantic not compatible with go-ethereum ( #798 )
...
* Problem: ForEachStorage sematic not compatible with go-ethereum
Solution:
- reversed the semantic of return value of the callback function.
* changelog
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-30 10:34:33 +00:00
Federico Kunze Küllmer
5d2798aa7e
docs: re-license to LGPLv3 ( #800 )
...
* docs: re-license to LGPLv3
* changelog
2021-11-30 09:22:21 +01:00
Federico Kunze Küllmer
841c93cd65
feat: store migration setup ( #794 )
...
* feat: store migration setup
* comment
* changelog
2021-11-29 16:46:20 +01:00
crypto-facs
bfe059e43e
Fix get block ( #781 )
2021-11-26 18:10:40 +00:00
yihuang
c8d4d3f9a3
fix: improve error message in SendTransaction
json-rpc api ( #786 )
...
* fix error message in `SendTransaction` json-rpc api
Closes : #785
Solution:
- Remove `stacktrace.Propagate`s, and recover error message in jsonrpc server
changelog
fix error messages
* Update x/evm/keeper/msg_server.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-26 15:19:28 +01:00
yihuang
32eaec8d99
fix: web3 rpc api returns wrong block gas limit ( #782 )
...
* Problem: web3 rpc api returns wrong block gas limit
Closes : #777
Solution:
- pass in specific block height to the query
* Apply suggestions from code review
* changelog
2021-11-25 11:30:03 +00:00
Federico Kunze Küllmer
16db5cabb5
ci: enable backport for v0.8 and v0.7 ( #784 )
...
* ci: enable backport for v0.8 and v0.7
* changelog
2021-11-25 11:06:30 +00:00
Daniel Burckhardt
2bf2b6758b
fix: RPC tests fail if FeeMarket BaseFee
is enabled by default ( #770 )
...
* Fix(FeeMarket): Enable FeeMarkat BaseFee
* fix rpc tests
* changelog
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Co-authored-by: Freddy Caceres <freddy.caceres@crypto.com>
Co-authored-by: Federico Kunze Küllmer <federico.kunze94@gmail.com>
2021-11-23 15:00:25 +00:00
Federico Kunze Küllmer
be8fd869ff
rpc: fix default signer ( #769 )
...
* rpc: fix default signer
* changelog
2021-11-22 16:39:25 +01:00
Federico Kunze Küllmer
d6a6bb5c9d
docs: update changelog ( #765 )
2021-11-19 01:17:53 +01:00
Jongwhan Lee
392d1dd8cf
rpc: eth_feeHistory
( #734 )
...
* Problem: missing json rpc of eth_feeHistory #685
add oracle backend
space ready
structure ok
refactoring
return feehistory
data flow ok
basefee
set gas used ratio
computing reward
add testing
add gas used
prepare data
fill reward
increase coin
fixing api
add mac
add launch
gas used ratio ok
print element
reward workes
reward working
fix panic
value correct
remove debugging log
tidy up
tidy up
remove oracle
tidy up
fix handler crash
add unit test
tidy up
add limit check
reformat
fix lint
fix lint
fix lint
fix lint
Update rpc/ethereum/backend/feebackend.go
thanks
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Update rpc/ethereum/backend/feebackend.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Update rpc/ethereum/backend/feebackend.go
thanks
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Update rpc/ethereum/backend/feebackend.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
fix compile error
split lines
remove temporary string conversion
return error if gaslimit is 0
move OneFeeHistory to types
add comment
only err check
Update rpc/ethereum/backend/feebackend.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Update rpc/ethereum/backend/feebackend.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
tidy up
add feehistory-cap
* Apply suggestions from code review
* changelog
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Co-authored-by: Federico Kunze Küllmer <federico.kunze94@gmail.com>
2021-11-17 11:58:52 +00:00
yihuang
b7e8dd8216
fix: don't revert gas refund logic when transaction reverted ( #751 )
...
* fix gas consumption when reverted
Apply suggestions from code review
changelog
* comments
* Update x/evm/keeper/state_transition.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-16 14:49:59 +00:00
Adu
e96a4b9f9d
rpc: debug_intermediateRoots
( #754 )
...
* Problem: need to add JSON-RPC endpoint debug_intermediateRoots
Closes #715
* currently return emtpy hash
* add changelog entry
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-16 14:29:51 +00:00
crypto-facs
fdabf69cb3
fix: filter non Ethereum txs in block JSON-RPC response ( #741 )
...
* filter non eth txs in block rpc response
* update changelog
* fix remaining endpoints
* Update rpc/ethereum/namespaces/eth/api.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* fix GetTransactionByBlockNumberAndIndex
* add comment
* fix tx index
* filter txs by block height
* fix linter
* Update rpc/ethereum/backend/backend.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* remove unnecesary hex calls
* fix linter
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-16 15:16:57 +01:00
crypto-facs
d4621f3e82
fix: set EVM debug based on tracer config ( #746 )
...
* set debug based on tracer
* fix tests
* set default tracer
* remove debug from keeper
* remove unnecesary param
* remove unnecesary param
* Update x/evm/keeper/state_transition.go
* changelog
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Co-authored-by: Federico Kunze Küllmer <federico.kunze94@gmail.com>
2021-11-16 08:57:03 +00:00
Adu
f42f339d05
rpc: personal_listWallets
( #748 )
...
* Problem: need to add JSON-RPC endpoint personal_listWallets
Closes #745
* wallet level that manages accounts is not supported by keyring interface, will return nil
* changelog entry
* fix lint failure by exposing RawWallet as public
* fix notes typo
2021-11-15 11:20:59 +00:00
Federico Kunze Küllmer
32c905ab87
tests: integration tests with JSON-RPC client ( #704 )
...
* tests: integration tests with JSON-RPC client
* fix package
* tests: networking configuration fixed (#706 )
* update testnet hdPath, fixes #688
* lint
* header
* e2e wip
* fix getBlock response
* enable personal API
* changelog
Co-authored-by: Guillermo Paoletti <guillermo.paoletti@gmail.com>
Co-authored-by: Freddy Caceres <freddy.caceres@crypto.com>
2021-11-14 14:34:10 +01:00
Calvin Lau
481e3b82ce
rpc: add debug_tranceBlockByHash
, fix debug_traceBlock*
crash on non-existing block ( #743 )
...
* Problem: Missing debug_tranceBlockByHash RPC method
Solution: (Fix #742 ) Add the missing method
* Problem: debug_traceBlockByNumber crashed when block height not found
Solution: (Fix #744 ) Fix memory reference error
* Run go fmt
* Revert comment on init.sh
* Apply suggestions from code review
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* Update rpc/ethereum/backend/backend.go
* Update rpc/ethereum/backend/backend.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-12 08:50:38 +00:00
Jongwhan Lee
72c1098972
fix: cli-config for keys
command ( #725 )
...
* Problem: config/client.toml keyring-backend not working correctly (fix #724 )
refactoring
fix lint
refactoring
Apply suggestions from code review
add changelog
* changelog
Co-authored-by: Federico Kunze Küllmer <federico.kunze94@gmail.com>
2021-11-12 08:16:46 +00:00
Adu
a874c1e1ca
rpc: personal_initializeWallet ( #740 )
...
* Problem: need to add JSON-RPC endpoint personal_initializeWallet
Closes #738
* this is aimed at smartcard wallet which is not supported yet.
* changelog and not skip for expecting error
* fix personal_test error message assertion
* Apply suggestions from code review
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-11 15:12:14 +00:00
Adu
a3f1d8d89d
rpc: personal_unpair
( #733 )
...
* Problem: need to add rpc endpoint personal_unpair
Closes #730
* this is aimed at smartcard wallet which is not supported yet.
* will return unsupported error now.
* Update rpc/ethereum/namespaces/personal/api.go
* add changelog entry and use errors.Is
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Co-authored-by: Tomas Tauber <2410580+tomtau@users.noreply.github.com>
2021-11-10 10:09:53 +01:00
Federico Kunze Küllmer
d647988ad5
deps: bump IBC-go to v2 ( #737 )
...
* deps: bump IBC-go to v2
* c++
2021-11-09 20:25:49 +00:00
yihuang
2a205e561a
rpc: debug_traceTransaction
fails for succesful tx ( #720 )
...
* Problem: traceTransaction fails for succesful tx
Solution:
- Change the context to the begining of the block, rather than the end
of it, while override block context to correct one
pass predecessors
pass current block information to grpc query
* changelog
* fix build
* fix lint
* refactor traceBlock
* update protobuf
* fix Predecessors
* traceBlock refactor
* refactor traceBlock response
* Update proto/ethermint/evm/v1/tx.proto
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* Update proto/ethermint/evm/v1/query.proto
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* Update proto/ethermint/evm/v1/query.proto
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* Update proto/ethermint/evm/v1/query.proto
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* Update proto/ethermint/evm/v1/query.proto
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* Update proto/ethermint/evm/v1/query.proto
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* check tx index is not out of bound
* fix build
* Update rpc/ethereum/namespaces/debug/api.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* Update rpc/ethereum/namespaces/debug/api.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* Update rpc/ethereum/namespaces/debug/api.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* Update rpc/ethereum/namespaces/debug/api.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* remove prealloc
* add traceBlock test
* Update x/evm/keeper/grpc_query.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
* use bytes2Hex
* fix error message
* add comment
* Apply suggestions from code review
Co-authored-by: Freddy Caceres <freddy.caceres@crypto.com>
Co-authored-by: crypto-facs <84574577+crypto-facs@users.noreply.github.com>
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-09 18:38:22 +00:00
Adu
e04422b6ff
fix: tx fields are not authenticated by signature ( #703 )
...
Co-authored-by: Muggle-Du <adudu@CNMAC0342.local>
2021-11-08 14:00:35 +01:00
NevermoreRandom
fd36873261
rpc: decode raw transaction via RLP ( #727 )
...
* Decode raw transaction via RLP
* add changelog
* Apply suggestions from code review
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-11-08 08:22:31 +00:00
yihuang
10c49f7748
feat: add raw ethereum tx CLI ( #712 )
...
Closes #709
fix index
Apply suggestions from code review
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
fix lint
transaction decoding unit test
test BuildTx
fix lint
changelog
2021-11-02 12:20:19 +01:00
yihuang
d1446fc1f4
encoding: rm MsgEthereumTx
custom support in TxConfig
( #714 )
...
* remove MsgEthereumTx support in TxConfig
Closes : #711
* changelog
2021-11-02 11:24:24 +01:00
yihuang
bc1d81c5e8
fix: Web3 RPC handlers panic ( #702 )
...
* Problem: Some Web3 RPC Handlers could panic
Closes : #701
Solution:
- return error rather than panic when decoding invalid tx
* add validation rules
* changelog
2021-10-26 13:13:27 +02:00
Federico Kunze Küllmer
1447bf6655
docs: update changelog ( #699 )
2021-10-24 12:06:59 +00:00
yihuang
1fe07edbf9
evm: refactor dup state transition code ( #674 )
...
* Problem: state transition code is duplicated
Closes : #672
Solution:
- move gas refund out from ApplyMessage
- move check into ApplyMessage
- move evm construction into ApplyMessage
- ensure context stack is clean after ApplyMessage return
fix unit tests
undo rename
add underflow check
* improve performance
- don't duplicate params loading
- passing EVMConfig around as pointer
2021-10-22 19:21:03 +02:00
Federico Kunze Küllmer
799dffef7d
deps: bump cosmos-sdk ( #692 )
...
* deps: bump cosmos-sdk
* changelog
2021-10-22 10:49:38 +00:00
yihuang
ac75a9a4a4
refactor: eth_call
and eth_estimateGas
don't need to pass base fee as field ( #671 )
...
Solution:
- load fee directly from state
changelog
2021-10-21 17:29:19 +02:00
JayT106
c644dd6707
fix: handle file close logic ( #679 )
...
* handle file close logic
* Update rpc/ethereum/namespaces/debug/utils.go
* update changelog
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-10-19 08:55:55 +00:00
JayT106
1076307e6b
tests: DynamicFeeTx ( #649 )
...
* test DynamicFeeTx against state_transition_benchmark_test
* add feemarketGenesis in the app setup param
* add dynamicTxFee flag to KeeperTestSuite
* add feemarketGenesis.BaseFee setup
* update TestAddLog
* fix gasFeeCap assignment in newMsgEthereumTx
* modify keeperTestSuite helper functions to support dynamicTxFee
* update test cases in grpc_query_test w/ dynamicTxFee
* update the evm keeper utils tests
* add dynamic tx fee in the ante tests
* remove duplicate type define
* fix error return type
* update changelog
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-10-19 08:49:29 +00:00
Thomas Nguy
cd3b0be5ed
rpc, feemarket: store base fee in event ( #673 )
...
* store base fee in event
* update changelog
2021-10-15 08:59:26 +00:00
Thomas Nguy
75d553674c
evm, rpc: disable BaseFee
for non London block ( #662 )
...
* disable basefee if not london block
* add london block check in state transition
* fix linter
* add unit test
* clean code
* add changelog
2021-10-13 15:39:47 +02:00
Devashish Dixit
c7a2fb97c7
fix: limit total number of filters that can be created ( #661 )
...
* Problem: No way to limit total number of filters that can be created
Solution: Add a config parameter to set the total number of filters that can be created
* Add defer statement for releasing locks
* Change default value for filter cap to 200
* Changed data type of filter cap to int32
* Add changelog entry
* Update CHANGELOG.md
* Fix struct alignment
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-10-13 11:03:49 +00:00
Tomas Tauber
8e12d94359
rpc: fix ExpandHome
restrictions bypass ( #667 )
...
`go-home` seems to be using environment variables first
2021-10-13 10:52:05 +00:00
yihuang
2e067590a2
fix: nil pointer panic in ApplyNativeMessage
( #660 )
...
* Problem: nil pointer panic in ApplyNativeMessage
Solution:
- pass NoOpTracer
* use NewTracer
* changelog
2021-10-13 10:57:12 +02:00
Federico Kunze Küllmer
89e2b29aed
deps: bump cosmos-sdk ( #665 )
...
* deps: bump cosmos-sdk
* c++
2021-10-12 15:45:24 +00:00
Federico Kunze Küllmer
bc8c87cb28
chore: merge v0.7.0
to main ( #651 )
...
* chore: merge v0.7.0 to main
* update changelog
2021-10-08 12:03:51 +00:00
Thomas Nguy
fe5fefbd8e
evm: fix panic when transaction is reverted ( #650 )
...
* fix panic when transaction is reverted
* update changelog
* Update x/evm/keeper/context_stack.go
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-10-08 11:29:40 +00:00
JayT106
f69c887276
rpc: test fix ( #608 )
...
* fix rpc tests with net namespace
* skip personal test
* skip rpc pending test
* fix endpoint
* fix rpc pending test
* fix missing gas param in some rpc tests
* fix eth_getproof when the block number is equal to pending or latest
* fix rpc tests filter subscribe failed
* lint
* remove unused linter
* fix PendingTransactionFilter and TestEth_GetFilterChanges_BlockFilter
* fix eth_estimateGas
* fix TestEth_EstimateGas_ContractDeployment
* skip TestEth_ExportAccount_WithStorage
* remove sleep in rpc test
* Update changelog
* add test-rpc in github action
* bump golangci-lint version to v1.42.1
2021-10-07 18:41:27 +02:00
Thomas Nguy
f9323f6473
rpc: fix range filter fromBlock logic ( #643 )
2021-10-07 11:04:04 +02:00
Federico Kunze Küllmer
bcdb982886
rpc: geth v1.10.9 changes ( #624 )
...
* rpc: geth v1.10.9 changes
* updates
* suggestGasTipCap
* update gRPC
* resend
* fixes
* rm unused func
* address TODO
2021-10-06 11:22:32 +00:00
yihuang
202bc5f1cd
evm: fix iterator on deeply nested cache contexts ( #617 )
...
* Problem: iterator on deeply nested cache contexts is extremely slow
Closes : #616
Solution:
- flatten cache contexts before doing `GetTxLogsTransient`
* Update x/evm/keeper/context_stack.go
* changelog
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Co-authored-by: Federico Kunze <federico.kunze94@gmail.com>
2021-10-05 16:08:55 +00:00
Federico Kunze Küllmer
a8722655bb
all: bump go-ethereum to v1.10.9 ( #231 )
...
* all: bump go-ethereum to v1.10.4
* build
* state transition and rpc
* wip rpc changes
* fix refund
* fixes
* no base fee param
* ante handler
* undo change
* fix test
* bump deps
* calculate base fee
* gRPC base fee query
* update RPC
* fix
* update'
* go.mod
* fix build
* fix panic
* rm changes in third_party
* json rpc changes
* reserved fields
* fixes fixes fixes
* rm no stringer
* fixes 2
* tests wip
* bump geth version
* update
* grpc traceTx
* rm fee market from ante
* fix TransactionArgs
* lint
* update proto
* update tx args
* changelog
2021-10-05 15:38:20 +00:00
yihuang
cda968bddd
evm, rpc: fix tx log attribute value is not parsable by some client ( #615 )
...
* Problem: tx log attribute value not parsable by some client
Closes : #614
Solution:
- encode the value to json string rather than bytes
Apply suggestions from code review
* rm cdc and changelog
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Co-authored-by: Federico Kunze <federico.kunze94@gmail.com>
2021-10-05 10:26:31 +00:00
Federico Kunze Küllmer
d6423f0c3f
deps: bump IBC-go ( #621 )
...
* deps: bump IBC-go
* changelog
2021-10-04 15:09:30 +00:00