-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add SC calls handling for ETH->MvX #267
Conversation
clients/batch.go
Outdated
return cloned | ||
} | ||
|
||
// SCBatch - |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
complete comments.
clients/ethereum/client_test.go
Outdated
@@ -5,6 +5,8 @@ import ( | |||
"encoding/hex" | |||
"errors" | |||
"fmt" | |||
"github.com/ethereum/go-ethereum" | |||
"github.com/ethereum/go-ethereum/ethclient" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
goimports
clients/ethereum/interface.go
Outdated
@@ -2,6 +2,7 @@ package ethereum | |||
|
|||
import ( | |||
"context" | |||
"github.com/ethereum/go-ethereum" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
goimports
@@ -2,6 +2,7 @@ package wrappers | |||
|
|||
import ( | |||
"context" | |||
"github.com/ethereum/go-ethereum" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
goimports
clients/ethereum/client.go
Outdated
"context" | ||
"crypto/ecdsa" | ||
"fmt" | ||
"github.com/ethereum/go-ethereum" | ||
"github.com/multiversx/mx-bridge-eth-go/clients/ethereum/contract" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
goimports
return GettingPendingBatchFromEthereum | ||
} | ||
|
||
actionID, err := step.bridge.GetAndStoreActionIDForProposeSCTransferOnMultiversX(ctx) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we need new steps of 6 and 7 ? all the SC execution should be in parallel to this state-machine.
We would need a separate process where small bots are monitoring the SC which can forward call for executions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will evaluate in the upcoming PR if we need more decoupling on the eth components
…l fields in assertion to avoid false positives
… into sc-exec-impl
cd241fe
The flow should be as follows:
Since ETH contracts are non-upgradable we introduced a new proxy contract in front of the SafeContract.
This contract emits an event with some metadata we need for smart contract execution on MvX (tx data and gas limit + matching info like deposit and batch nonces) then forwards the deposit call to SafeContract.