Skip to content

Commit

Permalink
Problem: eth_sendTransaction api don't work (crypto-org-chain#693)
Browse files Browse the repository at this point in the history
* Problem: eth_sendTransaction api don't work

Solution:
- clear the `From` field when building tx.

* Update CHANGELOG.md

* gomod2nix and fix test
  • Loading branch information
yihuang authored Sep 9, 2022
1 parent f700166 commit 0a546f6
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 5 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@

## UNRELEASED

### Bug Fixes

- [#693](https://github.com/crypto-org-chain/cronos/pull/693) Clear `From` field when building cosmos tx in `eth_sendTransaction`.

*Aug 31, 2022*

## v0.8.1

### Improvements

- [#667](https://github.com/crypto-org-chain/cronos/pull/667) Update iavl to 0.19.1 to improve node startup performance.
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ replace (

github.com/tendermint/tendermint => github.com/tendermint/tendermint v0.34.20

github.com/tharsis/ethermint => github.com/crypto-org-chain/ethermint v0.11.1-cronos
github.com/tharsis/ethermint => github.com/crypto-org-chain/ethermint v0.11.1-cronos.0.20220908100956-189ed50c7867

google.golang.org/grpc => google.golang.org/grpc v1.33.2
)
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -307,8 +307,8 @@ github.com/creachadair/taskgroup v0.3.2/go.mod h1:wieWwecHVzsidg2CsUnFinW1faVN4+
github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY=
github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
github.com/crypto-org-chain/ethermint v0.11.1-cronos h1:zlIl/VsltwoDAtNU1weWkVsYyOlt3qMbBzB5+tjdmo8=
github.com/crypto-org-chain/ethermint v0.11.1-cronos/go.mod h1:fnIlYT2MNQLj7cNiGz3rqgM5Yu/CYh5rV570Mxe2Wp8=
github.com/crypto-org-chain/ethermint v0.11.1-cronos.0.20220908100956-189ed50c7867 h1:65ww4rd8+dx9EVr3uWC+UAXCy+maF86Pvw7msjl12T0=
github.com/crypto-org-chain/ethermint v0.11.1-cronos.0.20220908100956-189ed50c7867/go.mod h1:fnIlYT2MNQLj7cNiGz3rqgM5Yu/CYh5rV570Mxe2Wp8=
github.com/crypto-org-chain/ibc-go/v2 v2.2.0-hooks2 h1:elj+Tb/3O9GA3pv62zkc1B0P8hl1WHmF6vF8PInEJm4=
github.com/crypto-org-chain/ibc-go/v2 v2.2.0-hooks2/go.mod h1:rAHRlBcRiHPP/JszN+08SJx3pegww9bcVncIb9QLx7I=
github.com/crypto-org-chain/keyring v1.1.6-fixes h1:AUFSu56NY6XobY6XfRoDx6v3loiOrHK5MNUm32GEjwA=
Expand Down
4 changes: 2 additions & 2 deletions gomod2nix.toml
Original file line number Diff line number Diff line change
Expand Up @@ -376,8 +376,8 @@ schema = 3
version = "v0.6.7"
hash = "sha256-hl/3RrBrpkk2zA6dmrNlIYKs1/GfqegSscDSkA5Pjlo="
[mod."github.com/tharsis/ethermint"]
version = "v0.11.1-cronos"
hash = "sha256-YQUAt3DNu4APK6i1o9WnnIZdi/ciGxGyBB0VvTZ8/iI="
version = "v0.11.1-cronos.0.20220908100956-189ed50c7867"
hash = "sha256-QTVXHmgEX7I8uMMppJTSbVSkIo1pHK9FYvW28M2YZ50="
replaced = "github.com/crypto-org-chain/ethermint"
[mod."github.com/tklauser/go-sysconf"]
version = "v0.3.10"
Expand Down
14 changes: 14 additions & 0 deletions integration_tests/test_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,20 @@ def test_basic(cluster):
assert w3.eth.chain_id == 777


def test_send_transaction(cluster):
"test eth_sendTransaction api"
w3 = cluster.w3
txhash = w3.eth.send_transaction(
{
"from": ADDRS["validator"],
"to": ADDRS["community"],
"value": 1000,
}
)
receipt = w3.eth.wait_for_transaction_receipt(txhash)
assert receipt.status == 1


def test_events(cluster, suspend_capture):
w3 = cluster.w3
erc20 = deploy_contract(
Expand Down

0 comments on commit 0a546f6

Please sign in to comment.