Skip to content

Commit

Permalink
fix: logs + data decrypt
Browse files Browse the repository at this point in the history
  • Loading branch information
rach-id committed Jul 2, 2024
1 parent 0c93b67 commit 3414640
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion replay/evm.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ func submitProof(
waitTimeout time.Duration,
) error {
for i := 0; i < 10; i++ {
logger.Info("submitting proof", "nonce", proofNonce, "gas_price", opts.GasPrice.Int64())
logger.Info("submitting transaction for proof", "nonce", proofNonce, "gas_price", opts.GasPrice.Int64())
tx, err := succinctGateway.FulfillCall(
opts,
args.FunctionID,
Expand All @@ -128,6 +128,7 @@ func submitProof(
if err != nil {
return err
}
logger.Info("transaction submitted", "hash", tx.Hash().Hex())
_, err = waitForTransaction(ctx, logger, client, tx, waitTimeout)
if err != nil {
actualNonce, err := targetBlobstreamXContract.StateProofNonce(&bind.CallOpts{})
Expand Down
5 changes: 3 additions & 2 deletions replay/replayer.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ func Follow(

logger.Debug("decoding the proof")
rawMap := make(map[string]interface{})
err = abi.UnpackIntoMap(rawMap, "fulfillCall", tx.Data())
err = abi.UnpackIntoMap(rawMap, "fulfillCall", tx.Data()[4:])
if err != nil {
return err
}
Expand Down Expand Up @@ -229,7 +229,8 @@ func Catchup(

logger.Debug("decoding the proof")
rawMap := make(map[string]interface{})
err = abi.UnpackIntoMap(rawMap, "fulfillCall", tx.Data())
inputArgs := abi.Methods["fulfillCall"].Inputs
err = inputArgs.UnpackIntoMap(rawMap, tx.Data()[4:])
if err != nil {
return err
}
Expand Down

0 comments on commit 3414640

Please sign in to comment.