Skip to content

Commit

Permalink
Merge branch 'main' into v0.7.x_rocks
Browse files Browse the repository at this point in the history
  • Loading branch information
yihuang authored Apr 26, 2022
2 parents 9f5fa95 + 891eb94 commit 521c54e
Show file tree
Hide file tree
Showing 19 changed files with 1,163 additions and 615 deletions.
3 changes: 3 additions & 0 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,9 @@ import (
// Force-load the tracer engines to trigger registration
_ "github.com/ethereum/go-ethereum/eth/tracers/js"
_ "github.com/ethereum/go-ethereum/eth/tracers/native"

// force register the extension json-rpc.
_ "github.com/crypto-org-chain/cronos/x/cronos/rpc"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ replace (

github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1

github.com/tharsis/ethermint => github.com/crypto-org-chain/ethermint v0.10.0-alpha1-cronos-8
github.com/tharsis/ethermint => github.com/crypto-org-chain/ethermint v0.10.0-alpha1-cronos-8.0.20220420023806-5b624f76d0fc

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 @@ -265,8 +265,8 @@ github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsr
github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
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/crypto-org-chain/ethermint v0.10.0-alpha1-cronos-8 h1:+1FLhY/C+mKUPqKNqtq81tCIorCFcqLZZflHebRDnIc=
github.com/crypto-org-chain/ethermint v0.10.0-alpha1-cronos-8/go.mod h1:3CXBYpzlUtEn6OCr1WFw/951MBEeojZW3hcqPCv5ktw=
github.com/crypto-org-chain/ethermint v0.10.0-alpha1-cronos-8.0.20220420023806-5b624f76d0fc h1:z0LzHZt238Y9sOsQvVI1PciUG7qnWrIM62vRRplJF1g=
github.com/crypto-org-chain/ethermint v0.10.0-alpha1-cronos-8.0.20220420023806-5b624f76d0fc/go.mod h1:3CXBYpzlUtEn6OCr1WFw/951MBEeojZW3hcqPCv5ktw=
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
6 changes: 3 additions & 3 deletions gomod2nix.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3668,13 +3668,13 @@
sha256 = "1sgjf2vaq554ybc0cwkzn17cz2ibzph2rq0dgaw21c2hym09437x"

["github.com/tharsis/ethermint"]
sumVersion = "v0.10.0-alpha1-cronos-8"
sumVersion = "v0.10.0-alpha1-cronos-8.0.20220420023806-5b624f76d0fc"
vendorPath = "github.com/crypto-org-chain/ethermint"
["github.com/tharsis/ethermint".fetch]
type = "git"
url = "https://github.com/crypto-org-chain/ethermint"
rev = "f4db90bb0575d2ffbe4e2f141c75b7cd638354a9"
sha256 = "15gv5hkcf5958rp69m49nxx7kagwpgicn1ry6b6mf23skwxys091"
rev = "5b624f76d0fc4d7fbd2bcc84135505de4bf62a21"
sha256 = "0mkslhsar47ayb3m1rf70ca13r6qhfd2xzdrnl16gfkpwc6p9pk5"

["github.com/tidwall/gjson"]
sumVersion = "v1.6.7"
Expand Down
10 changes: 9 additions & 1 deletion integration_tests/cosmoscli.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,9 @@ def __init__(
cmd,
):
self.data_dir = data_dir
self._genesis = json.load(open(self.data_dir / "config" / "genesis.json"))
self._genesis = json.loads(
(self.data_dir / "config" / "genesis.json").read_text()
)
self.chain_id = self._genesis["chain_id"]
self.node_rpc = node_rpc
self.raw = ChainCommand(cmd)
Expand Down Expand Up @@ -503,6 +505,12 @@ def broadcast_tx(self, tx_file, **kwargs):
self.raw("tx", "broadcast", tx_file, node=self.node_rpc, **kwargs)
)

def broadcast_tx_json(self, tx, **kwargs):
with tempfile.NamedTemporaryFile("w") as fp:
json.dump(tx, fp)
fp.flush()
return self.broadcast_tx(fp.name)

def unjail(self, addr):
return json.loads(
self.raw(
Expand Down
10 changes: 5 additions & 5 deletions integration_tests/network.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ class Cronos:
def __init__(self, base_dir):
self._w3 = None
self.base_dir = base_dir
self.config = json.load(open(base_dir / "config.json"))
self.enable_auto_deployment = json.load(open(base_dir / "genesis.json"))[
"app_state"
]["cronos"]["params"]["enable_auto_deployment"]
self.config = json.loads((base_dir / "config.json").read_text())
self.enable_auto_deployment = json.loads(
(base_dir / "genesis.json").read_text()
)["app_state"]["cronos"]["params"]["enable_auto_deployment"]
self._use_websockets = False

def copy(self):
Expand Down Expand Up @@ -65,7 +65,7 @@ def use_websocket(self, use=True):
class Chainmain:
def __init__(self, base_dir):
self.base_dir = base_dir
self.config = json.load(open(base_dir / "config.json"))
self.config = json.loads((base_dir / "config.json").read_text())

def base_port(self, i):
return self.config["validators"][i]["base_port"]
Expand Down
Loading

0 comments on commit 521c54e

Please sign in to comment.