Federico Kunze
261f86fdf2
bump SDK to v0.39.1 ( #386 )
...
* bump sdk version to v0.39.0 candidate
* updates
* update evm
* bump commit
* more changes
* build
* genesis
* fix tests
* fix tests
* bump commit
* bump commit
* bump commit
* add keygen func
* bump version to 0.39.0-rc0
* update AnteHandler
* fix TxDecoder
* lint
* fix test
* update statedb
* changelog
* fixes
* remove extra files
* update make test-import
* rename test
* bump SDK version to final release
* update to 0.39.1-rc1
* fix evm tests
* update RPC
* minor fixes
* update to rc2
* bump to v0.39.1
* fix personal API
* fix string type cast ambiguity (#449 )
* init
* fix estimate gas test
* minor genesis change
* remove comments from unstable commit (stargate release)
Co-authored-by: Alessio Treglia <quadrispro@ubuntu.com>
2020-08-23 17:41:54 -04:00
Federico Kunze
a243f43fe2
crypto: add keyring supported algorithms ( #439 )
...
* add keyring supported algorithms
* lint
* minor updates
* use eth_secp256k1 as the default signing algo
* add flag
* derivation func
* refactor
* rename keys amino registration
* fix keys
* address comments from review
2020-08-11 11:01:15 -04:00
noot
1d8c997585
rpc: implement eth_chainId ( #379 )
...
* add eth_chainId
* add nolint
* use clientCtx chainID
* rpc: eth_chainId test
Co-authored-by: Federico Kunze <federico.kunze94@gmail.com>
2020-07-08 03:57:19 -04:00
Daniel Choi
b76c36fcdb
allow multikey unlock ( #356 )
...
* allow multikey unlock
* fix lint
* Update rpc/apis.go
Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>
2020-07-06 10:03:34 -07:00
Federico Kunze
20e9b2ede3
rpc: event websocket subscription ( #308 )
...
* rpc: event websocket subscription
* rpc: use tendermint event subscriptions
* new log events
* filter evm transactions
* filter logs
* wip: refactor filters
* remove custom BlockNumber
* wip: refactor rpc
* HeaderByNumber and HeaderByHash
* update Tendermint event system
* update Filter
* update EventSystem
* fix lint issues
* update rpc filters
* upgrade to tendermint v0.33.4
* update filters
* fix unsubscription
* updates wip
* initialize channels
* cleanup go routines
* pass ResultEvent channel on subscription
* error channel
* add block filter changes test
* add eventCh loop
* pass funcs in select go func, block filter working
* cleanup
* lint
* NewFilter and GetFilterChanges working
* eth_getLogs working
* lint
* lint
* cleanup
* remove logs and minor fixes
* changelog
* address @noot comments
* revert BlockNumber removal
Co-authored-by: noot <elizabethjbinks@gmail.com>
2020-07-03 11:40:00 -04:00
Federico Kunze
edf4357176
build: github actions ( #346 )
...
* add workflows
* fix
* fix lint
* rpc tests
* build and format
* fix build errors
* remove dontcover
* update importer test
* more fixes
* lint
* split importer test
* fix
* remove tmp dir
* revert
* comment test import
2020-06-26 18:26:55 -04:00
noot
e9c494cf71
rpc: return 0 nonce if account doesn't exist ( #345 )
...
* add EnsureExists check to GetTransactionCount
* cleanup, return 0 as nonce if account doesn't exist
* update changelog
* update changelog
2020-06-26 14:15:54 -04:00
noot
0921c863e7
update uncles return ( #337 )
2020-06-18 16:35:06 -04:00
noot
9f573690a6
implement eth_exportAccount ( #331 )
2020-06-17 14:23:36 -04:00
noot
94f6acc651
rpc: return 0x0 as extra data in block instead of nil ( #333 )
...
* return 0x0 extra data instead of nil
* add fix for getBlock
* add tests
2020-06-17 12:14:21 -04:00
Federico Kunze
7b164a5aa4
Revert "bump SDK commit ( #324 )" ( #328 )
...
This reverts commit 5614adc933
.
2020-06-08 20:33:48 +02:00
Federico Kunze
988ee53a59
rpc: implement eth_coinbase ( #325 )
...
* rpc: implement eth_coinbase
* changelog
* address comments from review
* changelog
2020-06-08 12:43:37 -04:00
Federico Kunze
5614adc933
bump SDK commit ( #324 )
...
* bump SDK commit
* crypto: Secp256k1 algorithm
* crypto: fix codec and derivation issues
* lint
2020-06-08 12:19:26 -04:00
noot
446eb0a3b7
change eth_estimateGas to return hexutil.Uint64 ( #322 )
...
* change eth_estimateGas to return hexutil.Uint64
* update test
* Update rpc/eth_api.go
Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>
2020-06-01 14:12:34 -04:00
noot
846f48a572
get account sequence in GetTransactionCount ( #303 )
...
* get account sequence if querying latest in GetTransactionCount
* use ctx WithHeight in GetTransactionCount; remove nonce query from querier
2020-05-17 11:15:32 -04:00
noot
51b68d7512
rpc: fix receipt logs ( #285 )
...
* update GetTransactionReceipt and test
* change DecodeResultData err check back
* change doCall back
* change doCall back
* add logs
* remove prints
2020-05-14 16:55:33 -04:00
Federico Kunze
c7d89e3d56
rpc: fix eth_getProof ( #286 )
2020-05-12 15:12:52 -04:00
noot
ce0feb307b
update rpc tests ( #276 )
...
* update rpc tests
* cleanup
* add log assertion to getTransacionReceipt
* fix queurier_test
* address comment
2020-05-04 18:02:26 -04:00
Federico Kunze
26d4e968e0
remove duplicate query in receipts ( #273 )
...
* logs tests
* updates
* String()
* remove extra query, add comments
* test fixes
* lint
* lint
2020-05-02 21:56:18 -04:00
noot
86cd39defb
fix transaction receipts ( #274 )
...
* return ethtypes.Receipt in GetTransactionReceipt
* add PostState to receipts, test working
* add contract addr assert to tests
* update tests
* cleanup, working with web3
* remove print
* update tests
2020-05-02 13:39:26 -04:00
Federico Kunze
8ec7edf5bd
x/evm: unit tests and fixes ( #223 )
...
* evm: move Keeper and Querier to /keeper package
* keeper: update keeper_test.go
* fix format
* evm: use aliased types
* bump SDK version to v0.38.1
* app: updates from new version
* errors: switch sdk.Error -> error
* errors: switch sdk.Error -> error. Continuation
* more fixes
* update app/
* update keys and client pkgs
* build
* fix tests
* lint
* minor changes
* changelog
* address @austinbell comments
* Fix keyring usage in rpc API and CLI
* fix keyring
* break line
* Misc cleanup (#188 )
* evm: move Begin and EndBlock to abci.go
* evm: use expected keeper interfaces
* app: use EthermintApp for integration and unit test setup
* evm: remove count type; update codec
* go mod verify
* evm: rename msgs for consistency
* evm: events
* minor cleanup
* lint
* ante: update tests
* changelog
* nolint
* evm: update statedb to create ethermint Account instead of BaseAccount
* fix importer test
* address @austinabell comments
* update README
* changelog
* evm: update codec
* rename GasLimit->Gas and Price ->GasPrice
* msg cleanup and tests
* cleanup TxData
* fix marshaling
* revert rename
* move types
* evm/keeper: querier tests
* switch MarshalLengthPrefixed -> BinaryBare; remove panics
* fix event sender
* fix panic
* try fix txDecoder error
* evm: handler tests
* evm: handler MsgEthermint test
* fix tests
* store logs in keeper after transition (#210 )
* add some comments
* begin log handler test
* update TransitionCSDB to return ReturnData
* use rlp for result data encode/decode
* update tests
* implement SetBlockLogs
* implement GetBlockLogs
* test log set/get
* update keeper get/set logs to use hash as key
* fix test
* move logsKey to csdb
* attempt to fix test
* attempt to fix test
* attempt to fix test
* lint
* lint
* lint
* save logs after handling msg
* update k.Logs
* cleanup
* remove unused
* fix issues
* comment out handler test
* address comments
* lint
* fix handler test
* address comments
* use amino
* lint
* address comments
* merge
* fix encoding bug
* minor fix
* rpc: error handling
* rpc: simulate only returns gasConsumed
* rpc: error ineffassign
* evm: handler test
* go: bump version to 1.14 and SDK version to latest master
* rpc: fix simulation return value
* breaking changes from SDK
* sdk: breaking changes; build
* tests: fixes
* minor fix
* proto: ethermint types attempt
* proto: define EthAccount proto type and extend sdk std.Codec
* evm: fix panic on handler test
* evm: minor state object changes
* cleanup
* tests: update test-importer
* fix evm test
* fix pubkey registration
* lint
* cleanup
* more test checks for importer
* minor change
* codec fixes
* rm init func
* fix importer test build
* fixes
* test fixes
* fix bloom key
* rm unnecesary func
* remove comment
Co-authored-by: austinabell <austinabell8@gmail.com>
Co-authored-by: noot <36753753+noot@users.noreply.github.com>
2020-04-23 11:49:25 -04:00
Federico Kunze
4d609b2a22
bump Cosmos SDK version to v0.38.2 ( #183 )
...
* evm: move Keeper and Querier to /keeper package
* keeper: update keeper_test.go
* fix format
* evm: use aliased types
* bump SDK version to v0.38.1
* app: updates from new version
* errors: switch sdk.Error -> error
* errors: switch sdk.Error -> error. Continuation
* more fixes
* update app/
* update keys and client pkgs
* build
* fix tests
* lint
* minor changes
* changelog
* address @austinbell comments
* Fix keyring usage in rpc API and CLI
* fix keyring
* break line
* Misc cleanup (#188 )
* evm: move Begin and EndBlock to abci.go
* evm: use expected keeper interfaces
* app: use EthermintApp for integration and unit test setup
* evm: remove count type; update codec
* go mod verify
* evm: rename msgs for consistency
* evm: events
* minor cleanup
* lint
* ante: update tests
* changelog
* nolint
* evm: update statedb to create ethermint Account instead of BaseAccount
* fix importer test
* address @austinabell comments
* update README
* changelog
* evm: update codec
* fix event sender
* store logs in keeper after transition (#210 )
* add some comments
* begin log handler test
* update TransitionCSDB to return ReturnData
* use rlp for result data encode/decode
* update tests
* implement SetBlockLogs
* implement GetBlockLogs
* test log set/get
* update keeper get/set logs to use hash as key
* fix test
* move logsKey to csdb
* attempt to fix test
* attempt to fix test
* attempt to fix test
* lint
* lint
* lint
* save logs after handling msg
* update k.Logs
* cleanup
* remove unused
* fix issues
* comment out handler test
* address comments
* lint
* fix handler test
* address comments
* use amino
* lint
* address comments
* merge
* fix encoding bug
* minor fix
* rpc: error handling
* rpc: simulate only returns gasConsumed
* rpc: error ineffassign
* go: bump version to 1.14 and SDK version to latest master
* rpc: fix simulation return value
* breaking changes from SDK
* sdk: breaking changes; build
* tests: fixes
* minor fix
* proto: ethermint types attempt
* proto: define EthAccount proto type and extend sdk std.Codec
* evm: fix panic on handler test
* evm: minor state object changes
* cleanup
* tests: update test-importer
* fix pubkey registration
* lint
* cleanup
* more test checks for importer
* minor change
* codec fixes
* rm init func
* fix importer test build
* fix marshaling for TxDecoder
* use amino codec for evm
* fix marshaling for SimulationResponse
* use jsonpb for unmarshaling
* fix method handler crashed
* return err on VerifySig
* switch stateObject balance to sdk.Int
* fixes to codec and encoding
* cleanup
* set tmhash -> ethhash in state transition
* add tmhash->ethereumhash to csdb.GetLogs
* attempt to fix tests
* update GetLogs to switch with Has
* ante panic
* diff changes
* update SetLogs
* evm/cli: use ethermint codec
* use LengthPrefixed for encoding
* add check for nil *big.Int
* add balance to UpdateAccounts
* fix previous balance
* fix balance bug
* prevent panic on make test-import
Co-authored-by: austinabell <austinabell8@gmail.com>
Co-authored-by: noot <36753753+noot@users.noreply.github.com>
Co-authored-by: noot <elizabethjbinks@gmail.com>
2020-04-22 15:26:01 -04:00
Austin Abell
33ab63ef15
update web3 transaction hash from RLP ( #250 )
...
* remove ethereum hash of web3 transaction type (always amino hash)
* Update changelog
2020-04-13 19:08:43 -04:00
noot
199484fc2e
eth_getFilterLogs, eth_getLogs implementation ( #248 )
2020-04-13 15:18:50 -04:00
noot
35e7a98ab2
filters: begin implementation ( #230 )
...
* adds Filter type and related methods
* updates PublicFilterAPI to include backend, filter mapping
* stub out filter related eth_ functions
2020-04-01 20:43:59 -04:00
Federico Kunze
da9157e406
upgrade changes cleanup ( #236 )
...
* changes from update version
* app changes
* cmd changes
* build and send tx
* fix tests
* eth_rpc fixes
* lint
* add WithEventManager to handler ctx
* changelog
* go mod verify and tidy
2020-04-01 15:49:21 -03:00
Federico Kunze
87b625ed50
Tools configuration and linters ( #215 )
...
* tools config
* lint
* lint
* codecov
2020-03-16 19:53:24 -03:00
Federico Kunze
30f34e6c59
evm: move Keeper and Querier to /keeper package ( #182 )
...
* evm: move Keeper and Querier to /keeper package
* keeper: update keeper_test.go
* fix format
* evm: use aliased types
* add comments from review
* changelog
2020-03-09 10:17:23 -03:00
Austin Abell
51adade59f
Update golangci-lint config and fix linting issues ( #168 )
...
* update golangci
* update golang lint yml and updated linting issues
2020-01-08 09:56:49 +13:00
Austin Abell
ce8a94a98e
Cosmos PR changes ( #158 )
...
* Changes necessary for enforced custom account encoding/decoding and keyring keybase changes
* updates cosmos dependency and fixes inconsistency in gas usage for simulated/real txs
* Update PR changes
* Remove unused password prompt when using OS keyring
* Update from changes to sdk
* Update to merged PR commit :the_horns:
* updated code to handle keyring backend options
* update documentation and replace cosmos-sdk with fork (temporarily)
* update cosmos dependency from fork
* update documentation
2019-12-13 14:50:19 -05:00
Austin Abell
6eef37b0c6
Finish and clean up module queries and txs ( #152 )
...
* Basic transactions set up (to be separated)
* Change transaction command to not include create operation (to include other command in next commit)
* set up create command and made minor changes
* wip implements module queries
* Added tests for query address decoding
* Added ambiguous encoding of to address in transaction and added tests
* Fix linting issue
* Move registering key types to application level to allow module usage to ignore
* Move genaccounts code to be reused
* Switches nonce increase to always happen in ante handler
* change SetNonce from keeper to point to actual nonce operation
* Remove no op nonce switch (not needed with clearing cache)
* Changes to update all accounts pre state transition and clear cache at end of block
* Update accounts before end of block commit (edge case where necessary)
* Fix nonce of sender going into evm in case it's checked, and let evm set contract starting nonce
2019-11-15 12:02:13 -05:00
Austin Abell
9311f9efd0
Update keybase back to cosmos-sdk with support ( #147 )
...
* Migrate keybase back to Cosmos-sdk using temporary fork
* Cleaned up other affected code
* Change to updated tendermint
* fmt
* Change auth codec update
* clean up codec registration to respective packages
* Fix import fmt
* Remove no longer necessary replace
* Fix function comment
2019-11-13 12:00:21 -05:00
Austin Abell
1f51b73d71
Fix block gas limit return for dev tooling ( #150 )
...
* cap formatted -1 value of tendermint block gas limit
* return blank miner address for dev tooling checks
2019-11-07 13:02:35 -05:00
Austin Abell
42227a1b8c
Fix eth_estimateGas and simulated txs ( #142 )
2019-11-04 11:59:16 -05:00
Dustin Brickwood
fc57cabcab
Linted Repo ( #136 )
...
* Linted
* Updated lint to include config file
* Linted repo
* Updated make command
* made requested changes
* added no lint
2019-11-01 10:26:53 -05:00
Austin Abell
9294fa8423
Fix edge case for accessing accounts through rpc ( #134 )
...
* Add mutex and close keybase database correctly after use
* Add options http request to rpc API for remix
2019-10-31 11:09:40 -04:00
Dustin Brickwood
69e0873dd9
eth_estimateGas ( #128 )
...
* Draft eth_estimateGas
* implemented eth_estimateGas
* refactored doCall to be used for both eth_call and eth_estiamteGas
* updated to reflect requested changes
* moved GenerateFromArgs func
* removed todo
* revert comment
* fixes dereference issue
* gofmted
2019-10-30 13:30:24 -05:00
Austin Abell
2b4d2bea82
Implements eth_call ( #127 )
...
* Fixed tx receipt error on failed transaction
* Add returnData to failed transaction for logs bloom
* Added simulate call option, without returning evm data
* Added encoding and decoding of data from EVM execution for usability
* Remove unused context parameter
* Fix function comment and remove unnecessary logging on eth_call
2019-10-22 11:40:34 -05:00
Austin Abell
475919274e
Tx receipt query fix ( #126 )
...
* Fixed tx receipt error on failed transaction
* Add returnData to failed transaction for logs bloom
* Change comment to TODO
2019-10-23 01:04:51 +09:00
Austin Abell
160e82b2ad
Implement eth_pendingTransactions, bump sdk version ( #124 )
...
* Update sdk version, implement pending txs, fix nonce check
* Bump cached dependencies in circleCI
* bump circleci go version
* updated linter and fixed bugs relating to go version 1.13
2019-10-19 08:23:09 +09:00
Austin Abell
dc25d847c3
Implements eth_getProof ( #122 )
...
* Implemented eth_getProof and cleaned logs query types
* Rename ethereum logs query type
2019-10-16 09:46:50 +09:00
Austin Abell
eab81bc578
block and tx logs bloom and tx receipt logs ( #119 )
...
* Add bloom filter to tx receipt
* wip tx receipt logs to be tested
* Added Bloom - Height Mapping
* keeper.go sets <height:bloombits>
* keeper.go gets <height> --> bloombits
* updating and querying bloom by block (to be tested with real logs)
* fix bug with contract address return
* added error handling instead of logging
2019-10-04 15:32:56 -04:00
Austin Abell
1119c650c6
Implements gettransactionbyblockhashandindex ( #115 )
2019-09-29 16:46:10 -04:00
Austin Abell
81fc39a9bc
Implement eth_getBlockTransactionCountByHash ( #116 )
2019-09-29 16:43:26 -04:00
Austin Abell
09a71a2a3a
eth_getBlockByHash and block hash mapping functionality ( #114 )
...
* Set up block hash to height mapping storage and fixed linting issues
* fix typos
* Set up module query for block height
* fix bug with block mappings and implemented get block by hash
* Fix other consensus hash references
2019-09-27 10:08:45 -04:00
Austin Abell
7f1eb4b0cf
Query and bug fixes ( #110 )
...
* Fix queries and bugs
* Fix issues from rebasing
* Fix rpc query address
2019-09-26 11:36:23 -04:00
Austin Abell
192ce2cc1c
Implement eth_syncing ( #86 )
...
* wip getting Ethereum spec syncing status
* Update sync query
2019-09-26 11:33:25 -04:00
Austin Abell
6cfeb6e754
eth_getTransactionReceipt Impl ( #109 )
...
* wip Implement get transaction receipt, waiting on details to finalize
* Fix response format for tx receipt
* Fix duplicate err check
* remove cumulative gas field
* Used byte conversion function
2019-09-25 14:38:33 -04:00
Austin Abell
26e90e729e
Implement eth_getTransactionByBlockNumberAndIndex ( #107 )
...
* Implements eth_getTransactionByBlockNumberAndIndex
* reuse convenience function for converting bytes to eth tx
2019-09-25 09:26:42 -04:00
Austin Abell
cfca4d10e6
Implements eth_getTransactionByHash ( #108 )
...
* Implement eth_getTransactionByHash and add function for converting bytes to eth tx
* Fix nil return on invalid hash
* Fix error check
2019-09-24 21:58:29 -04:00