Skip to content

feat: allow to specify Ethereum chain id#168

Open
daniel1302 wants to merge 1 commit into
mainfrom
fix-ethereum-client
Open

feat: allow to specify Ethereum chain id#168
daniel1302 wants to merge 1 commit into
mainfrom
fix-ethereum-client

Conversation

@daniel1302

Copy link
Copy Markdown
Contributor

Issue

Currently bots are failing with the following errors on non ganache network:

time="2022-09-27T20:51:06.053505238Z" level=info msg=Version hash=no_hash_set version=no_version_set
time="2022-09-27T20:51:06.053571623Z" level=info msg="Initialised bot" name=b00
time="2022-09-27T20:51:06.248063852Z" level=info msg="Connected to data node" host="n01.stagnet3.vega.xyz:3007" service=DataNode state=READY
time="2022-09-27T20:51:06.563555896Z" level=fatal msg="Failed to create service" error="failed to initialise bots: failed to initialise bot 'b00': failed to start bot b00: failed to create token service: failed to create Ethereum client: failed to dial Ethereum client: websocket: bad handshake (HTTP status 400 Bad Request)"

Comment thread go.mod
code.vegaprotocol.io/priceproxy v0.1.0
code.vegaprotocol.io/protos v0.53.0
code.vegaprotocol.io/shared v0.0.0-20220704150014-7c22d12ccb72
code.vegaprotocol.io/shared v0.0.0-20220816105810-a519d6b44f35

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In shared@v0.0.0-20220813000126-79cdcc23dfd0 I've added code that automatically gets the chainID:

chainID, err := client.ChainID(ctx)
if err != nil {
	return nil, fmt.Errorf("failed to get chain ID: %w", err)
}

@daniel1302 daniel1302 Sep 27, 2022

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yess I just realised it later and updated that library

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants